Years ago I used to use Macromedia Director, and got to be pretty good at
programming objects (the kind that operated independently once they were
birthed...sort of OOP).
What's the best way of doing that sort of thing in LiveCode?
Cheers
Gerry
-- photo site: http://gerryorkin.com
On Tue, Mar 1, 2011 at 2:55 PM, Peter Haworth p...@mollysrevenge.com wrote:
OK, here's an amusing exercise in scripting for you experts out there, but
I'm giving away a prize! I will give the person who provides the best
solution a copy of my band's latest CD, Aged 10 years. the definition
I make a nice little controller that accepts the an encrypted email and
password as post and returns the information being desired from the
controller in an encrypted string that contains the results (encrypted with
a different key for transactions back to my client). revIgniters
ActiveRecord
behaviors + groups = widgets
-- Tom McGrath III
http://lazyriver.on-rev.com
3mcgr...@comcast.net
On Mar 1, 2011, at 4:51 AM, Gerry wrote:
Years ago I used to use Macromedia Director, and got to be pretty good at
programming objects (the kind that operated independently once they were
On Mar 1, 2011, at 9:27 AM, Thomas McGrath III wrote:
behaviors + groups = widgets
That is a bit different to objects. An object might look more like this:
var myobj:MyObj = new MyObj();
myobj.doSomethingSpecial();
You could I suppose have a new thing on the card that you set the script
On 1 Mar 2011, at 16:11, Colin Holgate wrote:
on mouseUp
new Button
set the name of button the number of buttons to myobj
--set the script of button myobj to field my script
set the behaviour of button myobj to the long id of button my script
send dosomethingspecial to button myobj
Hello
I am currently searching for presenters for the live livecode code event, this
week or any week later on. Please mail me off list if you're interested.
currently underrepresented topics:
- super basic stuff like what is a field why should i care, neat tricks with
basic properties
-
Not me, Peter.
Bob
On Mar 1, 2011, at 12:59 AM, Keith Clarke wrote:
Bob,
Just a couple of thoughts - I don't know what you're trying to achieve with
your app, but are you sure you even want to have such settings to follow the
user's machine/OS settings automatically?
Hi Keith,
Actually, it's me who is trying to implement this not Bob. You raise some good
points though. My first question is why on earth would you be running
Salesforce when you're on holiday in the Maldives :-)
My thoughts are that are that the first time you run my application, it will
Oh hell, I will just buy that outright! I love Celtic music and used to play in
a marching bagpipe band. And yes, I wore a kilt! I looked good in it too.
Bob
On Feb 28, 2011, at 8:55 PM, Peter Haworth wrote:
OK, here's an amusing exercise in scripting for you experts out there, but
I'm
Hi Sarah,
Sorry for the confusion, bad terminology! You're right when you say it's just
the currency value stored without the decimal point (although the number of
implied decimal points is part of the formatting spec, not fixed at 2).
I'll come up with some test cases today and send them in
In LC, buttons and fields are objects with methods (functions and
commands) and member variables (custom properties) and so are groups. It's
possible to create an empty group under script control (create group set
name of last group to myName) and set its behavior to a previously arranged
object,
On Mar 1, 2011, at 10:34 AM, Björnke von Gierke wrote:
Ok you can't use a field, but beyond that? totally working?
It works with a button, and the plan would be to set the button to be
invisible. It's just a container for handlers, and if it's self sufficient code
it would be a bit like an
I know I should probably use a stack of my own for these but I've been using
the 'answer' and 'ask' commands so long that it's become a daunting task to
swap them all out for something else. Anyway, anybody know where these
stacks reside so I can alter their appearance and other things like where
Yes, the situation is certainly different for web apps (mine's a desktop app).
The coding is quite simple to get the OS preferences and store them. The hard
part is the formatting code which has to be done no matter where I get the
prefs from. LC makes it easy to deal with dates and times
On 3/1/11 2:11 AM, Joseba Aguayo wrote:
Finally my stack run OK in windows 7 (with Revolution Player)
But run slooowly when save datas.
The stack have 3,8Mb and for save datas in about 10-15 seconds. Is this normal?
In Windows XP or Mac save datas in 1-2 seconds.
The Player is very old and
Hoping someone might come up with some help. To recap, if I execute the command
locale -k LC_NUMERIC
...from Terminal on my Mac, the output is
decimal_point=.
thousands_sep=,
grouping=3;3
However, if I use the LC Shell command to issue the same command and put the
output into a field, it
It's possible that when you launch Terminal.app you are using BASH and that
LC is using SH (or something other than BASH) that doesn't have the
localization environment setup the same?
That's just a guess.
Jeff M.
On Tue, Mar 1, 2011 at 2:00 PM, Peter Haworth p...@mollysrevenge.comwrote:
Thanks Jeff. I tried setting the shellCommand property to point to bash but
still the same problem.
Pete Haworth
http://www.mollysrevenge.com
http://www.sonicbids.com/MollysRevenge
http://www.myspace.com/mollysrevengeband
On Mar 1, 2011, at 1:13 PM, Jeff Massung wrote:
It's
the LC shell command launches a shell which not the same as the one in
Terminal. I am unfortunately not a Unix guru, but I know this has consequences
on some default options, even if you use the same variant of the shell (BASH,
I believe).
Le 1 mars 2011 à 22:00, Peter Haworth a écrit :
Hey Jeff,
I also tried using the Bourne shell in Temrinal (the dictionary says that's
what LC uses by default), and I got the same results as with bash. I wish it
had been that simple!
Pete Haworth
On Mar 1, 2011, at 1:13 PM, Jeff Massung wrote:
It's possible that when you launch
On Tue, 2011-03-01 at 13:00 -0800, Peter Haworth wrote:
Hoping someone might come up with some help. To recap, if I execute the
command
locale -k LC_NUMERIC
...from Terminal on my Mac, the output is
decimal_point=.
thousands_sep=,
grouping=3;3
However, if I use the LC Shell
Thanks Francois. I don;t think that's the problem though. If I use the LC
shell command to execute the locale command and put it's output into a file,
the contents of the file are correct. BUt then if I open the file in LC and
put the contents into a field, it's garbled again.
I wonder if
Thanks Warren. I just used the message box on my Mac and got the same
(incorrect) output too. It's good to know if works under Linux though because
that makes me think it's an LC bug even more.
I'm currently researching if there's a way to get this info using Applescript
(without issuing a
If theres a .bashrc file, or .. well I forget what its name is supposed to
be, you might try
shell(source path/to/my/.bashrc; locale -k LC_NUMERIC)
Basically, find the file that bash loads, source it to force to be
processed, and then tack your command onto the end.
On Tue, Mar 1, 2011 at 2:54
oh. If lc uses sh not bash, might need to parse whatever the default shell
resource file is for the LANG string, at which point you could manually set
it before calling locale. I don't recall if sh and bash are similar enough
to eat the same file.
On Tue, Mar 1, 2011 at 3:10 PM, Mike Bonner
On Tue, 2011-03-01 at 15:13 -0700, Mike Bonner wrote:
oh. If lc uses sh not bash, might need to parse whatever the default shell
resource file is for the LANG string, at which point you could manually set
it before calling locale. I don't recall if sh and bash are similar enough
to eat the
Ah k, hadn't seen this one..
*Thanks Francois. I don;t think that's the problem though. If I use the LC
shell command to execute the locale command and put it's output into a file,
the contents of the file are correct. BUt then if I open the file in LC and
put the contents into a field, it's
Hi all,
I am trying to create an eComic with Livecode and I need the user to be able to
scroll each page vertically or horizontally. When I developped the App in
Objective-C, I had to implement a scrollview, but as I am still a beginner, I
don't know how to do this in Livecode yet. Can
On Mar 1, 2011, at 10:08 AM, Ray Horsley wrote:
I know I should probably use a stack of my own for these but I've
been using
the 'answer' and 'ask' commands so long that it's become a daunting
task to
swap them all out for something else. Anyway, anybody know where
these
stacks reside so
On Mar 1, 2011, at 2:55 PM, Eric Peyron wrote:
Hi all,
I am trying to create an eComic with Livecode and I need the user to
be able to scroll each page vertically or horizontally. When I
developped the App in Objective-C, I had to implement a scrollview,
but as I am still a beginner, I
Eric - check under 'example stacks and resources' in the Livecode help menu.
There should be an iOS scroller example there that has both vertical and
horizontal scrolling implemented.
Regards,
Terry...
On 2/03/11 10:19 AM, Jim Ault jimaultw...@yahoo.com wrote:
On Mar 1, 2011, at 2:55 PM,
OK, In terminal, that returns LANG=en_US.UTF-8. With the LC shell command,
it returns nothing!! There's definitely something weird going on with the LC
shell command.
Pete Haworth
On Mar 1, 2011, at 2:44 PM, Mike Bonner wrote:
I'd still be curious to know if
env; |grep LANG
returns the
Ok, the plot thickens! I ran a simple Applescript from the Applescript editor:
do shell script (locale -k LC_MONETARY)
and got the same problem!
Pete Haworth
On Mar 1, 2011, at 2:44 PM, Mike Bonner wrote:
Ah k, hadn't seen this one..
*Thanks Francois. I don;t think that's the problem
Ok, while this doesn't solve the issue, if you do
shell(LANG=en_US.UTF-8;locale -k LC_NUMERIC)
You get back the correct info yes?
The problem here is that (I think someone said this farther up) the process
shell uses isn't the same as a full blown terminal start. If you have a
.bash_profile
Hi Andrew,
No, I'm sorry it doesn't...
I know exactly what you mean, but I got no idea how to setup something like
this :-(
warm regards,
Ton Kuypers
On 1-mrt-2011, at 15:02, Andrew Kluthe wrote:
I make a nice little controller that accepts the an encrypted email and
password as post
Oh. And since it's UTF-8, and it looks correct in the file apparently (which
is weird with no LANG env variable) would that affect how you have to manage
the results? I'm definately not a font guy, so dunno the answer to that.
On Tue, Mar 1, 2011 at 5:04 PM, Mike Bonner bonnm...@gmail.com wrote:
Jim,
Very helpful!
Thanks,
Ray
-Original Message-
From: use-livecode-boun...@lists.runrev.com
[mailto:use-livecode-boun...@lists.runrev.com] On Behalf Of Jim Ault
Sent: Tuesday, March 01, 2011 6:11 PM
To: How to use LiveCode
Subject: Re: Answer and Ask Dialogs
On Mar 1, 2011, at 10:08
Thanks Mike. 'Fraid the command you gave me still returns the incorrect info
when executed with the LC shell command.
In answer to your other email, I'm trying to get this info so I can format
numbers and currency in my application according to the user's preferences,
rather than having the
Recently, Eric Peyron wrote:
I am trying to create an eComic with Livecode and I need the user to be able
to scroll each page vertically or horizontally. When I developped the App in
Objective-C, I had to implement a scrollview, but as I am still a beginner, I
don't know how to do this in
Hi all.
I just came across a curious issue where I had an if then else control
structure inside another if then structure.
I *thought* I used toe be able to use the form
if statement then
-- do somestuff
else if anotherstatement then
-- do someotherstuff
else
-- do defaultstuff
I'm curious is there really a real-life use-case for the group spec ?
i.e. variable size groupings of digits ?
Not sure what order you want for currency and neg sign ? Should it be
$-123 or -$123
and should it be 123-$ or 123$- ?
Should there always be a 0 before the point ? i.e.
Bob - as you've found out, nested if/then statements tend to break down in
unexpected ways when you mix the short and long forms of the syntax. To be
on the safe side, always opt for the long form when nesting statements -
these always compile correctly.
Terry...
On 2/03/11 11:40 AM, Bob
Well if you can figure out how to get locale to work from an lc shell, there
are interesting things that can be done in that vein using python.
If LANG is set to en_GB, and locale is actually working, you can feed it to
a python script such as this
#!/usr/bin/python
import locale -- for locale
Hi Alex,
To be honest, I'm not sure if there's a real life case for variable sizing of
groups! I'm using the specs for the information returned by the Unix locale
LC_MONETARY command and it specifically talks about the group spec this way.
Seems unlikely but it adds to the spice of writing a
Yeah, was just pointing out that since os x has python installed by default
(right?) could include a small python script and just feed it numbers
through shell anytime you wanted a currency format. Not sure how fast it
would be for lots of conversions though. /shrug
On Tue, Mar 1, 2011 at 6:37
That's definitely an option if I don't find a solution to getting the locale
info from within LiveCode. Unfortunately, I know nothing about python. I've
been sent some pretty cool LC scripts to do this formatting in response to my
post about it. I'm almost at the point where I will just have
On 3/1/11 6:40 PM, Bob Sneidar wrote:
Hi all.
I just came across a curious issue where I had an if then else control
structure inside another if then structure.
I *thought* I used toe be able to use the form
if statement then
-- do somestuff
else if anotherstatement then
-- do
This goes way back to the earliest HC days. You can even find cases where
indentation doesn't even work, never mind successful compiles, even though the
construction is sound. I seem to remember that in HC, it happened both ways
with mixed constructs as well, that failed indentations worked,
Hmmm. Perhaps towards the end of the month, I could do a two parter for
livecode.tv. An intro to revIgniter and a talk on building web services with
it.
--
View this message in context:
http://runtime-revolution.278305.n4.nabble.com/using-mySQL-on-a-web-based-server-tp3328963p3331110.html
Sent
50 matches
Mail list logo