Panorama QNA Discussion

simple proc that wont work on panx

Gary A. Yonaites gary at yonaites.com
Friday, October 14th, 2016 @ 19:01:47 PDT
Try changing the one line to:

select arraycontains(ary,«»,sep)=true()



> On Oct 14, 2016, at 3:54 PM, Sam Rutherford <<A HREF="http://provue.com/mailman/listinfo/qna">samrutherford at musiccitymetals.net</A>> wrote:
> 
> 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> <mailto:<A HREF="http://provue.com/mailman/listinfo/qna">samrutherford at musiccitymetals.net</A>>
> 
> _______________________________________________
> Qna mailing list
> <A HREF="http://provue.com/mailman/listinfo/qna">Qna at provue.com</A>
> <A HREF="http://provue.com/mailman/listinfo/qna">http://provue.com/mailman/listinfo/qna</A>

—————————————— next part ——————————————
An HTML attachment was scrubbed...
URL: <<A HREF="http://provue.com/pipermail/qna/attachments/20161014/0dee07ed/attachment.html">http://provue.com/pipermail/qna/attachments/20161014/0dee07ed/attachment.html</A>>
—————————————— next part ——————————————
A non—text attachment was scrubbed...
Name: PastedGraphic—8.png
Type: image/png
Size: 1843 bytes
Desc: not available
URL: <<A HREF="http://provue.com/pipermail/qna/attachments/20161014/0dee07ed/attachment.png">http://provue.com/pipermail/qna/attachments/20161014/0dee07ed/attachment.png</A>>


Previous Next Previous Next (in Thread)