Panorama QNA Discussion

simple proc that wont work on panx

Sam Rutherford samrutherford at musiccitymetals.net
Friday, October 14th, 2016 @ 15:54:42 PDT
this is a proc i've been using for years. it works flawlessly in pan6 and i'm damned if i can see why it shouldnt work in panx.

to use it you copy an array to the clipboard, then tell the proc what the sep is, and it selects the array's elements in a db.
here's the code:

local ary, sep
sep=''
ary = clipboard()
gettext 'Separator? (if ¶, blank; if tab, 1).', sep
case sep = ''    sep = ¶
case sep = '1'    sep = ¬
endcase

select arraycontains(ary,«»,sep)
selectwithin «» ≠ ''

if info('empty') message 'No records selected.' +¶+ 'Reverting to previous selection.' endif



this does exactly nothing in panx unless the sep is a comma.
well that makes no sense, but i'm more interested in making it work than in trying to figure out why it doesnt, so i decided that if it wants a comma, i'll give it a comma.
to that end, i inserted this after the endcase
	if sep ≠ ','    ary = replace(ary, sep, ',')   endif

so now the proc should have the sep it wants and all should be well, but that isnt the way it went.
still nothing.

i then inserted this line, to see what the trouble was:
	message ary
this showed that the sep was still a ¶. the if statement had not executed.

oh, and when i try to step thru the proc, after it gets to ary = clipboard(), it goes back to the 1st step.



i realize this is child's play for most of you, but i could really use some help.

thanks, 
sam

________________________________________________________________
Sam Rutherford 
Music City Metals
615/255—4481
<A HREF="http://provue.com/mailman/listinfo/qna">samrutherford at musiccitymetals.net</A>


—————————————— next part ——————————————
An HTML attachment was scrubbed...
URL: <<A HREF="http://provue.com/pipermail/qna/attachments/20161014/b77151bd/attachment—0001.html">http://provue.com/pipermail/qna/attachments/20161014/b77151bd/attachment—0001.html</A>>


Previous Next Previous Next (in Thread)