Speed optimisation

2005-10-05 Thread Rob Beynon
Dear Colleagues, I have a function that takes a time in this format hh:mm:ss.s and to which I add a variable number of seconds, then output the updated time in the same format. hh can be greater than 24! Here's the function. Problem is, it seems slow (I need to do this call about 150,000 times

Re: Speed optimisation

2005-10-05 Thread Wouter
Hi, May be this will do? (just to give an idea, can be tweaked) function newTime oldTime,addedSec set the twelvehourtime to false convert oldTime to seconds add addedSec to oldTime convert oldTime to long time if length(oldTime) = 8 then return oldTime else return 0 oldTime end

Re: Speed optimisation

2005-10-05 Thread Geoff Canyon
I wrote the following alternative. It's about twice as fast, which is less than I had hoped for. One real speed gain if your data is at all repetitive would be to memo-ize your function. Keep a table of a few thousand inputs and outputs. Whenever you get a call with the same values that

RE: Looking for Implementation Advice

2005-10-05 Thread Mike Doub
Thanks Alex, I appreciate your input. I was thinking about dynamically creating some array of objects, but I did not made to connection to put the data in the object itself. It is so obvious now. Setting the tool tip property is really clever. How would you recommend managing setting up the

Re: Determine active OS langguage

2005-10-05 Thread graham samuel
Hi Trevor Tried your function out on a French Windows XP SP2 system running RunRev 2.6 (after taking out spurious returns) and it didn't work - it just returned en because your registry query put nothing into tUserLangs. I am no expert, but it looks to me as if the Registry entries in

Re: Speed optimisation

2005-10-05 Thread Dick Kriesel
On 10/4/05 11:58 PM, Rob Beynon [EMAIL PROTECTED] wrote: Dear Colleagues, I have a function that takes a time in this format hh:mm:ss.s and to which I add a variable number of seconds, then output the updated time in the same format. hh can be greater than 24! Here's the function.

Re: Speed optimisation

2005-10-05 Thread Sarah Reichelt
I tested the suggestions and a couple of my own and couldn't find anything faster than Wouter's suggestions, with Dick's being very similar. I challenge for the shortest function :-) function newTime pTime, pAdd set the itemDel to : add pAdd to item 3 of pTime convert pTime to long time

Re: Determine active OS langguage

2005-10-05 Thread graham samuel
Oops - I'm an amateur at these things. I now see that there is also another folder, Geo, within Control Panel\International, and I can see Control Panel\International\Geo\Nation of which the value on my machine is 84 (presumably Hex, so decimal 132). Not sure what that means, but it still

stack on server very very slow

2005-10-05 Thread andreas
In several posts one can read, that a stack, when networked, can be slow, due to the save statement. I have a solution on a client computer and the stack is (now) on a server. Setup is OS X 10.4 After porting this stack to the server machine, it behaves very slow (more than 1000! times

Stack Switching Question

2005-10-05 Thread AbilityForms
Hi Everyone, Often times I have a button switch stacks in order to retrieve data that I need to complete that button's task. In HyperCard I could lock the screen, lock the messages, push the card, go to the data stack, retrieve the data, pop the card and insert the found data. All without

ReplaceText and Backslash

2005-10-05 Thread Todd Geist
Hello, I have a string that comes from Applescript and it has a bunch of / in it. It looks like this Script id=\7\ name=\New Script 2\ includeInMenu=\True\ I would like to replace the Backslash Quote string with just Quote. But this does not work. put replaceText (theString, backslash

Re: Stack Switching Question

2005-10-05 Thread Richard Gaskin
[EMAIL PROTECTED] wrote: Hi Everyone, Often times I have a button switch stacks in order to retrieve data that I need to complete that button's task. In HyperCard I could lock the screen, lock the messages, push the card, go to the data stack, retrieve the data, pop the card and insert the

Stack Switching Question again

2005-10-05 Thread AbilityForms
In a message dated 10/5/05 10:47:20 AM, [EMAIL PROTECTED] writes: [EMAIL PROTECTED] wrote: Hi Everyone, Often times I have a button switch stacks in order to retrieve data that I need to complete that button's task. In HyperCard I could lock the screen, lock the messages, push the

Re: stack on server very very slow

2005-10-05 Thread Phil Jimmieson
In several posts one can read, that a stack, when networked, can be slow, due to the save statement. I have a solution on a client computer and the stack is (now) on a server. Setup is OS X 10.4 After porting this stack to the server machine, it behaves very slow (more than 1000! times

Re: Speed optimization

2005-10-05 Thread kee nethery
My favorite way to speed things up is to do something like put 0 into x function newTime oldTime,addedSec if x mod 100 = 0 then -- stuff from smart people in previous posts end if add 1 to x end newTime Do you really need to change that variable every millisecond

RE: ReplaceText and Backslash

2005-10-05 Thread Lynch, Jonathan
Does this work: Put \ quote into tRep Replace tRep with quote in tString -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Todd Geist Sent: Tuesday, October 04, 2005 3:35 AM To: use-revolution@lists.runrev.com Subject: ReplaceText and Backslash Hello, I

Re: Stack Switching Question

2005-10-05 Thread simplsol
Richard, I believe stack MyData.rev would have to be open already in order to get fld Whatever. Paul Looney -Original Message- From: Richard Gaskin [EMAIL PROTECTED] To: How to use Revolution use-revolution@lists.runrev.com Sent: Wed, 05 Oct 2005 07:47:04 -0700 Subject: Re: Stack

Re: Stack Switching Question

2005-10-05 Thread Klaus Major
Hi Paul, Richard, I believe stack MyData.rev would have to be open already in order to get fld Whatever. no, it doesn't :-) Paul Looney -Original Message- From: Richard Gaskin [EMAIL PROTECTED] To: How to use Revolution use-revolution@lists.runrev.com Sent: Wed, 05 Oct 2005

Re: Stack Switching Question

2005-10-05 Thread TJ Frame
Then can't you use go invisible... ? On 10/5/05, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: Richard, I believe stack MyData.rev would have to be open already in order to get fld Whatever. Paul Looney -Original Message- From: Richard Gaskin [EMAIL PROTECTED] To: How to use

Re: Stack Switching Question

2005-10-05 Thread Richard Gaskin
[EMAIL PROTECTED] wrote: Often times I have a button switch stacks in order to retrieve data that I need to complete that button's task. In HyperCard I could lock the screen, lock the messages, push the card, go to the data stack, retrieve the data, pop the card and insert the found data.

Re: Speed optimization

2005-10-05 Thread Alex Tweedly
kee nethery wrote: My favorite way to speed things up is to do something like put 0 into x function newTime oldTime,addedSec if x mod 100 = 0 then -- stuff from smart people in previous posts end if add 1 to x end newTime Do you really need to change that

Re: Looking for Implementation Advice

2005-10-05 Thread Alex Tweedly
Mike Doub wrote: How would you recommend managing setting up the locations of the buttons? Depends on whether your app is going to have resizeable windows or not, and whether you're going to put it in a scrolling group, and what else scrolls, and Do I just pick an x,y location on the

Re: Stack Switching Question again

2005-10-05 Thread Mark Smith
But you can still just refer to the data stack.. repeat with n = 1 to the number of cds in stack dataStack repeat for each line L in fld somedata of cd n of stack dataStack if L is whatImAfter then doSomethingWith L end if end repeat end repeat the point being that you can

Re: Stack Switching Question again

2005-10-05 Thread Robert Brenstein
In a message dated 10/5/05 10:47:20 AM, [EMAIL PROTECTED] writes: [EMAIL PROTECTED] wrote: Hi Everyone, Often times I have a button switch stacks in order to retrieve data that I need to complete that button's task. In HyperCard I could lock the screen, lock the messages, push the

Sound Files

2005-10-05 Thread Louis Molina
I need help!!! How do I bring sound to a card? The scripts you have don't seem to work. I need to play a aif or a mov file when a card opens. Please help me! ___ use-revolution mailing list use-revolution@lists.runrev.com Please visit this url

Re: Determine active OS langguage

2005-10-05 Thread Trevor DeVore
On Oct 5, 2005, at 2:37 AM, graham samuel wrote: Hi Trevor Tried your function out on a French Windows XP SP2 system running RunRev 2.6 (after taking out spurious returns) and it didn't work - it just returned en because your registry query put nothing into tUserLangs. I am no expert,

Re: Determine active OS langguage

2005-10-05 Thread Scott Rossi
Recently, Trevor DeVore wrote: Let me walk through the logic of the function to see where it might be going wrong. ... get queryRegistry(HKEY_CURRENT_USER\Control Panel\International \Locale) -- RETURNS HEX get baseConvert(it,16,10) -- CONVERT HEX TO DECIMAL (1036 FOR FRENCH STANDARD)

Re: Determine active OS langguage

2005-10-05 Thread Trevor DeVore
On Oct 5, 2005, at 10:51 AM, Scott Rossi wrote: Recently, Trevor DeVore wrote: Let me walk through the logic of the function to see where it might be going wrong. ... get queryRegistry(HKEY_CURRENT_USER\Control Panel\International \Locale) -- RETURNS HEX get baseConvert(it,16,10) -- CONVERT

Re: stack on server very very slow

2005-10-05 Thread andreas
Hello Phil thanks for your hint. In this case, the save command works speedy. Only stackoperations take very long. There is a lot of text-processing going on, on many fields on many cards. What surprises me, is exactly this: Why should this take longer than with the local stack? Both,

Oracle DB Connection

2005-10-05 Thread David Anderson
Hello All I have just purchased the Enterprise license so I can connect to an oracle database. Reading in the documentation, it says: Oracle: Oracle database drivers are not included as part of the Revolution installation on any platform. To obtain an Oracle database driver for your

Setting Custom Property to an Array

2005-10-05 Thread David Burgun
Hi, How can I set the Customer Property of a Stack to an array? The following does not seem to work: local myArray set the cpArray of this stack to myArray Thanks a lot Dave ___ use-revolution mailing list use-revolution@lists.runrev.com Please

Re: Setting Custom Property to an Array

2005-10-05 Thread Dave Cragg
On 5 Oct 2005, at 19:16, David Burgun wrote: Hi, How can I set the Customer Property of a Stack to an array? The following does not seem to work: local myArray set the cpArray of this stack to myArray set the customProperties[cpArray] of this stack to myArray Cheers Dave

Re: Determine active OS langguage

2005-10-05 Thread Scott Rossi
Recently, Trevor DeVore wrote: Without knowing exactly what you're doing, I think you may not need the bitAND portion of the code. If you're using the MS provided tables of locales and/or languages, you only need to get either decimal or hex values. In the localized projects I've worked

Re: Determine active OS langguage

2005-10-05 Thread Trevor DeVore
On Oct 5, 2005, at 11:33 AM, Scott Rossi wrote: It's been a long time since I did this but I think all you need to do is grab the last two digits of the language identifier code. If you look at MS's table, you'll see that groups of related languages (such as English) all end with the

Re: Stack Switching Question

2005-10-05 Thread J. Landman Gay
Richard Gaskin wrote: I used the file name form to illustrate another difference between HC and Rev: while you would indeed need to open a stack in HC in order to get stuff out of it, in Rev you can get property values of objects in unopened stacks. When you do that the engine reads the

Re: Setting Custom Property to an Array

2005-10-05 Thread Mark Smith
Dave, you can have pretty much as many Custom Property Sets as you like. Each custom property set is an array. You can store an array in a custom property set as Dave Cragg has shown ie: set the CustomProperties[myData] of this stack to myArray. You can also then refer to the individual

Re: stack on server very very slow: solution for workaround

2005-10-05 Thread andreas
Hello Phil strange workaround to gain back speed on server stored stacks: :-) There are two ways to gain access to a remote stack: I) The easy way: (NOT WORKING) set the stackFiles of this stack to deutsch1.rev, ServerVerzeichnis put deutsch1.rev into PlugIn open stack PlugIn - This

Re: Stack Switching Question

2005-10-05 Thread Richard Gaskin
J. Landman Gay wrote: Richard Gaskin wrote: I used the file name form to illustrate another difference between HC and Rev: while you would indeed need to open a stack in HC in order to get stuff out of it, in Rev you can get property values of objects in unopened stacks. When you do that

Re: Stack Switching Question

2005-10-05 Thread Dave Cragg
On 5 Oct 2005, at 21:04, Richard Gaskin wrote: J. Landman Gay wrote: Richard Gaskin wrote: I used the file name form to illustrate another difference between HC and Rev: while you would indeed need to open a stack in HC in order to get stuff out of it, in Rev you can get property

Re: Machine network names

2005-10-05 Thread Devin Asay
Jacque, I'm tardy here, but didn't see any replies. Could you write a shell script that ssh'ed to the remote machine, then check the $HOST variable. Kinda roundabout, I know. Or how about just getting the number of bytes of data on each disk. Not guaranteed to be unique, but the chances

Re: Export/Import Stacks as XML

2005-10-05 Thread Marielle Lange
Hi David, ... obviously, I don't check the revolution digest everyday ;-). Whats - the interest? Is there not something going on with standards based file formats for education or...??? or do I have crossed wires? David, what do you mean by something going on with standards based file

Re: Machine network names

2005-10-05 Thread Andre Garzia
Jacque, Is this program running on remote machine or local machine wondering about a remote connection? Some way to do this is by using reverse dns lookup. you can use host ip address on a shell command to resolve it back to the hostname but this works only with registered ips. From your

Re: Bizarre problem of disappearing pictures on reducing stack size

2005-10-05 Thread Stgoldberg
Yes, Jaqueline, that seems to be the problem. The missing pictures are all in the same place and same size and correct layer, but getting the imagedata of the missing images comes up empty, unlike the other images. I don't know why, but thanks for the clarification. Another mystery,

Early Update Pack

2005-10-05 Thread Jesse Sng
Hi, I'm curious about what's the advantage of the Early Update Pack for Rev Studio. As a developer who's delivering a project, is it advantageous to sign up for it? I guess what I'm trying to figure out is whether the Early Update allows me to tap in early into bug fixes or is this more to

Re: Stack Switching Question

2005-10-05 Thread J. Landman Gay
Dave Cragg wrote: On 5 Oct 2005, at 21:04, Richard Gaskin wrote: J. Landman Gay wrote: Richard Gaskin wrote: I used the file name form to illustrate another difference between HC and Rev: while you would indeed need to open a stack in HC in order to get stuff out of it, in Rev you can

Re: Stack Switching Question

2005-10-05 Thread Richard Gaskin
J. Landman Gay wrote: Dave Cragg wrote: On 5 Oct 2005, at 21:04, Richard Gaskin wrote: J. Landman Gay wrote: Richard Gaskin wrote: I used the file name form to illustrate another difference between HC and Rev: while you would indeed need to open a stack in HC in order to get stuff

Re: Machine network names

2005-10-05 Thread J. Landman Gay
Devin Asay wrote: Jacque, I'm tardy here, but didn't see any replies. Could you write a shell script that ssh'ed to the remote machine, then check the $HOST variable. Kinda roundabout, I know. Or how about just getting the number of bytes of data on each disk. Not guaranteed to be

Re: Bizarre problem of disappearing pictures on reducing stack size

2005-10-05 Thread Chipp Walters
Steve, Feel free to send me the stack in question (as long as it's not larger than 2 Mb - I have a slow connection here at the ranch). I'll take a look and get back to you. best, Chipp chippATchippDOTcom [EMAIL PROTECTED] wrote: I tried this but, for some reason the stack size increased

Re: Stack Switching Question

2005-10-05 Thread simplsol
Richard, Jacque, et. al., By destroyStack don't we always mean purge stack? PL -Original Message- From: Richard Gaskin [EMAIL PROTECTED] To: How to use Revolution use-revolution@lists.runrev.com Sent: Wed, 05 Oct 2005 20:19:01 -0700 Subject: Re: Stack Switching Question J. Landman Gay

Re: Stack Switching Question

2005-10-05 Thread Jeanne A. E. DeVoto
At 12:25 AM -0400 10/6/2005, [EMAIL PROTECTED] wrote: Richard, Jacque, et. al., By destroyStack don't we always mean purge stack? The delete stack command, when used on a main stack, purges the stack from memory. However, when used on a substack, it deletes that substack from the stack file.

Re: Stack Switching Question

2005-10-05 Thread Richard Gaskin
Jeanne A. E. DeVoto wrote: At 12:25 AM -0400 10/6/2005, [EMAIL PROTECTED] wrote: By destroyStack don't we always mean purge stack? The delete stack command, when used on a main stack, purges the stack from memory. However, when used on a substack, it deletes that substack from the stack

Re: Machine network names

2005-10-05 Thread Sarah Reichelt
What I eventually decided to use for the unique machine ID -- instead of its network name -- was the host machine's MAC address. This handler gets that info, regardless of whether the program is running locally or remotely: I don't expect it matters but you can have more than one MAC

Function to easily read values from a plist file

2005-10-05 Thread Ken Ray
After Jacque discovered the data in the preferences.plist file she needed, I decided to write a general-purpose function that would get values from a plist file... it's a bit long, but it takes into account a number of different scenarios for retrieving data. Enjoy! And let me know if I need to

Re: Function to easily read values from a plist file

2005-10-05 Thread Ken Ray
On 10/6/05 12:40 AM, Ken Ray [EMAIL PROTECTED] wrote: stsReadFromPlist pathTopListFile,keyPath By the way, for those of you with Scripter's Scrapbook 5, this has been posted to SSBK Online so you can just browse and click a button to copy it into your scrapbook - eliminates the need to