Test Variable?

Eric Chatonet eric.chatonet at sosmartsoftware.com
Fri Feb 10 17:58:13 EST 2006


Hi Garret,

function IsAPath pPath
   return (there is a file pPath)
end IsAPath

And:

if IsAPath(myVar) then... -- does exist a file with this url (locally  
or elsewhere)
else... -- does not exist a file with this url

Le 10 févr. 06 à 23:52, Garrett Hylltun a écrit :

>
>>> How do I test whether a variable is null or not?
>>>
>>
>> Null as in not yet initialized?
>>
>> Try this:
>>   if myVar is empty then ....
>
> Null as in empty, but already initialized onOpenStack.  What I'm  
> trying to accomplish is that if a text file path is sent to my .app  
> on OSX, that when my program opens, it grabs the command line and  
> puts it into a variable.  onOpen field needs to test if the  
> variable has anything at all in it, if it does, then take the path  
> and open the file and put it in the FieldEditor.
>
> Would
>
> if myVar is not empty then..
>
> work?

Best Regards from Paris,
Eric Chatonet
------------------------------------------------------------------------ 
----------------------
http://www.sosmartsoftware.com/    eric.chatonet at sosmartsoftware.com/





More information about the use-livecode mailing list