Re: How do I get the ID of a database?

2021-07-12 Thread Bob Sneidar via use-livecode
That's what I ended up doing. I am so used to using sqlYoga, so the standard 
API took a little getting used to. 

Bob S


> On Jul 9, 2021, at 19:30 , Tom Glod via use-livecode 
>  wrote:
> 
> Hey Bob I don't understand the problem. Why don't you just store the ID
> in a persistent place? i think you are over complicating something here.
> Why can't YOU give it the name that you need and wnat it to be and then
> store the ID with that name somewhere?
> 
> Maybe I'm just misunderstanding the problem.


___
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: [iOS] possible console bug

2021-07-12 Thread matthias rebbe via use-livecode
Andre,

tested now with LC 9.6.3 and Xcode 12.4, as i am still on Catalina.  Took me 
some time to download Xcode.

i tried here with 2 different physical devices (iPhone 7 iOS 14.4 and iPhone 12 
iOS 14.6) and was able to see the output in the Console log pressing the 'open 
console' button in Xcode's 'Devices and Simulators' (shift CMD 2)

I selected my device in that tool and pressed 'open console'. I had the 'Now' 
mode activated and filtered for my output. I could see the output.

But i still do not see it when using the simulator.

Regards,
Matthias

 

> Am 12.07.2021 um 17:13 schrieb Andre Garzia via use-livecode 
> :
> 
> 
> 
>> On 12 Jul 2021, at 16:02, Mark Waddingham via use-livecode 
>>  wrote:
>> 
>> If you run the app on a real iOS device, do you see your log messages in the 
>> device log for it? Could it be Apple are now funneling simulator logs into a 
>> pane in Xcode - like they do for devices, rather than have them go to the 
>> macOS system log?
> 
> Running the app on a real device doesn’t show the log either. 
> 
> The organiser window of XCode has a specific “Open Console” button on the 
> pane for the device you selected. 
> 
> It opens the console and it doesn’t contain the data I’m trying to output 
> from LiveCode. You need to tell it to stream the console data from the phone, 
> it delivers a ton of garbage. Filtering by process or by the string I’m 
> sending — which is a fixed string at this point since I’m just trying to get 
> the console working — yields no result whatsoever.
> ___
> 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: [iOS] possible console bug

2021-07-12 Thread Andre Garzia via use-livecode


> On 12 Jul 2021, at 16:02, Mark Waddingham via use-livecode 
>  wrote:
> 
> If you run the app on a real iOS device, do you see your log messages in the 
> device log for it? Could it be Apple are now funneling simulator logs into a 
> pane in Xcode - like they do for devices, rather than have them go to the 
> macOS system log?

Running the app on a real device doesn’t show the log either. 

The organiser window of XCode has a specific “Open Console” button on the pane 
for the device you selected. 

It opens the console and it doesn’t contain the data I’m trying to output from 
LiveCode. You need to tell it to stream the console data from the phone, it 
delivers a ton of garbage. Filtering by process or by the string I’m sending — 
which is a fixed string at this point since I’m just trying to get the console 
working — yields no result whatsoever.
___
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: [iOS] possible console bug

2021-07-12 Thread matthias rebbe via use-livecode
The Simulator from Xcode 12.1  still shows the menu entry 'Show System Log..." 
under the Debug menu. That entry opens the "normal" system log.



> Am 12.07.2021 um 17:02 schrieb Mark Waddingham via use-livecode 
> :
> 
> On 2021-07-12 15:37, Andre Garzia via use-livecode wrote:
>> Mark,
>> That’s the problem, I’m looking at the system log on the iOS Simulator
>> and there is no output for put without a target.
> 
> Heh sorry - I didn't actually read the code you posted in your original post 
> :D
> 
> I believe this should work - `put ...` just gets sent to `NSLog` which should 
> emit to the relevant console.
> 
> If you run the app on a real iOS device, do you see your log messages in the 
> device log for it? Could it be Apple are now funneling simulator logs into a 
> pane in Xcode - like they do for devices, rather than have them go to the 
> macOS system log?
> 
> Warmest Regards,
> 
> Mark.
> 
> -- 
> 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


___
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: [iOS] possible console bug

2021-07-12 Thread Mark Waddingham via use-livecode

On 2021-07-12 15:37, Andre Garzia via use-livecode wrote:

Mark,

That’s the problem, I’m looking at the system log on the iOS Simulator
and there is no output for put without a target.


Heh sorry - I didn't actually read the code you posted in your original 
post :D


I believe this should work - `put ...` just gets sent to `NSLog` which 
should emit to the relevant console.


If you run the app on a real iOS device, do you see your log messages in 
the device log for it? Could it be Apple are now funneling simulator 
logs into a pane in Xcode - like they do for devices, rather than have 
them go to the macOS system log?


Warmest Regards,

Mark.

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


[iOS] possible bug with javascriptHandlers on iOS

2021-07-12 Thread Andre Garzia via use-livecode
I started a thread today about a possible bug with using “put without a target” 
on iOS. That bug appeared while I was trying to debug a problem with a mobile 
app we’re developing. It is an odd bug, we have it working on macOS Desktop 
inside the IDE and on Android, but it fails on iOS. The problem is a simple 
single like handler that executes something alone the lines of:

  do “liveCode.myapp_RecordScrollPosition(window.scrollY)” in widget “browser”

The handler is not named that of course but you get the idea. The 
“myapp_RecordScrollPosition” is in the message path, and is added to the 
“javascriptHandlers” property of the widget. The proof that the code is sound, 
is that it works on Android in a real device, and on desktop inside the IDE. 

I don’t understand why this code fails on iOS (both in the Simulator and on an 
iPhone 12 mini). 

Trying to debug this, I attempted to write to the console, so that I could see 
if the code is passing through the routines it should. I don’t have a business 
license, so I can use the remote debugger. I need to use old “put without 
target” calls. And then, they don’t work either.

I’ve already spent basically two days trying to debug why this fails. It fails 
silently. There is no error on LC side. I suspect it is something on the iOS 
WKWebView (or whatever is being used) side.

Anyone successfully calling LC from a browser widget on 9.6.3-rc-1 on iOS ?

Puzzled Regards
Andre
___
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: [iOS] possible console bug

2021-07-12 Thread Andre Garzia via use-livecode
Mark,

That’s the problem, I’m looking at the system log on the iOS Simulator and 
there is no output for put without a target.

Om om
A

> On 12 Jul 2021, at 15:14, Mark Waddingham via use-livecode 
>  wrote:
> 
> On 2021-07-12 15:01, Andre Garzia via use-livecode wrote:
>> but it is supposed to work, right? Did this changed in some version?
> 
> Apple stopped piping stdout/stderr to 'console' a few years ago I think - 
> both on Desktop, and when looking at the device console for iOS.
> 
> In version 9.0 though we changed the behavior of `put` without a target. e.g.
> 
>   put "foo"
> 
> In the IDE this will output to the message box.
> 
> In -ui mode, this will write to stderr.
> 
> Otherwise (which will be the case on iOS / Android!) this will output to the 
> system log
>   - using NSLog on Desktop/iOS
>   - using android.Log class on Android
>   - using OutpuDebugString on Win32
>   - using syslog on Linux
>   - using JS console on html5
> 
> Warmest Regards,
> 
> Mark.
> 
> -- 
> 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


___
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: [iOS] possible console bug

2021-07-12 Thread Mark Waddingham via use-livecode

On 2021-07-12 15:01, Andre Garzia via use-livecode wrote:

but it is supposed to work, right? Did this changed in some version?


Apple stopped piping stdout/stderr to 'console' a few years ago I think 
- both on Desktop, and when looking at the device console for iOS.


In version 9.0 though we changed the behavior of `put` without a target. 
e.g.


   put "foo"

In the IDE this will output to the message box.

In -ui mode, this will write to stderr.

Otherwise (which will be the case on iOS / Android!) this will output to 
the system log

   - using NSLog on Desktop/iOS
   - using android.Log class on Android
   - using OutpuDebugString on Win32
   - using syslog on Linux
   - using JS console on html5

Warmest Regards,

Mark.

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


Re: [iOS] possible console bug

2021-07-12 Thread Jimmieson, Phil via use-livecode
I think it changed at some point and you’re now supposed to use
  write  to stdout
though I just tried that and couldn’t get it to produce any output in the 
console.


On 12 Jul 2021, at 15:01, Andre Garzia via use-livecode 
mailto:use-livecode@lists.runrev.com>> wrote:

but it is supposed to work, right? Did this changed in some version?

On 12 Jul 2021, at 14:45, matthias rebbe via use-livecode 
mailto:use-livecode@lists.runrev.com>> wrote:

I tried here with  LC9.6.2 under Catalina. It doesn't work either.


Am 12.07.2021 um 14:49 schrieb Andre Garzia via use-livecode 
mailto:use-livecode@lists.runrev.com>>:

Hi Friends,

I’m writing here before I fill up a bug report because I don’t know if I’m 
doing things correctly.

From what I remember, if we did a “put” to stdout, it would appear in the 
system log on iOS Simulator. Is that still the case?

I have an empty stack here with a button with the following script:

on mouseUp
put “this doesn’t work.”
put “it still doesn’t work”
end mouseUp

When I run that stack on the iOS Simulator, and select the “system log” menu 
item from the Simulator application, I can see a log of debug information but I 
can’t see any of my own “put” messages. No matter how many times I click the 
button.

Wasn’t that supposed to work?

This is MacOS Big Sur in a Macbook Air M1 running LiveCode 9.6.3-rc-1

Om om
Andre
___
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

___
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: [iOS] possible console bug

2021-07-12 Thread Andre Garzia via use-livecode
but it is supposed to work, right? Did this changed in some version?

> On 12 Jul 2021, at 14:45, matthias rebbe via use-livecode 
>  wrote:
> 
> I tried here with  LC9.6.2 under Catalina. It doesn't work either. 
> 
> 
>> Am 12.07.2021 um 14:49 schrieb Andre Garzia via use-livecode 
>> :
>> 
>> Hi Friends,
>> 
>> I’m writing here before I fill up a bug report because I don’t know if I’m 
>> doing things correctly. 
>> 
>> From what I remember, if we did a “put” to stdout, it would appear in the 
>> system log on iOS Simulator. Is that still the case?
>> 
>> I have an empty stack here with a button with the following script:
>> 
>> on mouseUp
>> put “this doesn’t work.”
>> put “it still doesn’t work”
>> end mouseUp
>> 
>> When I run that stack on the iOS Simulator, and select the “system log” menu 
>> item from the Simulator application, I can see a log of debug information 
>> but I can’t see any of my own “put” messages. No matter how many times I 
>> click the button.
>> 
>> Wasn’t that supposed to work?
>> 
>> This is MacOS Big Sur in a Macbook Air M1 running LiveCode 9.6.3-rc-1
>> 
>> Om om
>> Andre
>> ___
>> 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: [iOS] possible console bug

2021-07-12 Thread matthias rebbe via use-livecode
I tried here with  LC9.6.2 under Catalina. It doesn't work either. 


> Am 12.07.2021 um 14:49 schrieb Andre Garzia via use-livecode 
> :
> 
> Hi Friends,
> 
> I’m writing here before I fill up a bug report because I don’t know if I’m 
> doing things correctly. 
> 
> From what I remember, if we did a “put” to stdout, it would appear in the 
> system log on iOS Simulator. Is that still the case?
> 
> I have an empty stack here with a button with the following script:
> 
> on mouseUp
>  put “this doesn’t work.”
>  put “it still doesn’t work”
> end mouseUp
> 
> When I run that stack on the iOS Simulator, and select the “system log” menu 
> item from the Simulator application, I can see a log of debug information but 
> I can’t see any of my own “put” messages. No matter how many times I click 
> the button.
> 
> Wasn’t that supposed to work?
> 
> This is MacOS Big Sur in a Macbook Air M1 running LiveCode 9.6.3-rc-1
> 
> Om om
> Andre
> ___
> 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: [iOS] possible console bug

2021-07-12 Thread Andre Garzia via use-livecode
Besides that original problem, I have another one which is that calls to “do … 
in widget ‘browser’” are not working on iOS Simulator but work fine on the 
Desktop and Android. The code has no branching for each system, it is the exact 
same code in all platforms. There is no error, it simply doesn’t work as if it 
was not there.

I’m finding all that very odd.

> On 12 Jul 2021, at 13:49, Andre Garzia  wrote:
> 
> Hi Friends,
> 
> I’m writing here before I fill up a bug report because I don’t know if I’m 
> doing things correctly. 
> 
> From what I remember, if we did a “put” to stdout, it would appear in the 
> system log on iOS Simulator. Is that still the case?
> 
> I have an empty stack here with a button with the following script:
> 
> on mouseUp
>  put “this doesn’t work.”
>  put “it still doesn’t work”
> end mouseUp
> 
> When I run that stack on the iOS Simulator, and select the “system log” menu 
> item from the Simulator application, I can see a log of debug information but 
> I can’t see any of my own “put” messages. No matter how many times I click 
> the button.
> 
> Wasn’t that supposed to work?
> 
> This is MacOS Big Sur in a Macbook Air M1 running LiveCode 9.6.3-rc-1
> 
> Om om
> Andre


___
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


[iOS] possible console bug

2021-07-12 Thread Andre Garzia via use-livecode
Hi Friends,

I’m writing here before I fill up a bug report because I don’t know if I’m 
doing things correctly. 

From what I remember, if we did a “put” to stdout, it would appear in the 
system log on iOS Simulator. Is that still the case?

I have an empty stack here with a button with the following script:

on mouseUp
  put “this doesn’t work.”
  put “it still doesn’t work”
end mouseUp

When I run that stack on the iOS Simulator, and select the “system log” menu 
item from the Simulator application, I can see a log of debug information but I 
can’t see any of my own “put” messages. No matter how many times I click the 
button.

Wasn’t that supposed to work?

This is MacOS Big Sur in a Macbook Air M1 running LiveCode 9.6.3-rc-1

Om om
Andre
___
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