Re: How do I check to see if an environment variable exists?

2018-11-24 Thread Richard Gaskin via use-livecode

Stephen MacLean wrote:

> Looking to see how I check to see if my standalone was launch via
> command line with a parameter?
>
> I know that when it’s launched via command line with a parameter in
> windows, I will see a $0 (Name of executable) and $1 for the
> parameter.
...
> How would I test to see if the $1 variable exists?

   if "$1 is among the lines of the globalNames then ...

But that won't tell you if your app is running from the command line.

If the user double-clicks a document associated with your app, the OS 
will pass the path to the document to the app in $1.


To determine if an app is running facelessly from the command line 
(assuming you include -ui as an option with the command to bypass 
loading the GUI), see the environment function:


   if the environment is "command line" then ...

--
 Richard Gaskin
 Fourth World Systems
 Software Design and Development for the Desktop, Mobile, and the Web
 
 ambassa...@fourthworld.comhttp://www.FourthWorld.com

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Browser Widget Problem in Android

2018-11-24 Thread Mike for GDC via use-livecode
I have put a map browser widget in my app.  When I load the URL and try to
display it in my android, I just get a blank screen.  Attached are my
standalone settings.  

The app works on my desktop but NOT on the Android.  The browser URL is set
correctly, it just does not display.  Any suggestions as to what might be
wrong?

 

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: How to get physical coordinates of cursor in field

2018-11-24 Thread Kaveh Bazargan via use-livecode
I knew there was a simple answer! And it works so beautifully. :-) Thanks.

On Sat, 24 Nov 2018 at 16:39, J. Landman Gay via use-livecode <
use-livecode@lists.runrev.com> wrote:

> SelectedLoc.
> --
> Jacqueline Landman Gay | jac...@hyperactivesw.com
> HyperActive Software | http://www.hyperactivesw.com
> On November 24, 2018 8:08:36 AM Kaveh Bazargan via use-livecode
>  wrote:
>
> > I want to place a button at a position relative to the text cursor in a
> > field. How can I get the coordinates? Something like ClickLoc but for
> text
> > cursor.
> >
> > --
> > Kaveh Bazargan
> > Director
> > River Valley Technologies  •
> Twitter
> >  • LinkedIn
> > 
> > ___
> > use-livecode mailing list
> > use-livecode@lists.runrev.com
> > Please visit this url to subscribe, unsubscribe and manage your
> > subscription preferences:
> > http://lists.runrev.com/mailman/listinfo/use-livecode
>
>
>
>
> ___
> use-livecode mailing list
> use-livecode@lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your
> subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode



-- 
Kaveh Bazargan
Director
River Valley Technologies  • Twitter
 • LinkedIn

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: How do I check to see if an environment variable exists?

2018-11-24 Thread Stephen MacLean via use-livecode
Thanks all!

I am basically doing what Jacqueline does and check to see if empty and then 
verify against a list of switches.

It does seem strange that we can’t check for the existence of a variable, but 
this works.

Thanks,

Steve MacLean

> On Nov 24, 2018, at 11:35 AM, J. Landman Gay via use-livecode 
>  wrote:
> 
>> How would I test to see if the $1 variable exists?
> 
> I don't check for existence, I only check whether it's empty.
> --
> Jacqueline Landman Gay | jac...@hyperactivesw.com
> HyperActive Software | http://www.hyperactivesw.com
> On November 24, 2018 8:04:50 AM bob--- via use-livecode 
>  wrote:
> 
>> $# tells you how many parameters there are for a script. Perhaps if $# > 0 
>> then... instead might work (I’ve not tried that). You might find using 
>> environment() potentially helps as well. The Dictionary has the details. If 
>> neither of those options work let me know. I have another way you could 
>> tackle the issue.
>> 
>> - Bob Hall
>> 
>>> On Nov 23, 2018, at 5:27 PM, Stephen MacLean via use-livecode 
>>>  wrote:
>>> 
>>> However, the exists($1) never returns true, even when it should. Which 
>>> leads to to believe that’s not what I want to use.
>>> 
>>> How would I test to see if the $1 variable exists?
>> 
>> ___
>> use-livecode mailing list
>> use-livecode@lists.runrev.com
>> Please visit this url to subscribe, unsubscribe and manage your subscription 
>> preferences:
>> http://lists.runrev.com/mailman/listinfo/use-livecode
> 
> 
> 
> 
> ___
> use-livecode mailing list
> use-livecode@lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription 
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: How to get physical coordinates of cursor in field

2018-11-24 Thread J. Landman Gay via use-livecode

SelectedLoc.
--
Jacqueline Landman Gay | jac...@hyperactivesw.com
HyperActive Software | http://www.hyperactivesw.com
On November 24, 2018 8:08:36 AM Kaveh Bazargan via use-livecode 
 wrote:



I want to place a button at a position relative to the text cursor in a
field. How can I get the coordinates? Something like ClickLoc but for text
cursor.

--
Kaveh Bazargan
Director
River Valley Technologies  • Twitter
 • LinkedIn

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your 
subscription preferences:

http://lists.runrev.com/mailman/listinfo/use-livecode





___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: How do I check to see if an environment variable exists?

2018-11-24 Thread J. Landman Gay via use-livecode

How would I test to see if the $1 variable exists?


I don't check for existence, I only check whether it's empty.
--
Jacqueline Landman Gay | jac...@hyperactivesw.com
HyperActive Software | http://www.hyperactivesw.com
On November 24, 2018 8:04:50 AM bob--- via use-livecode 
 wrote:


$# tells you how many parameters there are for a script. Perhaps if $# > 0 
then... instead might work (I’ve not tried that). You might find using 
environment() potentially helps as well. The Dictionary has the details. If 
neither of those options work let me know. I have another way you could 
tackle the issue.


- Bob Hall

On Nov 23, 2018, at 5:27 PM, Stephen MacLean via use-livecode 
 wrote:


However, the exists($1) never returns true, even when it should. Which 
leads to to believe that’s not what I want to use.


How would I test to see if the $1 variable exists?


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your 
subscription preferences:

http://lists.runrev.com/mailman/listinfo/use-livecode





___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

How to get physical coordinates of cursor in field

2018-11-24 Thread Kaveh Bazargan via use-livecode
I want to place a button at a position relative to the text cursor in a
field. How can I get the coordinates? Something like ClickLoc but for text
cursor.

-- 
Kaveh Bazargan
Director
River Valley Technologies  • Twitter
 • LinkedIn

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: How do I check to see if an environment variable exists?

2018-11-24 Thread bob--- via use-livecode
$# tells you how many parameters there are for a script. Perhaps if $# > 0 
then... instead might work (I’ve not tried that). You might find using 
environment() potentially helps as well. The Dictionary has the details. If 
neither of those options work let me know. I have another way you could tackle 
the issue.

- Bob Hall

> On Nov 23, 2018, at 5:27 PM, Stephen MacLean via use-livecode 
>  wrote:
> 
> However, the exists($1) never returns true, even when it should. Which leads 
> to to believe that’s not what I want to use.
> 
> How would I test to see if the $1 variable exists?

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: LiveCode and Websockets

2018-11-24 Thread bob--- via use-livecode
Charles,

I would like to find out more about your socket external specifically for 
websockets. Can you point me to where I can find out about the socket external?

Thanks,
Bob Hall

> On Nov 23, 2018, at 1:10 AM, Charles Warwick via use-livecode 
>  wrote:
> 
> Hi Todd,
> 
> Depending on what platforms you need to support, I have a socket external for 
> LiveCode that includes the ability to use websockets.
> 
> Cheers,
> 
> Charles

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode