Re: OT: Looking for a new programming language?

2018-07-27 Thread Stephen Barncard via use-livecode
And does that violate the terms of service!?

On Fri, Jul 27, 2018 at 19:18 Monte Goulding via use-livecode <
use-livecode@lists.runrev.com> wrote:

> Ahaha… are you doing the LiveCode implementation?
>
> > On 28 Jul 2018, at 2:51 am, Mark Wieder via use-livecode <
> use-livecode@lists.runrev.com> wrote:
> >
> >
> > "But why?
> > Mainly because if we make Rockstar a real (and completely pointless)
> programming language, then recruiters and hiring managers won't be able to
> talk about 'rockstar developers' any more."
> >
> > https://boingboing.net/2018/07/25/hello-cleveland-world.html
> > https://github.com/dylanbeattie/rockstar
> >
> > --
> > Mark Wieder
> > ahsoftw...@gmail.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
>
>
> ___
> 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

-- 
--
Stephen Barncard - Sebastopol Ca. USA -
mixstream.org
___
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: OT: Looking for a new programming language?

2018-07-27 Thread Monte Goulding via use-livecode
Ahaha… are you doing the LiveCode implementation?

> On 28 Jul 2018, at 2:51 am, Mark Wieder via use-livecode 
>  wrote:
> 
> 
> "But why?
> Mainly because if we make Rockstar a real (and completely pointless) 
> programming language, then recruiters and hiring managers won't be able to 
> talk about 'rockstar developers' any more."
> 
> https://boingboing.net/2018/07/25/hello-cleveland-world.html
> https://github.com/dylanbeattie/rockstar
> 
> -- 
> Mark Wieder
> ahsoftw...@gmail.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


___
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: Checking if internet is connected using tsNet?

2018-07-27 Thread Sannyasin Brahmanathaswami via use-livecode
Well the use case differences are obvious, but to say the obvious

I am connecting with

a) our own server
b) YouTube

that’s it. 

AND I want to know if the URL in the app is correct (silly typo in a JSON in 
the app OR misfiled media on out server...etc), so I would always to get the 
header of the actual media being called. We can traps errors, send to the 
MotherShip the URL that failed and fix it... etc.

That different from (Klaus's ?) "am I connected or not"

BR

On 7/27/18, 12:44 PM, "use-livecode on behalf of Mark Wieder via use-livecode" 
 wrote:

> if  (tResult < 400) then
>return true
> else
>return false
> end if

I'd be a little wary of that "< 400" result though. You may (or may not) 
want to follow redirects, and if you get a 418 you may want a cuppa .

and due to the extra hops involved, I probably wouldn't try for 
"https://www.google.com;. DNS resolution will add tens to over a hundred 
milliseconds to a web command, so if you're going to go that route 
instead of opening a socket I'd go straight to "http://8.8.8.8:53;.

curl -v --trace-time 8.8.8.8:53
20 milliseconds

curl -v --trace-time www.google.com
50 milliseconds

But otherwise, yes... there is no way of checking for the internet 
without connecting to the internet.

___
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: ANN: *** targetSdkVersion requirements Android ***

2018-07-27 Thread Mark Wieder via use-livecode

On 07/27/2018 04:12 PM, Mark Waddingham via use-livecode wrote:

Because before you can have a cross platform anything (which is tied to 
specific OS features) you need the things to call which perform the appropriate 
action on the individual platforms.


Not necessarily. I often stub out functions and then flesh them out as I 
go. I realize you're going to do it your way anyway, just was curious 
about the reasoning. No worries.


--
 Mark Wieder
 ahsoftw...@gmail.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


Re: ANN: *** targetSdkVersion requirements Android ***

2018-07-27 Thread Mark Waddingham via use-livecode
Because before you can have a cross platform anything (which is tied to 
specific OS features) you need the things to call which perform the appropriate 
action on the individual platforms.

The patterns for 'getting user consent' on android and iOS are similar (because 
they are both about 'getting user consent') but not identical.

The immediate issue is android so we implement that now.

It may or may not be useful on iOS - that is yet to be determined.

If it is then we add iphoneRequestPermission...

And then mobileRequestPermission can be an LCS handler which maps whatever 
universal permission groups exist from universal names to platform specific 
names.

The bit which must be in a lower level language at present goes in the engine - 
the bit which doesn't need to be, goes in LCS.

Platform dependent stuff has to be done from the bottom up to have any chance 
of being correct (essentially) - and it's better to expose the lower level 
features that build cross platform support and build the cross platform aspect 
in a language where iteration to get it right is far far easier (i.e. LCS). [ 
And, indeed more accessible to anyone who knows LCS ].

Warmest Regards,

Mark.

P.S. Given that requesting user permissions is a UI interaction the overhead of 
LCS here is entirely irrelevant.

Sent from my iPhone

> On 27 Jul 2018, at 23:55, Mark Wieder via use-livecode 
>  wrote:
> 
>> On 07/27/2018 09:13 AM, Mark Waddingham via use-livecode wrote:
>> 
>> P.S. We could look into doing something similar with iOS with regards 
>> explicitly
>> being able to ask for permission for things - in a similar way proposed 
>> above. If
>> people feel there is a need for it, please file an enhancement request and 
>> we'll
>> see what we can do. (At the moment we propose to add an 
>> androidRequestPermission
>> command - but we could add an iphone one too at some point, and then perhaps 
>> a
>> cross-platform one which tries to do its best to map the permission groups 
>> on android
>> to the similar things on iOS).
> 
> Q: Why would it not make sense to add a mobileRequestPermission command 
> instead at this point and have it work on Android now with the option of also 
> having it work on iOS later on? This rather than two different commands and 
> *then* later on make a cross-platform one? If necessary for engine code 
> compartmentalization there could be two non-exported commands for the 
> different platforms and only export the mobile one.
> 
> -- 
> Mark Wieder
> ahsoftw...@gmail.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


___
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: Data Persistence

2018-07-27 Thread Richard Gaskin via use-livecode

Mike Bonner wrote:

> On the subject of sqLite/memory databases and preferences/data
> persistence, rather than using an array, and doing the encode/decode
> stuff, would it make sense to do the following..
> 1. open an empty in memory database
> 2. attach a disk based database
> 3. copy the required table(s) from disk base to memory base
>
> At this point, for data reads you have a super fast sqlite in memory
> database.  For updates, do a double update, both in memory, and disk.

Whether using LC-native LSON or going through the externals interface to 
manage the SQLite RDBMS, getting any data from disk always has 
tradeoffs, sometimes favoring one method over another.


ArrayEncode is a single function call, so it's not like it's onerous to use.

SQLite's b-tree is a good one, so while the steps needed internally to 
traverse it are vastly more complex than the steps needed to traverse an 
array's hash, both are handled in machine-compiled C so it's not a big 
deal either way.


This reiterates the point I'd made earlier:
> It seems like this would be more efficient than re-encoding an array
> every time there is an update and writing the whole thing out to disk
> each time, rather than updating just whatever small change might need
> to be made to sqlite.

This is the upside of an RDBMS's complex b-tree: disk paging.  As I'd 
written earlier, if the data size is large enough that LC's machine-code 
serialization is slower than SQLite's SQL parsing + machine-code b-tree 
traversal, then SQLite would be the winner in that instance where raw 
performance may offset the additional requirement mixing SQL scripting 
with LC Script, and of no longer having a completely self-contained EXE 
(only Mac embeds externals and drivers within the bundle; Win and Linux 
at that point require use of an installer to install the multiple parts 
where the standalone can find them and the user won't mess with them).


You'd be surprised how fast LC is for many things, though. I've written 
routines using flat files that were able to do simple queries in LC 
Script about 20% faster than SQLite.


But even there, it's about project requirement.  If you need richer 
querying relying on relationality, nothing scripted in LC will come 
close in raw performance to the well-honed relational engine in SQLite.


But also, remember that the file system itself is a b-tree-based storage 
system, well optimized for general use, automatically ACID (in journaled 
file systems), and super easy to use.  Clustering as with Canela's 
LiveCloud DB, or even as separate file per document/record, can be quite 
efficient for some needs.


SQLite is a wonderful toolkit.  But with so many ways to store, 
retrieve, and work with data, we can pick and choose for the task at hand.


At a certain point, discussions about "SQL vs solution here>" are too similar to those of the NoSQL world last decade 
when those started taking off.  None of the many passionate arguments 
have managed to rid the world of MongoDB, CouchDB, Neo4J, or any other 
non-SQL storage system, nor have they displaced the valuable role of a 
good RDBMS where relationality is needed.  We have more options today 
than ever before, so we can pick whatever gets the job done.


--
 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


Re: Data Persistence

2018-07-27 Thread Mark Wieder via use-livecode

On 07/27/2018 02:58 PM, Mike Bonner via use-livecode wrote:

Your Bran. will be assimilated. (borg zombies FTW)


Yes. More brains please.

--
 Mark Wieder
 ahsoftw...@gmail.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


Re: ANN: *** targetSdkVersion requirements Android ***

2018-07-27 Thread Mark Wieder via use-livecode

On 07/27/2018 09:13 AM, Mark Waddingham via use-livecode wrote:

P.S. We could look into doing something similar with iOS with regards 
explicitly
being able to ask for permission for things - in a similar way proposed 
above. If
people feel there is a need for it, please file an enhancement request 
and we'll
see what we can do. (At the moment we propose to add an 
androidRequestPermission
command - but we could add an iphone one too at some point, and then 
perhaps a
cross-platform one which tries to do its best to map the permission 
groups on android

to the similar things on iOS).



Q: Why would it not make sense to add a mobileRequestPermission command 
instead at this point and have it work on Android now with the option of 
also having it work on iOS later on? This rather than two different 
commands and *then* later on make a cross-platform one? If necessary for 
engine code compartmentalization there could be two non-exported 
commands for the different platforms and only export the mobile one.


--
 Mark Wieder
 ahsoftw...@gmail.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


Re: Data Persistence

2018-07-27 Thread Richard Gaskin via use-livecode

Bob Sneidar wrote:

> I tried reading an "LSON" format, but it's not straight forward. It's
> easier to simply arrayDecode the LSON and work with the array.

I think there's a misunderstanding here:  LSON *is* the standard LC 
encoded array.


--
 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


Re: Data Persistence

2018-07-27 Thread Richard Gaskin via use-livecode

J. Landman Gay wrote:
> On 7/27/18 2:26 PM, Richard Gaskin via use-livecode wrote:
>> if the result is empty then
>>return "Error in getTempSavedParams: "& the result for error
>> end if
>
> I believe you had a thinko: "not empty", yes?

Indeed I did - thanks.

--
 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


Re: Data Persistence

2018-07-27 Thread Brian Milby via use-livecode
Use case is a major driver though.  If you have no need to hand edit a
file, then LSON is an efficient and easy way to store the data.  It also
has the benefit of being able to easily store binary data if needed.

On Fri, Jul 27, 2018 at 5:40 PM, Richard Gaskin via use-livecode <
use-livecode@lists.runrev.com> wrote:

> Alex Tweedly wrote:
>
> On 27/07/2018 20:17, Richard Gaskin via use-livecode wrote:
>>
>>>
>>> >  Using arrays intigues me, especially if I can just keep it in RAM (It
>>> > is a small amount of data for sure).
>>>
>>> One great thing about LC's built-in support for arrays is that it's
>>> built-in.
>>>
>>> JSON has become used in so many other languages that we've forgotten why
>>> it was invented:  to serialize JavaScript objects as simply and efficiently
>>> as possible using features already built into the JavaScript interpreter.
>>>
>>> LSON is that for us, as much a with-the-grain approach to data handling
>>> in LiveCode as JSON is for JavaScript.
>>>
>> I just wish there was a human-readable, human-editable-in-a-text-editor
>> variant of LSON :-)
>>
>
> True, LSON is even closer to BSON ("Binary JSON") than JSON itself, with
> all the machine-parsing efficiencies inherent in a binary format.
>
> The world wanted a human-readable/writable form of JSON too, so YAML was
> invented. :)
>
> --
>  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
>
___
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: Checking if internet is connected using tsNet?

2018-07-27 Thread Mark Wieder via use-livecode

On 07/27/2018 10:48 AM, Sannyasin Brahmanathaswami via use-livecode wrote:


if  (tResult < 400) then
   return true
else
   return false
end if


I'd be a little wary of that "< 400" result though. You may (or may not) 
want to follow redirects, and if you get a 418 you may want a cuppa .


and due to the extra hops involved, I probably wouldn't try for 
"https://www.google.com;. DNS resolution will add tens to over a hundred 
milliseconds to a web command, so if you're going to go that route 
instead of opening a socket I'd go straight to "http://8.8.8.8:53;.


curl -v --trace-time 8.8.8.8:53
20 milliseconds

curl -v --trace-time www.google.com
50 milliseconds

But otherwise, yes... there is no way of checking for the internet 
without connecting to the internet.


--
 Mark Wieder
 ahsoftw...@gmail.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


Re: Data Persistence

2018-07-27 Thread Richard Gaskin via use-livecode

Sannyasin Brahmanathaswami wrote:

> Richard wrote " If that native form is an array, there may be no need
> to do anything more than what LC already gives us straight out of the
> box."
>
> I have been toying with this for some time, but like Alex said..
>
> "I just wish there was a human-readable, human-editable-in-a-text-
> editor variant of LSON :-)"
>
> Keeps me in JSON

How often do you hand-edit array data?

Even JSON was found too cumbersome for efficient human reading/writing, 
so YAML came along to fill that gap where human editing of raw data is a 
priority.


One of the great things about computing in the 21st century is that we 
have so many options to choose from, selecting the best fit for the 
balance of human editing vs runtime efficiency as a given project requires.


--
 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


Re: Data Persistence

2018-07-27 Thread Richard Gaskin via use-livecode

Alex Tweedly wrote:


On 27/07/2018 20:17, Richard Gaskin via use-livecode wrote:


>  Using arrays intigues me, especially if I can just keep it in RAM (It
> is a small amount of data for sure).

One great thing about LC's built-in support for arrays is that it's 
built-in.


JSON has become used in so many other languages that we've forgotten 
why it was invented:  to serialize JavaScript objects as simply and 
efficiently as possible using features already built into the 
JavaScript interpreter.


LSON is that for us, as much a with-the-grain approach to data 
handling in LiveCode as JSON is for JavaScript.
I just wish there was a human-readable, human-editable-in-a-text-editor 
variant of LSON :-)


True, LSON is even closer to BSON ("Binary JSON") than JSON itself, with 
all the machine-parsing efficiencies inherent in a binary format.


The world wanted a human-readable/writable form of JSON too, so YAML was 
invented. :)


--
 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


Re: Data Persistence

2018-07-27 Thread Mike Bonner via use-livecode
On the subject of sqLite/memory databases and preferences/data persistence,
rather than using an array, and doing the encode/decode stuff, would it
make sense to do the following..
1. open an empty in memory database
2. attach a disk based database
3. copy the required table(s) from disk base to memory base

At this point, for data reads you have a super fast sqlite in memory
database.  For updates, do a double update, both in memory, and disk.

It seems like this would be more efficient than re-encoding an array every
time there is an update and writing the whole thing out to disk each time,
rather than updating just whatever small change might need to be made to
sqlite.

The affects and requirements would be similar. Update the array, (1 update)
ecode and write to disk (second update)  vs update in mem sqlite, and
update attached sqlite database.

Does my thinking make sense?

On Fri, Jul 27, 2018 at 4:11 PM Bob Sneidar via use-livecode <
use-livecode@lists.runrev.com> wrote:

> I tried reading an "LSON" format, but it's not straight forward. It's
> easier to simply arrayDecode the LSON and work with the array. And since
> you can convert the array to a memory sqLite database and back again with
> my handy dandy handlers, everybody wins!
>
> Bob S
>
>
> > On Jul 27, 2018, at 12:52 , Alex Tweedly via use-livecode <
> use-livecode@lists.runrev.com> wrote:
> >
> > On 27/07/2018 20:17, Richard Gaskin via use-livecode wrote:
> >
> >>
> >> >  Using arrays intigues me, especially if I can just keep it in RAM (It
> >> > is a small amount of data for sure).
> >>
> >> One great thing about LC's built-in support for arrays is that it's
> built-in.
> >>
> >> JSON has become used in so many other languages that we've forgotten
> why it was invented:  to serialize JavaScript objects as simply and
> efficiently as possible using features already built into the JavaScript
> interpreter.
> >>
> >> LSON is that for us, as much a with-the-grain approach to data handling
> in LiveCode as JSON is for JavaScript.
> > I just wish there was a human-readable, human-editable-in-a-text-editor
> variant of LSON :-)
> >
> > Someday, when I have some spare time, ...
> >
> > -- Alex.
>
>
> ___
> 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: Data Persistence

2018-07-27 Thread J. Landman Gay via use-livecode

On 7/27/18 2:26 PM, Richard Gaskin via use-livecode wrote:

if the result is empty then
   return "Error in getTempSavedParams: "& the result for error
end if


I believe you had a thinko: "not empty", yes?

--
Jacqueline Landman Gay | jac...@hyperactivesw.com
HyperActive Software   | http://www.hyperactivesw.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

Re: Data Persistence

2018-07-27 Thread Bob Sneidar via use-livecode
I tried reading an "LSON" format, but it's not straight forward. It's easier to 
simply arrayDecode the LSON and work with the array. And since you can convert 
the array to a memory sqLite database and back again with my handy dandy 
handlers, everybody wins! 

Bob S


> On Jul 27, 2018, at 12:52 , Alex Tweedly via use-livecode 
>  wrote:
> 
> On 27/07/2018 20:17, Richard Gaskin via use-livecode wrote:
> 
>> 
>> >  Using arrays intigues me, especially if I can just keep it in RAM (It
>> > is a small amount of data for sure).
>> 
>> One great thing about LC's built-in support for arrays is that it's built-in.
>> 
>> JSON has become used in so many other languages that we've forgotten why it 
>> was invented:  to serialize JavaScript objects as simply and efficiently as 
>> possible using features already built into the JavaScript interpreter.
>> 
>> LSON is that for us, as much a with-the-grain approach to data handling in 
>> LiveCode as JSON is for JavaScript.
> I just wish there was a human-readable, human-editable-in-a-text-editor 
> variant of LSON :-)
> 
> Someday, when I have some spare time, ...
> 
> -- Alex.


___
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: Checking if internet is connected using tsNet?

2018-07-27 Thread Bob Sneidar via use-livecode
And don't forget my telnet technique. Telnet will tell you if there is a basic 
connection without "actually" connecting with a protocol of any sort. So it 
doesn't suffer from any of the built in timeouts that web protocols must have 
to work properly. 

Bob S


> On Jul 27, 2018, at 10:53 , Richard Gaskin via use-livecode 
>  wrote:
> 
> Klaus wrote:
> 
> >> Define "valid"...
> >
> > Sorry, I meant if the machine is currently connected to the internet.
> > And if an URL actually does exist = "valid".
> 
> Assuming the protocol in question is HTTP/S, a request to a non-existent 
> resource should return "404" in the error string provided in "the result".   
> If "the result" is empty the resource was retrieved as expected.
> 
> -- 
> Richard Gaskin
> Fourth World Systems
> Software Design and Development for the Desktop, Mobile, and the Web


___
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: Data Persistence

2018-07-27 Thread Mike Bonner via use-livecode
Your Bran. will be assimilated. (borg zombies FTW)

On Fri, Jul 27, 2018 at 3:39 PM J. Landman Gay via use-livecode <
use-livecode@lists.runrev.com> wrote:

> On 7/27/18 12:47 PM, John McKenzie via use-livecode wrote:
> >   Tom, thank you for welcoming me. Much different than some online
> > programming groups. :-)
>
> We love new users, it's more brains for the collective. :)
>
> --
> Jacqueline Landman Gay | jac...@hyperactivesw.com
> HyperActive Software   | http://www.hyperactivesw.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
>
___
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: ANN: *** targetSdkVersion requirements Android ***

2018-07-27 Thread Bob Sneidar via use-livecode
Another regression I noticed is that I am back to red dot breakpoints clearing 
after a script save/compile. The dots are there but the script does not break. 
Unsetting and resetting causes the debugger to break again. 

Bob S


> On Jul 27, 2018, at 09:13 , Mark Waddingham via use-livecode 
>  wrote:
> 
> On 2018-07-26 06:02, Colin Holgate via use-livecode wrote:
>> One problem this may introduce is that from Android 6 onwards you’re
>> expected to only ask permission to use features at the time the user
>> reaches that part of your app, like it has always been on iOS. I wrote
>> about publishing to Android before Android 6, I’m not sure how that
>> gets handled. Are there features in LiveCode to cover the difficulty
>> of asking for permission at runtime instead of when the app is
>> installed?
> 
> 9.0.1-rc-1 changes the engine to build against the appropriate minimum now so
> we are almost there.
> 
> However, we had noticed the above - admittedly due to a regression in 
> 9.0.1-rc-1 with
> regards to the camera - so we have (well Panos) has been working hard to
> resolve that.

___
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: Data Persistence

2018-07-27 Thread J. Landman Gay via use-livecode

On 7/27/18 12:47 PM, John McKenzie via use-livecode wrote:

  Tom, thank you for welcoming me. Much different than some online
programming groups. :-)


We love new users, it's more brains for the collective. :)

--
Jacqueline Landman Gay | jac...@hyperactivesw.com
HyperActive Software   | http://www.hyperactivesw.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


Re: Data Persistence

2018-07-27 Thread Sannyasin Brahmanathaswami via use-livecode
Richard Gaskin 
This is where serialization comes in, collecting all the disparate 
pointer contents and packing them into a bytestream that can be saved or 
transported, using arrayEncode:

Ha! I knew that would bring out something useful... thanks for upgrading the 
handlers.

Richard wrote " If that native form is an array, there may be no need to do 
anything
more than what LC already gives us straight out of the box."

I have been toying with this for some time, but like Alex said..

"I just wish there was a human-readable, human-editable-in-a-text-editor
variant of LSON :-)"

Keeps me in JSON

BR


___
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: Data Persistence

2018-07-27 Thread Alex Tweedly via use-livecode

On 27/07/2018 20:17, Richard Gaskin via use-livecode wrote:



>  Using arrays intigues me, especially if I can just keep it in RAM (It
> is a small amount of data for sure).

One great thing about LC's built-in support for arrays is that it's 
built-in.


JSON has become used in so many other languages that we've forgotten 
why it was invented:  to serialize JavaScript objects as simply and 
efficiently as possible using features already built into the 
JavaScript interpreter.


LSON is that for us, as much a with-the-grain approach to data 
handling in LiveCode as JSON is for JavaScript.
I just wish there was a human-readable, human-editable-in-a-text-editor 
variant of LSON :-)


Someday, when I have some spare time, ...

-- Alex.



___
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: Data Persistence

2018-07-27 Thread Richard Gaskin via use-livecode

Sannyasin Brahmanathaswami wrote:

>   (rough draft code)
>
> Local sTempParamArray # may good to save a local,
>
> Command saveTempParams
>
>Put fld "fuelNeed" into  pTempParamArray["fuelNeeded'}
>Put fld "timeToArrival" into  pTempParamArray["timeToArrival""
># etc.
>Put pTempParamArray into sTempParamArray
>storeTempParams pTempParamArray
>
> End saveTempParams
>
> command storeTempParams pTempParamArray
>
> 	put   specialFolderPath("documents") & "/tempSavedParams" into 
tSavedPath

>put sTempParamArray into url ("binfile:" & tSavedPath)
>
> end storeTempParams

A good outline, but missing a key step:  arrays are collections of 
pointers and in their native form are not a contiguous bytestream, so 
attempting to write one to disk directly with yield an empty file.


This is where serialization comes in, collecting all the disparate 
pointer contents and packing them into a bytestream that can be saved or 
transported, using arrayEncode:


command storeTempParams pTempParamArray
  put specialFolderPath("documents") & "/tempSavedParams" into \
 tSavedPath
  put arrayEncode(sTempParamArray) into url ("binfile:" & tSavedPath)
end storeTempParams


And because arrayDecode will throw a fatal error if you attempt to use 
it with anything other than actual LSON data, we can't just check "the 
result" afterward; better to wrap it in a try/catch:


Function getTempSavedParams
  Put specialFolderPath("documents") & "/tempSavedParams" into \
 tSavedPath
  put url ("binfile:" & tSavedPath) into pTempParamArray
  -- Always check I/O for errors:
  if the result is empty then
 return "Error in getTempSavedParams: "& the result for error
   end if
   -- Try as LSON:
   try
 put arrayDecode(pTempParamArray) into pTempParamArray
   catch tErr
 return "Not a valid array file: "& tSavedPath for error
   end try
   --
   return pTempParamArray
end getTempSavedParams


--
 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


Re: Data Persistence

2018-07-27 Thread Richard Gaskin via use-livecode

John McKenzie wrote:
>  Because I like word play I might make my own text file format, the
> "Extended Livecode Optimized Serialized Object Notation" format or
> ELSON. It adds just enough features to LSON to make identical to JSON.
> Being stupid and redundant it will be the hot new buzzword in the
> computing industry.

Buzzwords are important.  If you don't use enough of them you'll never 
find adequate funding. :)



>  Using arrays intigues me, especially if I can just keep it in RAM (It
> is a small amount of data for sure).

One great thing about LC's built-in support for arrays is that it's 
built-in.


JSON has become used in so many other languages that we've forgotten why 
it was invented:  to serialize JavaScript objects as simply and 
efficiently as possible using features already built into the JavaScript 
interpreter.


LSON is that for us, as much a with-the-grain approach to data handling 
in LiveCode as JSON is for JavaScript.


ELSON and any number of other variants can be fun, but what will you do 
with the deserialized native form as you work with it in your program? 
If that native form is an array, there may be no need to do anything 
more than what LC already gives us straight out of the box.


--
 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


Re: Data Persistence

2018-07-27 Thread John McKenzie via use-livecode


 Thanks for the extra comments everyone. Glad my thought process was
correct, databse is overkill, saving every text change is too much,
etc, etc.

 As I said I will not be able to really do anything until next week.

 Thanks for mentioning the closeField command guys. I will check it
out, but the name sounds like it explains it, loose focus on the field,
field is closed, handling activated.

 Because I like word play I might make my own text file format, the
"Extended Livecode Optimized Serialized Object Notation" format or
ELSON. It adds just enough features to LSON to make identical to JSON.
Being stupid and redundant it will be the hot new buzzword in the
computing industry.


 Using arrays intigues me, especially if I can just keep it in RAM (It
is a small amount of data for sure).

 Thanks for your continued help everyone. Off to super busy weekend
planning and working on an event for Sunday. Will update you/ask
follow-ups next week.




___
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: Data Persistence

2018-07-27 Thread Sannyasin Brahmanathaswami via use-livecode
Welcome John!

You will need this, I would endorse Tom's arrayEncode.  

If you have not: Learn to array code RIGHT NOW, before going further with 
Livecode. I resisted array for years, and it bought me a boat load of silly 
coding of text files. And 100 of lines of unnecessary code then I  are 
learned about arrays. I broke my head of the desk.. saying "oh wow is me! I 
have could have saved thousand of hours and lines of codes if use arrays from 
the beginning!" (ha)

  (rough draft code)


Local sTempParamArray # may good to save a local, 

Command saveTempParams

Put fld "fuelNeed" into  pTempParamArray["fuelNeeded'} 
Put fld "timeToArrival" into  pTempParamArray["timeToArrival""
# etc.
Put pTempParamArray into sTempParamArray
storeTempParams pTempParamArray

End saveTempParams

command storeTempParams pTempParamArray 

put   specialFolderPath("documents") & "/tempSavedParams" into  
tSavedPath
put sTempParamArray into url ("binfile:" & tSavedPath)

end storeTempParams

# you will have some trigger get them back, I don't know what that would be:

Function getTempSavedParams

Put   specialFolderPath("documents") & "/tempSavedParams" into  
tSavedPath
put url ("binfile:" & tSavedPath) into pTempParamArray
put pTempParamArray into sTempParamArray
return pTempParamArray

end getTempSavedParams

command reLoadSettings

put getTempSavesParams() into pLastParams
put pLastParams["fuelNeeded"] into # whatever
put pLastParams["timeToArrival"] into # whatever
# etc.

End reLoadSettings

# code is a little verbose but easy to debug later.
# other wizards can improve on my baby xTalk
 
BR 

On 7/23/18, 11:57 AM, "use-livecode on behalf of John McKenzie via 
use-livecode"  wrote:

What I need help with is the issue of persistence. 

___
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: Data Persistence

2018-07-27 Thread Richard Gaskin via use-livecode

John McKenzie wrote:

> An SQLite database seems like extreme overkill but I will give it
> a try if it is needed to get the app to work.

SQLite is very feature-rich, but if you don't need the relationality 
provided by a full-featured RDBMS it can be like swatting flies with a 
grenade launcher.


Persistence can be provided by any format that can be written to disk. 
You may be surprised by how many programs use simple flat text files. 
And in LC, arrays are easy and efficient to work with, and can be 
serialized to disk with arrayEncode (resulting in files I affectionately 
call "LSON", a LiveCode-optimized alternative to the 
JavaScript-optimized JSON).


Indeed, many who use an RDBMS write code to return the result of queries 
in the form of an LC array.  If you don't need the relationality, and if 
your data is of a size that fits comfortably in RAM, using an array 
directly is about as simple as it can be.


If your data does not fit comfortably in RAM, you may find that breaking 
it into multiple LSON files can work quite nicely.



> Does this require me to pre-install any sort of database software?

Selecting the SQLite driver in the Standalone Build should be all that's 
needed.



>  Brian, I gathered from your post that the only way to work with a
> text file as data storage on Android is to save every time a field
> is changed? How would I do this in such a way that it knows to save
> when "1421" is typed as a time of day as opposed to the app trying
> to save it after "1" is typed, then again when "2" is typed, etc.
> Or perhaps there is no way and I have to re-save every time a
> character it typed.

Finding appropriate auto-save triggers is the third hard thing in 
computing (the first two being cache invalidation and naming things ).


Saving on every keystroke may be overkill. Saving on closeField may 
suffice when the contents of each field do not contain much data.  If 
you have a long field in which a user may spend significant time, you 
may consider a periodic timer for saving as a middle path between 
closeField and textChanged.


--
 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


Re: Checking if internet is connected using tsNet?

2018-07-27 Thread Klaus major-k via use-livecode
Hi Richard,

> Am 27.07.2018 um 19:53 schrieb Richard Gaskin via use-livecode 
> :
> 
> Klaus wrote:
> >> Define "valid"...
> >
> > Sorry, I meant if the machine is currently connected to the internet.
> > And if an URL actually does exist = "valid".
> Assuming the protocol in question is HTTP/S,

yes.

> a request to a non-existent resource should return "404" in the error string 
> provided in "the result".  
> If "the result" is empty the resource was retrieved as expected.

I treid with a non-existing url and got:
tsneterr: (6) Could not resolve host: www.ghghgtztztuoouummmb.com

No 404, but it is OK for me!

> -- 
> Richard Gaskin

Best

Klaus

--
Klaus Major
http://www.major-k.de
kl...@major-k.de


___
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: Checking if internet is connected using tsNet?

2018-07-27 Thread Klaus major-k via use-livecode
Hi Swami,

> Am 27.07.2018 um 19:48 schrieb Sannyasin Brahmanathaswami via use-livecode 
> :
> 
> I just went through  this in my app. Like Mark said, you do need to connect 
> to "something"
> I put a "ping.txt" on the server. It has one word "true".  Apple does the 
> same thing. Though they call it something else  "serviceAvailable" or 
> something like that and it has one word in it "available"

OK, that will work for your own server, but not in general.

> ===
> But with TSNet you can just "ping" for the url you are trying  get. By using 
> tsNetHeadSync, you don't have to down load the whole file. It will return 
> headers.
> 
> It is very fast, so with so much music and online links books  and youTube 
> videos, with users going in and out of wi-fi, they forgot their phone on 
> airport mode etc.  There is no way of knowing the user context. 
> 
> So I just implemented this in one of my main backscripts and call it *every* 
> time when try to connect. Turn out the was easy them expected. I only take a 
> few millisecond to get status. Charles did say that tsNetHeadSync was 
> probably the best way to go.
> 
> =
> function checkURLAvailable pSelectedURL 
> put  tsNetHeadSync(pSelectedURL, tSentHeaders, tResult, tBytes)  into 
> tHeaders  # into tHeaders
> 
>   ## get url pSelectedURL
>   if  (tResult < 400) then
>  return true
>   else
>  internetConnectionDown
>  return false
>   end if
> end checkURLAvailable
> 
> command internetConnectionDown
>   dialog_CustomMsg "Offline or Low Bandwidth"
>   exit top
> end internetConnectionDown
> 
> 
> If you don't have 
> 
> a) a ping 
> b) you want test without a URL
> 
> Just use  "https://www.google.com;
> 
> function checkURLAvailable "https://www.google.com;
> 
> put  tsNetHeadSync(pSelectedURL, tSentHeaders, tResult, tBytes)  into 
> tHeaders  
> 
>   ## get url pSelectedURL header
> 
>   if  (tResult < 400) then
>  return true
>   else
>  return false
>   end if
> end checkURLAvailable
> 
> if Google down, so is the whole internet. (smile)
> 
> Almond cheese, please.

:-D

Cool, thanks a lot for thi info!
Please tell Mark W. about it, too! 8-)

> BR
> 
> On 7/26/18, 4:40 AM, "use-livecode on behalf of Klaus major-k via 
> use-livecode"  use-livecode@lists.runrev.com> wrote:
> 
>can we possibly "mis-"use tsNet somehow to check if the 
>current machine has a valid internet connection? 
>And to check if a given URL is valid?

Best

Klaus

--
Klaus Major
http://www.major-k.de
kl...@major-k.de


___
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: Checking if internet is connected using tsNet?

2018-07-27 Thread Richard Gaskin via use-livecode

Klaus wrote:

>> Define "valid"...
>
> Sorry, I meant if the machine is currently connected to the internet.
> And if an URL actually does exist = "valid".

Assuming the protocol in question is HTTP/S, a request to a non-existent 
resource should return "404" in the error string provided in "the 
result".   If "the result" is empty the resource was retrieved as expected.


--
 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


Re: Data Persistence

2018-07-27 Thread Klaus major-k via use-livecode
Hi John,

> Am 27.07.2018 um 19:47 schrieb John McKenzie via use-livecode 
> :
> 
> Tom, thank you for welcoming me. Much different than some online
> programming groups. :-)
> 
> Brian and Tom thank you for your replies about my Android data
> persistence problem. An SQLite database seems like extreme overkill but
> I will give it a try if it is needed to get the app to work. Does this
> require me to pre-install any sort of database software?

nope, unlike batteries, everything is included in LC! :-)

> Brian, I gathered from your post that the only way to work with a text
> file as data storage on Android is to save every time a field is
> changed? How would I do this in such a way that it knows to save when
> "1421" is typed as a time of day as opposed to the app trying to save
> it after "1" is typed, then again when "2" is typed, etc. Or perhaps
> there is no way and I have to re-save every time a character it typed.

Save "on closefield", means when the user has finished typing and "leaves" the 
field.

>  I am super duper busy this week, especially this weekend. Will really
> get back to the problem in earnest next week.

Whatever... :-)


Best

Klaus

--
Klaus Major
http://www.major-k.de
kl...@major-k.de


___
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: Checking if internet is connected using tsNet?

2018-07-27 Thread Sannyasin Brahmanathaswami via use-livecode
I just went through  this in my app. Like Mark said, you do need to connect to 
"something"

I put a "ping.txt" on the server. It has one word "true".  Apple does the same 
thing. Though they call it something else  "serviceAvailable" or something like 
that and it has one word in it "available"

===
But with TSNet you can just "ping" for the url you are trying  get. By using 
tsNetHeadSync, you don't have to down load the whole file. It will return 
headers.

 It is very fast, so with so much music and online links books  and youTube 
videos, with users going in and out of wi-fi, they forgot their phone on 
airport mode etc.  There is no way of knowing the user context. 

So I just implemented this in one of my main backscripts and call it *every* 
time when try to connect. Turn out the was easy them expected. I only take a 
few millisecond to get status. Charles did say that tsNetHeadSync was probably 
the best way to go.

=
function checkURLAvailable pSelectedURL 
 put  tsNetHeadSync(pSelectedURL, tSentHeaders, tResult, tBytes)  into tHeaders 
 # into tHeaders
  
   ## get url pSelectedURL
   if  (tResult < 400) then
  return true
   else
  internetConnectionDown
  return false
   end if
end checkURLAvailable

command internetConnectionDown
   dialog_CustomMsg "Offline or Low Bandwidth"
   exit top
end internetConnectionDown


If you don't have 

a) a ping 
b) you want test without a URL

Just use  "https://www.google.com;

function checkURLAvailable "https://www.google.com;

 put  tsNetHeadSync(pSelectedURL, tSentHeaders, tResult, tBytes)  into tHeaders 
 
  
   ## get url pSelectedURL header

   if  (tResult < 400) then
  return true
   else
  return false
   end if
end checkURLAvailable

if Google down, so is the whole internet. (smile)

Almond cheese, please.

BR


On 7/26/18, 4:40 AM, "use-livecode on behalf of Klaus major-k via 
use-livecode"  wrote:

can we possibly "mis-"use tsNet somehow to check if the 
current machine has a valid internet connection? 
And to check if a given URL is valid?

___
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: Data Persistence

2018-07-27 Thread John McKenzie via use-livecode


 Tom, thank you for welcoming me. Much different than some online
programming groups. :-)


 Brian and Tom thank you for your replies about my Android data
persistence problem. An SQLite database seems like extreme overkill but
I will give it a try if it is needed to get the app to work. Does this
require me to pre-install any sort of database software?

 Brian, I gathered from your post that the only way to work with a text
file as data storage on Android is to save every time a field is
changed? How would I do this in such a way that it knows to save when
"1421" is typed as a time of day as opposed to the app trying to save
it after "1" is typed, then again when "2" is typed, etc. Or perhaps
there is no way and I have to re-save every time a character it typed.


  I am super duper busy this week, especially this weekend. Will really
get back to the problem in earnest next week.


___
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: OT: Looking for a new programming language?

2018-07-27 Thread Stephen Barncard via use-livecode
No! Not another name change!
I still remember Runtime Revolution

On Fri, Jul 27, 2018 at 09:52 Mark Wieder via use-livecode <
use-livecode@lists.runrev.com> wrote:

>
> "But why?
> Mainly because if we make Rockstar a real (and completely pointless)
> programming language, then recruiters and hiring managers won't be able
> to talk about 'rockstar developers' any more."
>
> https://boingboing.net/2018/07/25/hello-cleveland-world.html
> https://github.com/dylanbeattie/rockstar
>
> --
>   Mark Wieder
>   ahsoftw...@gmail.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
>
-- 
--
Stephen Barncard - Sebastopol Ca. USA -
mixstream.org
___
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: Checking if internet is connected using tsNet?

2018-07-27 Thread Klaus major-k via use-livecode
Hi Mark,

> Am 27.07.2018 um 19:11 schrieb Mark Wieder via use-livecode 
> :
> On 07/27/2018 09:48 AM, Klaus major-k via use-livecode wrote:
>> Sorry, I meant if the machine is currently connected to the internet.
>> And if an URL actually does exist = "valid".
> So an active ethernet connection won't do the trick.
> And a valid address won't work either.
> I don't know of any way to validate that an address outside your local subnet 
> exists other than trying to connect to it.

too bad, thanks for the clarification!

So back to trying to load GOOGLE and checking for an error...

> -- 
> Mark Wieder
> ahsoftw...@gmail.com

Best

Klaus

--
Klaus Major
http://www.major-k.de
kl...@major-k.de


___
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: Checking if internet is connected using tsNet?

2018-07-27 Thread Mark Wieder via use-livecode

On 07/27/2018 09:48 AM, Klaus major-k via use-livecode wrote:


Sorry, I meant if the machine is currently connected to the internet.
And if an URL actually does exist = "valid".


So an active ethernet connection won't do the trick.
And a valid address won't work either.
I don't know of any way to validate that an address outside your local 
subnet exists other than trying to connect to it.


--
 Mark Wieder
 ahsoftw...@gmail.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


Re: OT: On-Rev cPanel (port 2083) access blocked by BT Smart Hub router?

2018-07-27 Thread Mark Wieder via use-livecode

On 07/27/2018 09:58 AM, Keith Clarke via use-livecode wrote:

Thanks Mark, I had found that thread but unfortunately that sits at the WHM 
server-level of cPanel to which only the mothership team have keys - for some 
reason we don’t get to play with server-wide config as on-rev shared hosting 
users ;-)

I doubt that on-rev support would be too keen to update server settings that 
could affect all users just because my router or ISP has blocked a port.

I’ll try a different router not supplied by my ISP, just in case they are 
restricting the router's menu.


Yeah, I was afraid this would get down to cPanel configs.
If you've got a fancy router you could possibly write a rule to forward 
port 443 to 2083 for the cPanel url only and that might have a chance of 
working...


--
 Mark Wieder
 ahsoftw...@gmail.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

Re: OT: On-Rev cPanel (port 2083) access blocked by BT Smart Hub router?

2018-07-27 Thread Keith Clarke via use-livecode
Thanks Mark, I had found that thread but unfortunately that sits at the WHM 
server-level of cPanel to which only the mothership team have keys - for some 
reason we don’t get to play with server-wide config as on-rev shared hosting 
users ;-)

I doubt that on-rev support would be too keen to update server settings that 
could affect all users just because my router or ISP has blocked a port.

I’ll try a different router not supplied by my ISP, just in case they are 
restricting the router's menu.
Thanks
Keith   

> On 27 Jul 2018, at 17:23, Mark Wieder via use-livecode 
>  wrote:
> 
> On 07/27/2018 09:06 AM, Keith Clarke via use-livecode wrote:
>> Hi folks,
>> Apologies for OT thread - but I’m hoping there may be a UK-based fellow 
>> on-rev hosting user, with BT Broadband + Smart Hub, who can confirm whether 
>> any router tweaks are needed to access port 2083 (for on-rev cPanel), which 
>> seems to be blocked from any device on my home network (BT Broadband & Smart 
>> Hub)?
> 
> Don't know if this will help, but apparently you're not alone in not being 
> able to access port 2083. If your router allows you to set proxy subdomains 
> then this might work.
> 
> https://forums.cpanel.net/threads/how-to-login-when-port-2083-is-blocked.553551/
> -- 
> Mark Wieder
> ahsoftw...@gmail.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


___
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

OT: Looking for a new programming language?

2018-07-27 Thread Mark Wieder via use-livecode



"But why?
Mainly because if we make Rockstar a real (and completely pointless) 
programming language, then recruiters and hiring managers won't be able 
to talk about 'rockstar developers' any more."


https://boingboing.net/2018/07/25/hello-cleveland-world.html
https://github.com/dylanbeattie/rockstar

--
 Mark Wieder
 ahsoftw...@gmail.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


Re: Checking if internet is connected using tsNet?

2018-07-27 Thread Klaus major-k via use-livecode
Hi Mark,

> Am 27.07.2018 um 18:44 schrieb Mark Wieder via use-livecode 
> :
> 
> On 07/27/2018 09:32 AM, Klaus major-k via use-livecode wrote:
>>> Am 26.07.2018 um 16:40 schrieb Klaus major-k via use-livecode 
>>> :
>>> 
>>> Hi friends,
>>> 
>>> can we possibly "mis-"use tsNet somehow to check if the
>>> current machine has a valid internet connection?
>>> And to check if a given URL is valid?
>>> 
>>> Thanks for any hints!
>> Cheese anyone? 8-)
> 
> Yum. Cheese.

I KNEW this would get some attention! :-)

> Define "valid"...

Sorry, I meant if the machine is currently connected to the internet.
And if an URL actually does exist = "valid".

> -- 
> Mark Wieder
> ahsoftw...@gmail.com

Best

Klaus

--
Klaus Major
http://www.major-k.de
kl...@major-k.de


___
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: Checking if internet is connected using tsNet?

2018-07-27 Thread Mark Wieder via use-livecode

On 07/27/2018 09:32 AM, Klaus major-k via use-livecode wrote:



Am 26.07.2018 um 16:40 schrieb Klaus major-k via use-livecode 
:

Hi friends,

can we possibly "mis-"use tsNet somehow to check if the
current machine has a valid internet connection?
And to check if a given URL is valid?

Thanks for any hints!


Cheese anyone? 8-)


Yum. Cheese.
Define "valid"...

--
 Mark Wieder
 ahsoftw...@gmail.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


Re: Checking if internet is connected using tsNet?

2018-07-27 Thread Klaus major-k via use-livecode


> Am 26.07.2018 um 16:40 schrieb Klaus major-k via use-livecode 
> :
> 
> Hi friends,
> 
> can we possibly "mis-"use tsNet somehow to check if the 
> current machine has a valid internet connection? 
> And to check if a given URL is valid?
> 
> Thanks for any hints!

Cheese anyone? 8-)

--
Klaus Major
http://www.major-k.de
kl...@major-k.de


___
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: OT: On-Rev cPanel (port 2083) access blocked by BT Smart Hub router?

2018-07-27 Thread Mark Wieder via use-livecode

On 07/27/2018 09:06 AM, Keith Clarke via use-livecode wrote:

Hi folks,
Apologies for OT thread - but I’m hoping there may be a UK-based fellow on-rev 
hosting user, with BT Broadband + Smart Hub, who can confirm whether any router 
tweaks are needed to access port 2083 (for on-rev cPanel), which seems to be 
blocked from any device on my home network (BT Broadband & Smart Hub)?


Don't know if this will help, but apparently you're not alone in not 
being able to access port 2083. If your router allows you to set proxy 
subdomains then this might work.


https://forums.cpanel.net/threads/how-to-login-when-port-2083-is-blocked.553551/
--
 Mark Wieder
 ahsoftw...@gmail.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

Re: ANN: *** targetSdkVersion requirements Android ***

2018-07-27 Thread Mark Waddingham via use-livecode

On 2018-07-26 06:02, Colin Holgate via use-livecode wrote:

One problem this may introduce is that from Android 6 onwards you’re
expected to only ask permission to use features at the time the user
reaches that part of your app, like it has always been on iOS. I wrote
about publishing to Android before Android 6, I’m not sure how that
gets handled. Are there features in LiveCode to cover the difficulty
of asking for permission at runtime instead of when the app is
installed?


9.0.1-rc-1 changes the engine to build against the appropriate minimum 
now so

we are almost there.

However, we had noticed the above - admittedly due to a regression in 
9.0.1-rc-1 with

regards to the camera - so we have (well Panos) has been working hard to
resolve that.

We're putting implicit permission requests in all the places that need 
them
(which parallels how iOS has been since around iOS8), and are intending 
on
adding a new android-specific command so you can request appropriate 
permissions
at any point before needing them to ensure apps can be designed to work 
nicely

regardless of what the user wants access to.

So thanks for the heads-up - we are working on it!

Warmest Regards,

Mark.

P.S. We could look into doing something similar with iOS with regards 
explicitly
being able to ask for permission for things - in a similar way proposed 
above. If
people feel there is a need for it, please file an enhancement request 
and we'll
see what we can do. (At the moment we propose to add an 
androidRequestPermission
command - but we could add an iphone one too at some point, and then 
perhaps a
cross-platform one which tries to do its best to map the permission 
groups on android

to the similar things on iOS).

--
Mark Waddingham ~ m...@livecode.com ~ http://www.livecode.com/
LiveCode: Everyone can create apps

___
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

OT: On-Rev cPanel (port 2083) access blocked by BT Smart Hub router?

2018-07-27 Thread Keith Clarke via use-livecode
Hi folks,
Apologies for OT thread - but I’m hoping there may be a UK-based fellow on-rev 
hosting user, with BT Broadband + Smart Hub, who can confirm whether any router 
tweaks are needed to access port 2083 (for on-rev cPanel), which seems to be 
blocked from any device on my home network (BT Broadband & Smart Hub)?

I’m no router/network expert but think it’s my router configuration, as:
I can reach the cPanel page using my phone’s mobile hotspot - i.e. avoiding my 
home router & ISP
The mothership’s hosting support team confirm that other on-rev users - and 
they themselves - are getting to cPanel OK via BT broadband services

Checking the Smart Hub router’s fairly limited settings (even in the ‘advanced’ 
area), there are no outbound blocking firewall settings in play and indeed, no 
outbound port management facility that I can find. 

I even experimented with port-forwarding 2083 direct to my Mac but that didn’t 
work - not that I expect it to, as my understanding of port-forwarding is for 
inbound traffic anyway.

Any ideas gratefully received.
Keith
___
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