Resent to include [ps] in the subject line...
At 11:51 -0700 30/4/02, John Harms wrote:
>DO: John Harms - photojhh@... - 30-Apr-2002
>Need a way for a pScript to tell if pedit is in List View or Edit
>View, for use with &ifscript.
>This is needed for pScripts that behave differently depending on the mode.
I agree it would be useful, but here are some work-arounds.
1. ESC-o exits the memo in EditView (i.e. goes to ListView), but does
nothing (not even an error dialogue) in ListView. So you can use
ESC-o to get pedit into a defined state.
2. If you really need the if-type stuff then it can be done as follows:
/! /$e /&varSet@ [$0, $$] /*get length of memo; set to a zero if
no text field*/
/&ifScript@ [$0!=0, @@Memo@@] /*length isn't zero, so its a memo*/
/&mess [@@list!!@@,,250] /*a message*/
/&mess [@@memo!!@@,,250] /*a message*/
The only problem with this script an empty memo (i.e. length zero)
which behaves as a list.
Hope that helps,