Re: Script Improvement Advice

2003-06-06 Thread Cubist
In a message dated 6/5/2003 3:22:28 AM, [EMAIL PROTECTED] writes: > > >Message: 11 > sez [EMAIL PROTECTED]> >What I tend to do is put the script in the card and then call the >routine from the button e.g. > >In the button > >On mouseup > DisplayElement > --this invokes the handler named Dis

Re: Script Improvement Advice

2003-06-06 Thread Richard Gaskin
Paul Charlesworth wrote: > Then my few days of learning to program kicks in and I get a little > confused with what comes next. Do I create that property using script > or the property inspector? If so, how and how do I call it? In Revolution Development Guide, choose "Values & Properties" --

Re: Script Improvement Advice

2003-06-05 Thread Paul Charlesworth
Cool! I'll need to read a little more to understand the "getline" part of the script, but the idea of allowing an end user to edit the content would be useful if they want a different number of sig figs for example. Not only that, but it would save me a lot of "put" and "set" commands. Thanks,

Re: Script Improvement Advice

2003-06-05 Thread T. R. Ponn
Hello Paul, This looks like a fun one. I'd do something like this: Create a scrolling field and name it Data1 Put your data into the scrolling field in the form: H,Hydrogen,1,1.08,37,N/A, with 1 element to a line. Set the script to: on mouseUp hide me end mouseUp Now lock the field

Re: Script Improvement Advice

2003-06-05 Thread Paul Charlesworth
I was thinking of copy/pasting from a WYSIWYG editor to create the HTML code since I don't have enough experience (one week) with Revolution to write a function. Having said that, it might be a good learning experience and provide me with a useful tool for more chemistry projects. Thanks, Pau

Re: Script Improvement Advice

2003-06-05 Thread curry
Why not set up a tabbed (table) field first to enter all your data in rows, then use a script to read it into a custom property array. Then a handler to put the appropriate data from that array into the fields based on the name or number of the element (whatever you use for array index), and ca

Re: Script Improvement Advice

2003-06-05 Thread Paul Charlesworth
Thank you for all the suggestions. I am amazed that there are so many different ways to achieve the same result. Paul On Thursday, Jun 5, 2003, at 06:32 America/Detroit, Malte Brill wrote: Hi Paul, What I would like to know is the most elegant beginners way to script the placement of propertie

Re: Script Improvement Advice

2003-06-05 Thread Malte Brill
Hi Paul, >What I would like to know is the most elegant beginners way to script >the placement of properties into each field on pressing an element >button. At this point I am adding the following script to each button: Here is my two euro-cents. I would start naming the fields you want to put y

Re: Script Improvement Advice

2003-06-05 Thread Marian Petrides
What I tend to do is put the script in the card and then call the routine from the button e.g. In the button On mouseup DisplayElement --this invokes the handler named DisplayElement which is then found in the card script In the card script On DisplayElement --this is the actual handler --

Script Improvement Advice

2003-06-05 Thread Paul Charlesworth
Dear All: I am working on my first ever programming project, a simple periodic table, and have created the interface using colored buttons. At the bottom of the screen I have an area with elemental properties. This is basically a Tab area (for future options) and a series of fields for each pr

RE: Script Improvement Advice

2003-06-05 Thread Chipp Walters
Hi Paul, I'd probably use custom properties. I'd set the "myPeriodicProps" of button "my_Hydrogen" to: Hydrogen 1 1.008 37 N/A etc.. and do the same with all the other buttons. Then I'd make sure the button names all begin with "my_" and none of them have a 'on mouseup' handler. I'd put the fo

Script Improvement Advice

2003-06-05 Thread Paul Charlesworth
Dear All: I am working on my first ever programming project, a simple periodic table, and have created the interface using colored buttons. At the bottom of the screen I have an area with elemental properties. This is basically a Tab area (for future options) and a series of fields for each pr