Re: Learning about server
The regex I'm using to validate URL's isn't good enough yet - it needs a few tweaks - like the '=' ! On 26/06/2014 02:16, Scott Morrow wrote: FWIW… Although a “good” url probably shouldn’t have an equal sign… I’ve got one which appears to work in most browsers but gets reported as not valid when using 8up.uk http://elementarysoftware.com/beta/this=that/this=that-beta.html And count me as interested in any LC Server book. — Scott Morrow On Jun 25, 2014, at 2:19 PM, John Craig j...@splash21.com wrote: I've created a url shortening service with LC server that I want to write up as an example app. It seems like quite a good project to start with as it's fairly short / easy to complete, but not without having to solve a few problems first. There's exposure to quite a good mix of things to get it up and running - and I'll also add a captcha image to prevent robots... http://8up.uk On 10/06/2014 10:56, John Craig wrote: Any areas in particular that interest you? I was speaking to someone recently about writing a book on LC server - not sure how much interest there would be, but here is the current list of possible topics; Basic .lc server scripts Sessions Basic logging in and out with sessions SQL primer Server scripts with MySQL Logging in and out with a database Web applications User and group permissions Javascript AJAX Web APIs Push notifications: iOS/Android Basic record versioning with AJAX With hangouts / skype and all the other wonders of the interweb, delivery could be fun.. On 10/06/2014 04:00, Dar Scott wrote: I would like to learn about server. But, as Frodo would way, I don’t know the way. Dar Scott ___ 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 ___ 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: Learning about server
It copies and pastes OK on my android tablet (4.0.3). If the text is hilited, then that's what should copy... Were you on a device or emulator? On 26/06/2014 00:07, Roger Eller wrote: On Android, when I try to copy the shortened URL, this is what I get: You can now copy the shortened URL... Powered by LiveCode Community Server It would hilite the URL, http://8up.uk/M; but not copy it. ~Roger Sent from my Android tablet On Jun 25, 2014 5:19 PM, John Craig j...@splash21.com wrote: I've created a url shortening service with LC server that I want to write up as an example app. It seems like quite a good project to start with as it's fairly short / easy to complete, but not without having to solve a few problems first. There's exposure to quite a good mix of things to get it up and running - and I'll also add a captcha image to prevent robots... http://8up.uk On 10/06/2014 10:56, John Craig wrote: Any areas in particular that interest you? I was speaking to someone recently about writing a book on LC server - not sure how much interest there would be, but here is the current list of possible topics; Basic .lc server scripts Sessions Basic logging in and out with sessions SQL primer Server scripts with MySQL Logging in and out with a database Web applications User and group permissions Javascript AJAX Web APIs Push notifications: iOS/Android Basic record versioning with AJAX With hangouts / skype and all the other wonders of the interweb, delivery could be fun.. On 10/06/2014 04:00, Dar Scott wrote: I would like to learn about server. But, as Frodo would way, I don’t know the way. Dar Scott ___ 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 ___ 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: Learning about server
If it's valid ... it's valid :) I've replaced the url validation with a much looser regex On 26/06/2014 02:16, Scott Morrow wrote: FWIW… Although a “good” url probably shouldn’t have an equal sign… I’ve got one which appears to work in most browsers but gets reported as not valid when using 8up.uk http://elementarysoftware.com/beta/this=that/this=that-beta.html And count me as interested in any LC Server book. — Scott Morrow On Jun 25, 2014, at 2:19 PM, John Craig j...@splash21.com wrote: ___ 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
LiveCode Server: start session problem
I decided to add some session code to my server project, but the following command causes an error on 6.6.1 on Linux (community and commercial); start session LC 6.6.2 had another problem, which is why I rolled back to 6.6.1. I've now also tried 6.6.0 and 6.5.2 - 'start session' also bombs those versions out. Anyone know how far back I have to go to get a stable release with working sessions? ___ 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 Server: start session problem
took a punt on 6.7.0 DP4 - same problem . On 26/06/2014 12:12, John Craig wrote: I decided to add some session code to my server project, but the following command causes an error on 6.6.1 on Linux (community and commercial); start session LC 6.6.2 had another problem, which is why I rolled back to 6.6.1. I've now also tried 6.6.0 and 6.5.2 - 'start session' also bombs those versions out. Anyone know how far back I have to go to get a stable release with working sessions? ___ 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: LiveCode Server: start session problem
Hi John I am running the latest version - linux and windows and sessions are working fine for me. whats happening when you use start session ? Simon On Thu, Jun 26, 2014 at 1:12 PM, John Craig j...@splash21.com wrote: I decided to add some session code to my server project, but the following command causes an error on 6.6.1 on Linux (community and commercial); start session LC 6.6.2 had another problem, which is why I rolled back to 6.6.1. I've now also tried 6.6.0 and 6.5.2 - 'start session' also bombs those versions out. Anyone know how far back I have to go to get a stable release with working sessions? ___ 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 -- *Simon Smith* *seo, online marketing, web development* w. http://www.simonsmith.co m. +27 83 306 7862 ___ 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: Learning about server
It's a real device... running 4.1.1, and I've tried a couple different browsers. Sent from my Android tablet On Jun 26, 2014 2:56 AM, John Craig j...@splash21.com wrote: It copies and pastes OK on my android tablet (4.0.3). If the text is hilited, then that's what should copy... Were you on a device or emulator? On 26/06/2014 00:07, Roger Eller wrote: On Android, when I try to copy the shortened URL, this is what I get: You can now copy the shortened URL... Powered by LiveCode Community Server It would hilite the URL, http://8up.uk/M; but not copy it. ~Roger Sent from my Android tablet On Jun 25, 2014 5:19 PM, John Craig j...@splash21.com wrote: I've created a url shortening service with LC server that I want to write up as an example app. It seems like quite a good project to start with as it's fairly short / easy to complete, but not without having to solve a few problems first. There's exposure to quite a good mix of things to get it up and running - and I'll also add a captcha image to prevent robots... http://8up.uk On 10/06/2014 10:56, John Craig wrote: Any areas in particular that interest you? I was speaking to someone recently about writing a book on LC server - not sure how much interest there would be, but here is the current list of possible topics; Basic .lc server scripts Sessions Basic logging in and out with sessions SQL primer Server scripts with MySQL Logging in and out with a database Web applications User and group permissions Javascript AJAX Web APIs Push notifications: iOS/Android Basic record versioning with AJAX With hangouts / skype and all the other wonders of the interweb, delivery could be fun.. On 10/06/2014 04:00, Dar Scott wrote: I would like to learn about server. But, as Frodo would way, I don’t know the way. Dar Scott ___ 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 ___ 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: LiveCode Server: start session problem
Hi, Simon. It's encouraging that it's working on your system - hopefully there's just some misconfiguration on my machine. I get the following error when I add the start session line; file /var/www/vhosts/8up.uk/httpdocs/index.lc row 16, col 1: Row 16 is the line in question. Column 1 is the 's' of 'start' ! Everything else is working fine - database access, etc. Only that one command seems to throw an error. When you say the latest, do you mean the latest stable (6.6.2) or the latest DP (6.7.0)? Thanks On 26/06/2014 12:20, Simon Smith wrote: Hi John I am running the latest version - linux and windows and sessions are working fine for me. whats happening when you use start session ? Simon On Thu, Jun 26, 2014 at 1:12 PM, John Craig j...@splash21.com wrote: I decided to add some session code to my server project, but the following command causes an error on 6.6.1 on Linux (community and commercial); start session LC 6.6.2 had another problem, which is why I rolled back to 6.6.1. I've now also tried 6.6.0 and 6.5.2 - 'start session' also bombs those versions out. Anyone know how far back I have to go to get a stable release with working sessions? ___ 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: Learning about server
I think the issue might be uppercase letters - I've just tried this on a mac and an iPad - it is happy with runrev.com but borks at Runrev.com - Some are born coders, some achieve coding, and some have coding thrust upon them. - William Shakespeare Hugh Senior -- View this message in context: http://runtime-revolution.278305.n4.nabble.com/Learning-about-server-tp4680393p4680653.html Sent from the Revolution - User mailing list archive at Nabble.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: Learning about server
My take#2 at the url validation caused the uppercase problem. I've just updated it to take#3 - uppercase letters are welcome! Problem is I don't use regular expressions that often, so I get rusty - may take another few tweaks yet, but fingers crossed :) On 26/06/2014 12:41, Dave Kilroy wrote: I think the issue might be uppercase letters - I've just tried this on a mac and an iPad - it is happy with runrev.com but borks at Runrev.com - Some are born coders, some achieve coding, and some have coding thrust upon them. - William Shakespeare Hugh Senior -- View this message in context: http://runtime-revolution.278305.n4.nabble.com/Learning-about-server-tp4680393p4680653.html Sent from the Revolution - User mailing list archive at Nabble.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: LiveCode Server: start session problem
Thanks, Simon. Knowing that it worked elsewhere was enough to start me poking around again. Issue was resolved by specifying an alternative sessionSavePath. The original path '/tmp' is writable, etc. (and PHP uses it), but changing it worked for LC. :D On 26/06/2014 12:20, Simon Smith wrote: Hi John I am running the latest version - linux and windows and sessions are working fine for me. whats happening when you use start session ? Simon On Thu, Jun 26, 2014 at 1:12 PM, John Craig j...@splash21.com wrote: I decided to add some session code to my server project, but the following command causes an error on 6.6.1 on Linux (community and commercial); start session LC 6.6.2 had another problem, which is why I rolled back to 6.6.1. I've now also tried 6.6.0 and 6.5.2 - 'start session' also bombs those versions out. Anyone know how far back I have to go to get a stable release with working sessions? ___ 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: LiveCode Server: start session problem
Hi John Might be easier for to email the script to me and I can take a look. What you can try though is: Ensure that start session is at the very top of your script (e.g. line 1 ) and that you also have end session at the very end of the script. If you output anything before calling start session - thats probably whats causing the problem. Kind Regards Simon On Thu, Jun 26, 2014 at 1:40 PM, John Craig j...@splash21.com wrote: Hi, Simon. It's encouraging that it's working on your system - hopefully there's just some misconfiguration on my machine. I get the following error when I add the start session line; file /var/www/vhosts/8up.uk/httpdocs/index.lc row 16, col 1: Row 16 is the line in question. Column 1 is the 's' of 'start' ! Everything else is working fine - database access, etc. Only that one command seems to throw an error. When you say the latest, do you mean the latest stable (6.6.2) or the latest DP (6.7.0)? Thanks On 26/06/2014 12:20, Simon Smith wrote: Hi John I am running the latest version - linux and windows and sessions are working fine for me. whats happening when you use start session ? Simon On Thu, Jun 26, 2014 at 1:12 PM, John Craig j...@splash21.com wrote: I decided to add some session code to my server project, but the following command causes an error on 6.6.1 on Linux (community and commercial); start session LC 6.6.2 had another problem, which is why I rolled back to 6.6.1. I've now also tried 6.6.0 and 6.5.2 - 'start session' also bombs those versions out. Anyone know how far back I have to go to get a stable release with working sessions? ___ 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 -- *Simon Smith* *seo, online marketing, web development* w. http://www.simonsmith.co m. +27 83 306 7862 ___ 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
Problem on Win 7 with an app compiled with LC 6.6 on Mac
Hi list, I am using LC 6.6 build 4003 on Mac OSX 10.5.5 to compile an app made years ago on LC 4.5.3 and constantly improved over the years, with each new version of the app compiled with a more recent version of LC... And suddenly today, some of the users of this app in various cities of the country seem to encounter problems on Win 7, like app freeze or display going totally crazy... My own tests on Win 7 don't show any problem, and these users are hundreds of kilometers away and rather computer illiterate, so they can't give me much details... Other users of the Mac version of the same app compiled with the same LC 6.6 don't seem to have any problem. I have just re-compiled the app with an old LC 6.5.2 and am waiting for feedback from my clients... So far I don't see what else I could do... Has anybody faced a similar problem ? Any wise tip about what to do ? Thanks jbv ___ 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: Problem on Win 7 with an app compiled with LC 6.6 on Mac
On Thursday, June 26, 2014, j...@souslelogo.com wrote: So far I don't see what else I could do... Has anybody faced a similar problem ? Any wise tip about what to do ? 6.6 added high-res support for desktop. I would check your zoom settings on your Windows 7 install and see if it is the same as your customers. When zoom is set to 150% or higher Windows enters a high-dpi mode and things behave a little differently. If you aren't familiar with zoom setting search Google for make text larger 150% and you should find instructions on changing the setting. -- Trevor DeVore ___ 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
Error handling (was Re: nan v. try-catch for arithmetic)
J. Landman Gay wrote: On 6/24/2014, 1:02 PM, Graham Samuel wrote: I get a result, nan, and the catch doesn't fire. Why not? Maybe someone can explain what the engine is doing here - or is it just an obscure bug? A catch only triggers when there is a script error. In this case there is no error, nan is a legitimate value for a calculation that can't be computed. This conversation raises a broader issue that's concerned me for some time, and I'm hoping I've just overlooked some rule at play that would make things more readily understandable: How can a scripter know in advance which commands require try-catch to handle errors and which require checking the result? For example: decompress and arrayDecode require try-catch, throwing an execution error if the data passed to them is not in the expected format. But decrypt throws no execution error at all when unencrypted data is passed, instead describing that there is a problem in the result. Is there a simple rule that would allow scripters to understand when try-catch is necessary and when the result should be checked instead? If not, should there be? Or perhaps better yet, could error handling be made uniform, maybe as part of the Open Language initiative? If so, what would it look like? -- Richard Gaskin Fourth World LiveCode training and consulting: http://www.fourthworld.com Webzine for LiveCode developers: http://www.LiveCodeJournal.com Follow me on Twitter: http://twitter.com/FourthWorldSys ___ 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: Problem on Win 7 with an app compiled with LC 6.6 on Mac
jbv wrote: I am using LC 6.6 build 4003... And suddenly today, some of the users of this app in various cities of the country seem to encounter problems on Win 7... The current Stable version is 6.6.2, and the Release Notes for that version include mention of a great many fixes related to display issues, hangs, and crashes on Windows. It's always useful to try to ship with the most recent shipping version. And during development it's very useful to work with the next pre-release build, since you'll be able to submit any reports that may be needed during the development cycle for that build so they can be addressed before release. Please keep us posted if 6.6.2 resolves the issue, and if not whether the current next test release (6.7 DP4) still exhibits the issue. If it does, please note the bug report number here in your reply so those of us keenly interested in Windows issues can follow the fix process for it. -- Richard Gaskin Fourth World LiveCode training and consulting: http://www.fourthworld.com Webzine for LiveCode developers: http://www.LiveCodeJournal.com Follow me on Twitter: http://twitter.com/FourthWorldSys ___ 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: Image control in a Background
Hi This morning I did some testing to address the image updating in the current card in the image control and did not come up with a solution that worked. I have the On OpenCard script that is working to add the image to the image control, and as before the on OpenCard script cannot update the image field in the open card because the script has already triggered. I tried to use a button on the card to refresh the image field to display the last edited image, but everything I tried had no effect? I tried to have the image assigned to the card id to reload using this in the button: *on mouseUp* *if* the number of this card 1 *then* *set* the defaultfolder to specialFolderPath (documents) /photos/ *if* there is a file the short id of this card *then* *put* specialFolderPath (documents) /photos/ the short ID of this card into thePath *set* the filename of image imageField1 of this card to thepath *end* *if* *end* *if* *end mouseUp* I am I totally off base trying to use this approach? Thank you Vaughn Clement Apps by Vaughn Clement (Support) *http://www.appsbyvaughnclement.com/tools/home-page/ http://www.appsbyvaughnclement.com/tools/home-page/* Skype: vaughn.clement https://secure.join.me/appsbyvclement FaceTime: vclem...@gmail.com LogMeIn also avaialble Call on ooVoo at address: vaughnclement or 9282549062 Ph. 928-254-9062 On Wed, Jun 25, 2014 at 5:34 PM, J. Landman Gay jac...@hyperactivesw.com wrote: That's good to know. My app is desktop only and it must be different there. Thanks for the heads up. On June 25, 2014 4:51:44 PM CDT, Simon si...@asato-media.com wrote: Hi Jacque, But for image objects it isn't needed, and you can omit that instruction. Actually it was the only way to get the script to work on mobile when I actually put it on my device. -- 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: Error handling (was Re: nan v. try-catch for arithmetic)
On Thu, Jun 26, 2014 at 8:22 AM, Richard Gaskin ambassa...@fourthworld.com wrote: Is there a simple rule that would allow scripters to understand when try-catch is necessary and when the result should be checked instead? If not, should there be? Or perhaps better yet, could error handling be made uniform, maybe as part of the Open Language initiative? If so, what would it look like? Personally, I think error handling should be made uniform. As you say, sometimes try/catch is required, other times the result must be checked and sometimes it must be checked. Then there's the different ways errors are reported by the database library commands. Maybe there should a new variable - the error for example - which can be used to report all error conditions. Another approach might be the ability to specify a error callback handler similar to the libURL commands. Pete lcSQL Software http://www.lcsql.com Home of lcStackBrowser http://www.lcsql.com/lcstackbrowser.html and SQLiteAdmin http://www.lcsql.com/sqliteadmin.html ___ 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: Error handling (was Re: nan v. try-catch for arithmetic)
On 6/26/2014 12:23 PM, Peter Haworth wrote: On Thu, Jun 26, 2014 at 8:22 AM, Richard Gaskin ambassa...@fourthworld.com wrote: Is there a simple rule that would allow scripters to understand when try-catch is necessary and when the result should be checked instead? If not, should there be? Or perhaps better yet, could error handling be made uniform, maybe as part of the Open Language initiative? If so, what would it look like? Personally, I think error handling should be made uniform. As you say, sometimes try/catch is required, other times the result must be checked and sometimes it must be checked. Then there's the different ways errors are reported by the database library commands. Try - Catch functionally is present many programming languages for a very different purpose than general error reporting. Language commands and functions that can detect, trap, and report an error, should return appropriate error information that the programmer can check for. LC generally does this via the result, the returned value of a function itself (an empty return value from some functions can equal an error condition, or a function may return an error message), or it - and among these, improved consistency would be a nice improvement. However, no language can really prevent programming error or error based on unexpected inputs - i.e. add fred to tVar - that results in an execution error. Try/Catch serves as a tool in modern programming languages to allow a programmer to catch any UNEXPECTED execution error and handle it in some controlled way. Both mechanism can be used together. In the example below, if tInput contained text (fred) rather than a number or if either someFunction or someCommand return errors, the entire block of code has a graceful exit. try add tInput to tVar put someFuntion(tVar) into tVar2 if tVar2 is empty throw error someCommand tVar2 if the result begins with error then throw error catch tError -- controlled exit here end try ___ 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: Image control in a Background
Hi Vaughn, Still not clear on what you are doing because it looks like you are just repeating the openCard script from your original posting, so... on mouseUp openCard end mouseUp You should not see anything happen because it just loads the same image in. Unless I read this too quickly. Simon -- View this message in context: http://runtime-revolution.278305.n4.nabble.com/Image-control-in-a-Background-tp4680553p4680665.html Sent from the Revolution - User mailing list archive at Nabble.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: Image control in a Background
Hi Simon I was testing to see what might work to finish adding the image without having to leave the card and return to trigger the openCard script again? I thought a button script Update Image button might trigger the update? I used a portion of the open card script thinking it would work. Since the image was added to the photos subfolder thePath reloading it again might be a way to update the image in the control while not leaving the card? It did not have any effect, so I am not sure how to make it update the image without leaving the card. - I not only have to leave the card, but open another card and return to have it update the image now. - I thought to move to another card and then return, but I trapped myself by using a datagrid to select the card to be opened, and a simple goto card and return script messes up the datagrid row update. I have a button to close the card now and return to the datagrid. This allows me to select another card in the datagrid to view, and then I must return to the grid when finished. The process of going back to the datagrid and then returning to the same card will not update the image. But going to a different card, returning, and then opening the original card does update the image as you would expect when the open card script is triggered. On Thursday, June 26, 2014, Simon si...@asato-media.com wrote: Hi Vaughn, Still not clear on what you are doing because it looks like you are just repeating the openCard script from your original posting, so... on mouseUp openCard end mouseUp You should not see anything happen because it just loads the same image in. Unless I read this too quickly. Simon -- View this message in context: http://runtime-revolution.278305.n4.nabble.com/Image-control-in-a-Background-tp4680553p4680665.html Sent from the Revolution - User mailing list archive at Nabble.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: Image control in a Background
Hi Vaughn, You did see that I posted everything was working after a few small changes in your original script? I never received an answer that you tested it and it didn't work for you. Simon -- View this message in context: http://runtime-revolution.278305.n4.nabble.com/Image-control-in-a-Background-tp4680553p4680668.html Sent from the Revolution - User mailing list archive at Nabble.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
non-Functional Mac PPC installers?
I wonder what the point of stating that the Mac installer of Livecode 6.6.2 will install on a Mac PPC when it won't? I have just tried (again) to install this version on my G5 iMac running Mac OS 10.5.8: http://forums.livecode.com/viewtopic.php?f=6t=20611 Richmond. ___ 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: Image control in a Background
Hi Simon Is this the email: Hi Vaughn, Aside from a spelling mistake just add parentheses around all the folder paths e.g. put (specialFolderPath(documents) /photos/ the short ID of this card) into thePath and then delete the current filename on mouseUp --/ the image from mobilePickPhoto uses the template image construct --set it off screen so we don't see ift flash / set the loc of the templateImage to -1,-1 set the filename of image imageField1 of this card to Thank you Vaughn Clement Apps by Vaughn Clement (Support) *http://www.appsbyvaughnclement.com/tools/home-page/ http://www.appsbyvaughnclement.com/tools/home-page/* Skype: vaughn.clement https://secure.join.me/appsbyvclement FaceTime: vclem...@gmail.com LogMeIn also avaialble Call on ooVoo at address: vaughnclement or 9282549062 Ph. 928-254-9062 On Thu, Jun 26, 2014 at 12:11 PM, Simon si...@asato-media.com wrote: Hi Vaughn, You did see that I posted everything was working after a few small changes in your original script? I never received an answer that you tested it and it didn't work for you. Simon -- View this message in context: http://runtime-revolution.278305.n4.nabble.com/Image-control-in-a-Background-tp4680553p4680668.html Sent from the Revolution - User mailing list archive at Nabble.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: Image control in a Background
Yep on mouseUp --/ the image from mobilePickPhoto uses the template image construct --set it off screen so we don't see ift flash / --set the loc of the templateImage to -1,-1 set the vis of the templateImage to false --NEWLINE --delete file (specialFolderPath(documents) /photos/ the short ID of this card) set the filename of image imageField1 of this card to --NEWLINE --/choose a photo/ mobilePickPhoto library lock screen if the result cancel then --/ make the filepath to save the chosen image/ put (specialFolderPath(documents) /photos/ the short ID of this card) into thePath --/ put the image into a file in the photos folder / put the text of the last image of this card into URL(binfile: thePath) --/set the loc of image 1 to the loc of group picgroup' so it will align/ set the loc of image imageField1 to the loc of group picgroup --/ show the image on the card / set the filename of image imageField1 of this card to thePath --/ destroy the image imported from the library / delete the last image of this card end if unlock screen end mouseUp There is another change I made in there as well. Simon -- View this message in context: http://runtime-revolution.278305.n4.nabble.com/Image-control-in-a-Background-tp4680553p4680671.html Sent from the Revolution - User mailing list archive at Nabble.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: Image control in a Background
Hi Simon I aasume that the current stack script is replaced with your card script? On Thursday, June 26, 2014, Vaughn Clement vclem...@gmail.com wrote: Hi Simon Let me try this to test my stack for errors. On Thursday, June 26, 2014, Simon si...@asato-media.com javascript:_e(%7B%7D,'cvml','si...@asato-media.com'); wrote: Yep on mouseUp --/ the image from mobilePickPhoto uses the template image construct --set it off screen so we don't see ift flash / --set the loc of the templateImage to -1,-1 set the vis of the templateImage to false --NEWLINE --delete file (specialFolderPath(documents) /photos/ the short ID of this card) set the filename of image imageField1 of this card to --NEWLINE --/choose a photo/ mobilePickPhoto library lock screen if the result cancel then --/ make the filepath to save the chosen image/ put (specialFolderPath(documents) /photos/ the short ID of this card) into thePath --/ put the image into a file in the photos folder / put the text of the last image of this card into URL(binfile: thePath) --/set the loc of image 1 to the loc of group picgroup' so it will align/ set the loc of image imageField1 to the loc of group picgroup --/ show the image on the card / set the filename of image imageField1 of this card to thePath --/ destroy the image imported from the library / delete the last image of this card end if unlock screen end mouseUp There is another change I made in there as well. Simon -- View this message in context: http://runtime-revolution.278305.n4.nabble.com/Image-control-in-a-Background-tp4680553p4680671.html Sent from the Revolution - User mailing list archive at Nabble.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 -- Thank you Vaughn Clement Apps by Vaughn Clement (Support) *http://www.appsbyvaughnclement.com/tools/home-page/ http://www.appsbyvaughnclement.com/tools/home-page/* Skype: vaughn.clement https://secure.join.me/appsbyvclement FaceTime: vclem...@gmail.com javascript:_e(%7B%7D,'cvml','vclem...@gmail.com'); LogMeIn also avaialble Call on ooVoo at address: vaughnclement or 9282549062 Ph. 928-254-9062 -- Thank you Vaughn Clement Apps by Vaughn Clement (Support) *http://www.appsbyvaughnclement.com/tools/home-page/ http://www.appsbyvaughnclement.com/tools/home-page/* Skype: vaughn.clement https://secure.join.me/appsbyvclement FaceTime: vclem...@gmail.com LogMeIn also avaialble Call on ooVoo at address: vaughnclement or 9282549062 Ph. 928-254-9062 ___ 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: Image control in a Background
Vaughn Clement wrote Hi Simon I aasume that the current stack script is replaced with your card script? errr... you are confusing me, I don't have a card script. I posted a button script. Your original card script was ok. Simon -- View this message in context: http://runtime-revolution.278305.n4.nabble.com/Image-control-in-a-Background-tp4680553p4680674.html Sent from the Revolution - User mailing list archive at Nabble.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: Image control in a Background
Hi Simon The original email had a on OpenCard Stack script and a script in the image control to manage the card image.. The button on the buyer's order Button is my script test. The black buttons are the main buttons. If you send me an email address I will send you the stack. Thank you Vaughn Clement Apps by Vaughn Clement (Support) *http://www.appsbyvaughnclement.com/tools/home-page/ http://www.appsbyvaughnclement.com/tools/home-page/* Skype: vaughn.clement https://secure.join.me/appsbyvclement FaceTime: vclem...@gmail.com LogMeIn also avaialble Call on ooVoo at address: vaughnclement or 9282549062 Ph. 928-254-9062 On Thu, Jun 26, 2014 at 1:04 PM, Simon si...@asato-media.com wrote: Vaughn Clement wrote Hi Simon I aasume that the current stack script is replaced with your card script? errr... you are confusing me, I don't have a card script. I posted a button script. Your original card script was ok. Simon -- View this message in context: http://runtime-revolution.278305.n4.nabble.com/Image-control-in-a-Background-tp4680553p4680674.html Sent from the Revolution - User mailing list archive at Nabble.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
compatibility between Android SDK and Livecode versions
Hi, is there a Livecode vs. Android SDK versions compatibility matrix available? Which SDK would work with Livecode 6.5 (on Windows 8)? Best wishes! Viktoras ___ 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
Name shadows another variable
The above error has been flagged intermittently and incorrectly when compiling a script with Strict Compilation Mode turned on for as long as I've been using Livecode. In the last couple of days, the error has been flagged every time I compile a script in one particular application. I restart Livecode and all is OK - same combination of stacks, no recompile necessary. As far as I know, that's the only way to get around the issue unless I switch off Strict Compilation Mode which I am not willing to do. I know the bug has been entered at the QCC several times and I also know that so far it has been impossible to provide a recipe to reproduce it. I will add the stack exhibiting the problem to one of the error reports but I've done that in the past and RunRev have been unable to reproduce it. I am practically at a standstill with development of this application until this problem is fixed. It seems to me that someone at RunRev needs to take responsibility for finding what causes this problem using old fashioned methods, like going through the code, or reproduce it themselves. Pete lcSQL Software http://www.lcsql.com Home of lcStackBrowser http://www.lcsql.com/lcstackbrowser.html and SQLiteAdmin http://www.lcsql.com/sqliteadmin.html ___ 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: Image control in a Background
Hi Simon OK, thanks for the assistance. I will try the script in a button on the card. Thank you Vaughn Clement Apps by Vaughn Clement (Support) *http://www.appsbyvaughnclement.com/tools/home-page/ http://www.appsbyvaughnclement.com/tools/home-page/* Skype: vaughn.clement https://secure.join.me/appsbyvclement FaceTime: vclem...@gmail.com LogMeIn also avaialble Call on ooVoo at address: vaughnclement or 9282549062 Ph. 928-254-9062 On Thu, Jun 26, 2014 at 2:29 PM, Simon si...@asato-media.com wrote: Hi Vaughn, Nope I don't need to see the stack. Everything is running correctly here. Simon -- View this message in context: http://runtime-revolution.278305.n4.nabble.com/Image-control-in-a-Background-tp4680553p4680678.html Sent from the Revolution - User mailing list archive at Nabble.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: Image control in a Background
Hi Simon I used the script in a button a aligned and edited as shown: The image was added from the button to the image control. But all the cards in the stack now have the last added image. This is where I was a few days ago where the script did this same thing? Did I edit it wrong? *on* mouseUp *--/ the image from mobilePickPhoto uses the template image construct* *--set it off screen so we don't see ift flash /* *--set the loc of the templateImage to -1,-1* *set* the vis of the templateImage to false *--NEWLINE* *--delete file (specialFolderPath(documents) /photos/ the short ID* *--of this card)* *set* the filename of image imageField1 of this card to *--NEWLINE* *--/choose a photo/* mobilePickPhoto library *lock* screen *if* the result cancel *then* *--/ make the filepath to save the chosen image/* *put* (specialFolderPath (documents) /photos/ the short ID of this card) into thePath *--/ put the image into a file in the photos folder /* *put* the text of the last image of this card into URL(binfile: thePath) *--/set the loc of image 1 to the loc of group picgroup' so it will align/* *--set the loc of image imageField1 to the loc of group picgroup* *--/ show the image on the card /* *set* the filename of image imageField1 of this card to thePath *--/ destroy the image imported from the library /* *delete* the last image of this card *end* *if* *unlock* screen *end* mouseUp Thank you Vaughn Clement Apps by Vaughn Clement (Support) *http://www.appsbyvaughnclement.com/tools/home-page/ http://www.appsbyvaughnclement.com/tools/home-page/* Skype: vaughn.clement https://secure.join.me/appsbyvclement FaceTime: vclem...@gmail.com LogMeIn also avaialble Call on ooVoo at address: vaughnclement or 9282549062 Ph. 928-254-9062 On Thu, Jun 26, 2014 at 12:35 PM, Simon si...@asato-media.com wrote: Yep on mouseUp --/ the image from mobilePickPhoto uses the template image construct --set it off screen so we don't see ift flash / --set the loc of the templateImage to -1,-1 set the vis of the templateImage to false --NEWLINE --delete file (specialFolderPath(documents) /photos/ the short ID of this card) set the filename of image imageField1 of this card to --NEWLINE --/choose a photo/ mobilePickPhoto library lock screen if the result cancel then --/ make the filepath to save the chosen image/ put (specialFolderPath(documents) /photos/ the short ID of this card) into thePath --/ put the image into a file in the photos folder / put the text of the last image of this card into URL(binfile: thePath) --/set the loc of image 1 to the loc of group picgroup' so it will align/ set the loc of image imageField1 to the loc of group picgroup --/ show the image on the card / set the filename of image imageField1 of this card to thePath --/ destroy the image imported from the library / delete the last image of this card end if unlock screen end mouseUp There is another change I made in there as well. Simon -- View this message in context: http://runtime-revolution.278305.n4.nabble.com/Image-control-in-a-Background-tp4680553p4680671.html Sent from the Revolution - User mailing list archive at Nabble.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: Image control in a Background
Yes, if there is no file thePath And I think we've discussed enough why this happens. So to fix it so that it doesn't show an image at all if there is no file thePath: if there is a file the short id of this card then put (specialFolderPath (documents) /photos/ the short ID of this card) into thePath set the filename of image imageField1 of this card to thePath else ---here is a new line set the filename of image imageField1 of this card to ---here is a new line end if Update your openCard script Simon -- View this message in context: http://runtime-revolution.278305.n4.nabble.com/Image-control-in-a-Background-tp4680553p4680681.html Sent from the Revolution - User mailing list archive at Nabble.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: Image control in a Background
Hi Simon This is a real pleasure to say it is working as designed now. Your a real wizard at scripting. Looking at this from start to finish I can say I have learned a lot about the image control, but more over I have a better perspective on how to work to find solutions in scripting. Thanks for your time and effort!!! Thank you Vaughn Clement Apps by Vaughn Clement (Support) *http://www.appsbyvaughnclement.com/tools/home-page/ http://www.appsbyvaughnclement.com/tools/home-page/* Skype: vaughn.clement https://secure.join.me/appsbyvclement FaceTime: vclem...@gmail.com LogMeIn also avaialble Call on ooVoo at address: vaughnclement or 9282549062 Ph. 928-254-9062 On Thu, Jun 26, 2014 at 3:28 PM, Simon si...@asato-media.com wrote: Yes, if there is no file thePath And I think we've discussed enough why this happens. So to fix it so that it doesn't show an image at all if there is no file thePath: if there is a file the short id of this card then put (specialFolderPath (documents) /photos/ the short ID of this card) into thePath set the filename of image imageField1 of this card to thePath else ---here is a new line set the filename of image imageField1 of this card to ---here is a new line end if Update your openCard script Simon -- View this message in context: http://runtime-revolution.278305.n4.nabble.com/Image-control-in-a-Background-tp4680553p4680681.html Sent from the Revolution - User mailing list archive at Nabble.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
On my way to the LiveCode meeting
Hi guys, Just wanted to let you know I'm on my way to the LiveCode meeting in Switzerland. If you want to participate too, just send an e-mail to me to Bjoernke. More info is available at http://www3.economy-x-talk.com/blog/ . I hope to see you there. -- Best regards, Mark Schonewille Economy-x-Talk Consulting and Software Engineering Homepage: http://economy-x-talk.com Twitter: http://twitter.com/xtalkprogrammer KvK: 50277553 Installer Maker for LiveCode: http://qery.us/468 Buy my new book Programming LiveCode for the Real Beginner http://qery.us/3fi LiveCode on Facebook: https://www.facebook.com/groups/runrev/ ___ 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: Name shadows another variable
Peter, Can you tell me more about what this error is and does? Craig -Original Message- From: Peter Haworth p...@lcsql.com To: How to use LiveCode use-livecode@lists.runrev.com Sent: Thu, Jun 26, 2014 5:12 pm Subject: Name shadows another variable The above error has been flagged intermittently and incorrectly when compiling a script with Strict Compilation Mode turned on for as long as I've been using Livecode. In the last couple of days, the error has been flagged every time I compile a script in one particular application. I restart Livecode and all is OK - same combination of stacks, no recompile necessary. As far as I know, that's the only way to get around the issue unless I switch off Strict Compilation Mode which I am not willing to do. I know the bug has been entered at the QCC several times and I also know that so far it has been impossible to provide a recipe to reproduce it. I will add the stack exhibiting the problem to one of the error reports but I've done that in the past and RunRev have been unable to reproduce it. I am practically at a standstill with development of this application until this problem is fixed. It seems to me that someone at RunRev needs to take responsibility for finding what causes this problem using old fashioned methods, like going through the code, or reproduce it themselves. Pete lcSQL Software http://www.lcsql.com Home of lcStackBrowser http://www.lcsql.com/lcstackbrowser.html and SQLiteAdmin http://www.lcsql.com/sqliteadmin.html ___ 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: Image control in a Background
Hi Vaughn, I'm glad to hear you got it working. The following is opinion and you may ignore it. I think you could benefit by going to Jacque's site and reviewing the stacks: http://www.hyperactivesw.com/revscriptconf/scriptingconferences.html There are also the forums: http://forums.livecode.com/index.php Which are better suited for questions like this one, here they mostly go on about increasing the decimal point accuracy of liveCode to surpass the 16 digit limit and stuff like that. Scott and Jacque are a couple of the most sought-after/expensive liveCode minds. But of course, either place is fine for you to ask questions. Lots of great material here: http://lessons.runrev.com/ Regards, Simon -- View this message in context: http://runtime-revolution.278305.n4.nabble.com/Image-control-in-a-Background-tp4680553p4680685.html Sent from the Revolution - User mailing list archive at Nabble.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: Name shadows another variable
Not sure i'd know WHERE to do it, guess it depends on the script, but.. could you use delete variable... to fix the problem without having to restart lc? Of course this would probably require you to understand the source of the problem. Another thing I wonder about is the variable preservation preference setting. Wonder if you could pop the tick out of that, compile, then pop it back in. Pain in the butt though. There is a property (the preservervariables) also, that defaults to false I believe, but the recommendation in the dictionary is to not mess with that one. On Thu, Jun 26, 2014 at 5:54 PM, dunb...@aol.com wrote: Peter, Can you tell me more about what this error is and does? Craig -Original Message- From: Peter Haworth p...@lcsql.com To: How to use LiveCode use-livecode@lists.runrev.com Sent: Thu, Jun 26, 2014 5:12 pm Subject: Name shadows another variable The above error has been flagged intermittently and incorrectly when compiling a script with Strict Compilation Mode turned on for as long as I've been using Livecode. In the last couple of days, the error has been flagged every time I compile a script in one particular application. I restart Livecode and all is OK - same combination of stacks, no recompile necessary. As far as I know, that's the only way to get around the issue unless I switch off Strict Compilation Mode which I am not willing to do. I know the bug has been entered at the QCC several times and I also know that so far it has been impossible to provide a recipe to reproduce it. I will add the stack exhibiting the problem to one of the error reports but I've done that in the past and RunRev have been unable to reproduce it. I am practically at a standstill with development of this application until this problem is fixed. It seems to me that someone at RunRev needs to take responsibility for finding what causes this problem using old fashioned methods, like going through the code, or reproduce it themselves. Pete lcSQL Software http://www.lcsql.com Home of lcStackBrowser http://www.lcsql.com/lcstackbrowser.html and SQLiteAdmin http://www.lcsql.com/sqliteadmin.html ___ 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
Calculating age
Hi, does anyone know how to calculate someones age in years from two dates? Currently I am doing something kludgy like: convert dateone from date to seconds convert datetwo from date to seconds put datetwo - dateone into age -- calculate the age in seconds -- divide by the number of seconds per year put 60*60*24*365.25 into secs_per_year put the trunc of (age / secs_per_year) into age But I suspect it is only approximate. Thanks -- View this message in context: http://runtime-revolution.278305.n4.nabble.com/Calculating-age-tp4680687.html Sent from the Revolution - User mailing list archive at Nabble.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: Calculating age
Hi In a database you use a date of birth and calculate today to get the number of days since birth div. by 365 Thank you Vaughn Clement Apps by Vaughn Clement (Support) *http://www.appsbyvaughnclement.com/tools/home-page/ http://www.appsbyvaughnclement.com/tools/home-page/* Skype: vaughn.clement https://secure.join.me/appsbyvclement FaceTime: vclem...@gmail.com LogMeIn also avaialble Call on ooVoo at address: vaughnclement or 9282549062 Ph. 928-254-9062 On Thu, Jun 26, 2014 at 7:44 PM, Mark Smith mark_sm...@cpe.umanitoba.ca wrote: Hi, does anyone know how to calculate someones age in years from two dates? Currently I am doing something kludgy like: convert dateone from date to seconds convert datetwo from date to seconds put datetwo - dateone into age -- calculate the age in seconds -- divide by the number of seconds per year put 60*60*24*365.25 into secs_per_year put the trunc of (age / secs_per_year) into age But I suspect it is only approximate. Thanks -- View this message in context: http://runtime-revolution.278305.n4.nabble.com/Calculating-age-tp4680687.html Sent from the Revolution - User mailing list archive at Nabble.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: Calculating age
Hi. There would be a problem with certain date ranges. Think of thie variation of your script: on mouseUp convert 1/14/1951 from date to seconds put it into dateone convert 1/14/1956 from date to seconds put it into datetwo put datetwo - dateone into age -- calculate the age in seconds -- divide by the number of seconds per year put 60*60*24*365.25 into secs_per_year answer trunc(age / secs_per_year) end mouseUp Its the leap years. You claculate seconds, (and even do the 365.25 thing) but that value may not close a leap year if it falls in the wrong place. Craig Newman convert dateone from date to seconds convert datetwo from date to seconds put datetwo - dateone into age -- calculate the age in seconds -- divide by the number of seconds per year put 60*60*24*365.25 into secs_per_year put the trunc of (age / secs_per_year) into age -Original Message- From: Mark Smith mark_sm...@cpe.umanitoba.ca To: use-revolution use-revolut...@lists.runrev.com Sent: Thu, Jun 26, 2014 10:45 pm Subject: Calculating age Hi, does anyone know how to calculate someones age in years from two dates? Currently I am doing something kludgy like: convert dateone from date to seconds convert datetwo from date to seconds put datetwo - dateone into age -- calculate the age in seconds -- divide by the number of seconds per year put 60*60*24*365.25 into secs_per_year put the trunc of (age / secs_per_year) into age But I suspect it is only approximate. Thanks -- View this message in context: http://runtime-revolution.278305.n4.nabble.com/Calculating-age-tp4680687.html Sent from the Revolution - User mailing list archive at Nabble.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: Calculating age
Check out Sarah Reichelt's Date Time Library. It makes this easy, as well as several other useful time and date calculations. Cheers, - Charles On 26 Jun 2014, at 9:44 PM, Mark Smith mark_sm...@cpe.umanitoba.ca wrote: Hi, does anyone know how to calculate someones age in years from two dates? Currently I am doing something kludgy like: convert dateone from date to seconds convert datetwo from date to seconds put datetwo - dateone into age -- calculate the age in seconds -- divide by the number of seconds per year put 60*60*24*365.25 into secs_per_year put the trunc of (age / secs_per_year) into age But I suspect it is only approximate. Thanks -- View this message in context: http://runtime-revolution.278305.n4.nabble.com/Calculating-age-tp4680687.html Sent from the Revolution - User mailing list archive at Nabble.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 -- Charles E. Buchwald CEO/Director General Museografica Digital http://digital.museografica.com LC Developer Tools: http://buchwald.ca/developer-tools/ Email Notice: http://wp.me/P3aT4d-33 ___ 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: Calculating age
Since you only need straight years, subtract the birth year from the current date then a simple switch statement to adjust for whether the birthdate has been met for the year should work fine. Something like: switch case check to see if the month now month of the birthdate if so, subtract 1 from tYears break case if the month now = the month of the birthdate tBdate) and the day now the day of the birthdate if so, subtract 1 from tYears break end switch Also, curious now. Can you convert dates to seconds if they're before the epoch? Its not working for me in 6.6.2. Anything after 1970 works fine. On Thu, Jun 26, 2014 at 10:57 PM, Charles E Buchwald char...@buchwald.ca wrote: Check out Sarah Reichelt's Date Time Library. It makes this easy, as well as several other useful time and date calculations. Cheers, - Charles On 26 Jun 2014, at 9:44 PM, Mark Smith mark_sm...@cpe.umanitoba.ca wrote: Hi, does anyone know how to calculate someones age in years from two dates? Currently I am doing something kludgy like: convert dateone from date to seconds convert datetwo from date to seconds put datetwo - dateone into age -- calculate the age in seconds -- divide by the number of seconds per year put 60*60*24*365.25 into secs_per_year put the trunc of (age / secs_per_year) into age But I suspect it is only approximate. Thanks -- View this message in context: http://runtime-revolution.278305.n4.nabble.com/Calculating-age-tp4680687.html Sent from the Revolution - User mailing list archive at Nabble.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 -- Charles E. Buchwald CEO/Director General Museografica Digital http://digital.museografica.com LC Developer Tools: http://buchwald.ca/developer-tools/ Email Notice: http://wp.me/P3aT4d-33 ___ 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: Name shadows another variable
Hi Mike, My workaround is to turn off strict compilation mode, compile and turn it back on again but that's fraught with dangerous consequences if I forget to switch it on again. Bottom line is, this shouldn't happen, there should be no need for any workaround. A recent thread talked about paper cuts. For me this is an open, festering wound! Pete lcSQL Software http://www.lcsql.com Home of lcStackBrowser http://www.lcsql.com/lcstackbrowser.html and SQLiteAdmin http://www.lcsql.com/sqliteadmin.html On Thu, Jun 26, 2014 at 6:08 PM, Mike Bonner bonnm...@gmail.com wrote: Not sure i'd know WHERE to do it, guess it depends on the script, but.. could you use delete variable... to fix the problem without having to restart lc? Of course this would probably require you to understand the source of the problem. Another thing I wonder about is the variable preservation preference setting. Wonder if you could pop the tick out of that, compile, then pop it back in. Pain in the butt though. There is a property (the preservervariables) also, that defaults to false I believe, but the recommendation in the dictionary is to not mess with that one. On Thu, Jun 26, 2014 at 5:54 PM, dunb...@aol.com wrote: Peter, Can you tell me more about what this error is and does? Craig -Original Message- From: Peter Haworth p...@lcsql.com To: How to use LiveCode use-livecode@lists.runrev.com Sent: Thu, Jun 26, 2014 5:12 pm Subject: Name shadows another variable The above error has been flagged intermittently and incorrectly when compiling a script with Strict Compilation Mode turned on for as long as I've been using Livecode. In the last couple of days, the error has been flagged every time I compile a script in one particular application. I restart Livecode and all is OK - same combination of stacks, no recompile necessary. As far as I know, that's the only way to get around the issue unless I switch off Strict Compilation Mode which I am not willing to do. I know the bug has been entered at the QCC several times and I also know that so far it has been impossible to provide a recipe to reproduce it. I will add the stack exhibiting the problem to one of the error reports but I've done that in the past and RunRev have been unable to reproduce it. I am practically at a standstill with development of this application until this problem is fixed. It seems to me that someone at RunRev needs to take responsibility for finding what causes this problem using old fashioned methods, like going through the code, or reproduce it themselves. Pete lcSQL Software http://www.lcsql.com Home of lcStackBrowser http://www.lcsql.com/lcstackbrowser.html and SQLiteAdmin http://www.lcsql.com/sqliteadmin.html ___ 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