Search found 140 matches

by n.allan
Tue Jul 14, 2020 2:13 pm
Forum: Bug Triage
Topic: encrypt command "at x bit" being ignored
Replies: 1
Views: 541

Re: encrypt command "at x bit" being ignored

I couldn't see a way around this so I have spent a few days writing my own blowfish stuff. This is very rough (and fairly slow) at the moment but will suit my needs for the time being... Apologies for the code but I want it to be deliberately hard to read. I have left in some comments. This passes t...
by n.allan
Wed Jul 08, 2020 9:29 am
Forum: Bug Triage
Topic: encrypt command "at x bit" being ignored
Replies: 1
Views: 541

encrypt command "at x bit" being ignored

I am currently trying to use the encrypt command to reproduce test vectors given to me by a regulating body. The algorithm is bf-ecb. We are given a few test keys along with the plain text and cipher text. Key = 3130313231 (hex) or 10121 (ascii) Clear Text = 3132333435 (hex) or 12345 (ascii) Clear T...
by n.allan
Mon Jun 29, 2020 7:44 pm
Forum: CGIs and the Server
Topic: Server Sent Events - Prevent Closing of Socket
Replies: 2
Views: 984

Re: Server Sent Events - Prevent Closing of Socket

Thanks for the reply. I am completely new to server technology. I will keep digging as it may be an Apache issue. I have implemented server sent events in my own hand rolled LiveCode server (which admittedly will not be 100% compliant) and this works for me. The web browser shows the connection stay...
by n.allan
Mon Jun 29, 2020 4:52 pm
Forum: CGIs and the Server
Topic: Server Sent Events - Prevent Closing of Socket
Replies: 2
Views: 984

Server Sent Events - Prevent Closing of Socket

I am messing about with server sent events in livecode server. I have made a start by translating the php example found here https://www.html5rocks.com/en/tutorials/eventsource/basics/ Here is my very basic code to start with... <?lc put header "Content-Type: text/event-stream" put header "Cache-Con...
by n.allan
Thu Jun 04, 2020 3:30 pm
Forum: Getting Started with LiveCode - Experienced Developers
Topic: format() function and positional specifiers
Replies: 6
Views: 667

Re: format() function and positional specifiers

I will file an enhancement request.

Thanks everyone.
by n.allan
Sun May 31, 2020 2:53 pm
Forum: Getting Started with LiveCode - Experienced Developers
Topic: format() function and positional specifiers
Replies: 6
Views: 667

Re: format() function and positional specifiers

This website for printf() with positional specifiers has a good general case scenario where some spoken languages order their words differently. The positional specifiers could be used as part of a translation tool or some such. See here... https://www.gnu.org/software/gawk/manual/html_node/Printf-O...
by n.allan
Sun May 31, 2020 8:50 am
Forum: Getting Started with LiveCode - Experienced Developers
Topic: format() function and positional specifiers
Replies: 6
Views: 667

Re: format() function and positional specifiers

I assume the positional specifiers are only supported in special cases of printf(), thus not supported in LiveCode. My interim solution will be to use some kind of conditional statement prior to calling the format() function. Something like this... on testFormat pOrder -- pass in an "order" string C...
by n.allan
Sun May 24, 2020 5:55 pm
Forum: Getting Started with LiveCode - Experienced Developers
Topic: format() function and positional specifiers
Replies: 6
Views: 667

format() function and positional specifiers

I see the dictionary in 9.6.0.-rc-1, the entry for the format() function says that the format string is the same as the cpp printf() function. On "some" cpp printf() web pages there can be positional specifiers in the format string. You can pass the parameters in a certain order, then they will be b...
by n.allan
Fri May 15, 2020 12:10 pm
Forum: Databases
Topic: SQLite Database BLOB is identified as STRING
Replies: 3
Views: 623

Re: SQLite Database BLOB is identified as STRING

Thank you both very much for your replies... @LCMark, Your solution has solved the problem. The data type is now showing as BLOB and the full chunk of data is now in the tImage variable. my final handler with your solution... on test local tQuery, tRecordSet, tImage, tResult, tID , tTypes -- some va...
by n.allan
Fri May 15, 2020 10:01 am
Forum: Databases
Topic: SQLite Database BLOB is identified as STRING
Replies: 3
Views: 623

SQLite Database BLOB is identified as STRING

I am having trouble reading BLOB data from an SQLite database file. In my sqlite database there is a table called tiles. The columns in it are zoom_level (INTEGER), tile_row (INTEGER), tile_column (INTEGER) and tile_data (BLOB). For anyone "in the know" these are industry standard raster ".mbtiles"....
by n.allan
Tue Jul 30, 2019 8:36 pm
Forum: Databases
Topic: Connecting to SQL Express (localdb)\v11
Replies: 3
Views: 1555

Re: Connecting to SQL Express (localdb)\v11

OK no joy with the file DSN or indeed the system DSN....
More research required.
by n.allan
Sun Jul 21, 2019 7:04 pm
Forum: Databases
Topic: Connecting to SQL Express (localdb)\v11
Replies: 3
Views: 1555

Re: Connecting to SQL Express (localdb)\v11

I have used file DSN in the past now you mention it. I could maybe create a file DSN to the mdf files that are created by SQL Express perhaps? I dug out this old code for creating a ODBC DSN in windows from an mdb file livecode... function createConnection theFile replace "/" with "\\" in theFile if...
by n.allan
Sun Jul 21, 2019 5:24 pm
Forum: Databases
Topic: Connecting to SQL Express (localdb)\v11
Replies: 3
Views: 1555

Connecting to SQL Express (localdb)\v11

Does anyone if livecode can connect to an SQL Express Server with the revOpenDatabase() function? By it's nature the server is on the local machine (SQL Express does not allow remote connections) I have tried... get revOpenDatabase("mysql", "localhost", "(localdb)\v11",,,,,,) get revOpenDatabase("my...
by n.allan
Thu Jun 22, 2017 10:42 am
Forum: MergEXT
Topic: MergBLE on OS X Sierra 10.12.5
Replies: 7
Views: 3580

Re: MergBLE on OS X Sierra 10.12.5

Sorry initially when I wrote the post, I had spelt "initialize" incorrectly (debatable), which caused lc to throw an error. But as you can see it has been fixed in the code. Now there are no errors thrown but I know that there are at least 3 BLE devices visible so I would expect a message box to pop...
by n.allan
Wed Jun 21, 2017 7:19 pm
Forum: Android Deployment
Topic: Version 9 Deployment issues
Replies: 2
Views: 1255

Re: Version 9 Deployment issues

OK 9.0.0-dp-5 is the last version that runs on the watch. dp-6 and dp-7 do not run on it so I'm not imagining it and Livecode used to be compatible with the device. I wonder what has changed to cause the black screen issue?

Go to advanced search