|
No, the path is not correct. [ /Users/dewdrop/sounds/a11wlk01.wav ] The current drag seems to be giving you an array containing the string -- the brackets. BTW, you have an extra pair of {} in there, removed here and reformatted to be legible :) { var w,a,sf; w=Window.new("drag n drop utility",Rect(700,270,540,35)).front; a=SCDragSink(w,Rect(20,0,450,20)); a.string="..drag a file here to output a string.."; a.receiveDragHandler={|i| sf=SoundFile.new; sf.openRead(SCView.currentDrag[0].asString); sf.path.postln; sf.numFrames.postln; sf.numChannels.postln; sf.sampleRate.postln; }; }.defer(0.1); hjh On May 1, 2009, at 8:14 AM, Marinos Koutsomichalis wrote: this code : : H. James Harkins .::!:.:.......:.::........:..!.::.::...:..:...:.:.:.:..: "Come said the Muse, Sing me a song no poet has yet chanted, Sing me the universal." -- Whitman |