Search found 22 matches

by drhoward
Wed May 13, 2015 9:02 am
Forum: Getting Started with LiveCode - Complete Beginners
Topic: Limiting allowed key stroked in a text entry field
Replies: 7
Views: 4284

Re: Limiting allowed key stroked in a text entry field

Thank you! Your suggestion worked when there was only 1 digit in the field and a modification of it worked for two digit in the field. Rather than have 2 compound if statements in a row, I pulled out the common part and made it an initial if statement. The key to making this work was your cluing me ...
by drhoward
Tue May 12, 2015 7:39 pm
Forum: Getting Started with LiveCode - Complete Beginners
Topic: Limiting allowed key stroked in a text entry field
Replies: 7
Views: 4284

Re: Limiting allowed key stroked in a text entry field

I'm sorry! I wasn't clear. This doesn't take care of either single character or double character cases! The only characters allowed are numeric. This allows any character to be inserted. Is there any way that we can write a command that says something like: if Field VolumeField is highlighted then ....
by drhoward
Tue May 12, 2015 7:27 pm
Forum: Getting Started with LiveCode - Complete Beginners
Topic: A possible race condition
Replies: 3
Views: 2515

Re: A possible race condition

The "wait 0 milliseconds" worked fine. I turned off the visible property within the mouseUp handler. With the wait command, installed in key routines, the abort button disappears when pushed and the program aborts properly.

Thanks!
by drhoward
Tue May 12, 2015 4:29 pm
Forum: Getting Started with LiveCode - Complete Beginners
Topic: A possible race condition
Replies: 3
Views: 2515

A possible race condition

I have a program that uses long running loops. Within these loops, I''m copying one buffer into another, byte by byte. There are times that I may need to abort the operation so I created an "Abort Button". Within these loops I also have a test so that every 1000th time through the loop the program u...
by drhoward
Tue May 12, 2015 3:43 pm
Forum: Getting Started with LiveCode - Complete Beginners
Topic: Using Globals
Replies: 8
Views: 5246

Re: Using Globals

Thank you! That explains a lot and handled my problem.
by drhoward
Tue May 12, 2015 3:37 pm
Forum: Getting Started with LiveCode - Complete Beginners
Topic: Limiting allowed key stroked in a text entry field
Replies: 7
Views: 4284

Re: Limiting allowed key stroked in a text entry field

I tried what you suggested. Unfortunately, this doesn't appear to address the root of the problem, which is that I still have no way of detecting whether one or both digits in the Field have been highlighted or not. I have to perform different functions if there has been a highlight and if there has...
by drhoward
Tue May 12, 2015 9:27 am
Forum: Getting Started with LiveCode - Complete Beginners
Topic: Using Globals
Replies: 8
Views: 5246

Using Globals

I'm having a problem using global variables. In the main stack (I only have 1 stack). I'm declaring a variable to be global as follows: Global gAbortFlag Then in the handler openStack I'm setting it to false using the following code: put false into gAbortFlag I have an abort button defined and when ...
by drhoward
Tue May 12, 2015 8:37 am
Forum: Getting Started with LiveCode - Complete Beginners
Topic: Limiting allowed key stroked in a text entry field
Replies: 7
Views: 4284

Limiting allowed key stroked in a text entry field

I have a text entry field in which I use the handler rawKeyDown to limit the acceptable key strokes to numeric, backspace, delete, right arrow and left arrow. In this handler, I also restrict the entry to the range 0 to 99 (2 digits maximum). It works fine except for the case where there are 2 digit...
by drhoward
Fri May 01, 2015 9:02 am
Forum: Converting to LiveCode
Topic: Selecting a file to open using the answer function
Replies: 2
Views: 8777

Selecting a file to open using the answer function

I'm working on a program that reads a csv file and am using the answer file function. The function has a parameter to specify the file type. However, when I get to the directory containing my file, all of the files are displayed, not just the csv files. I've tried various ways of entering the parame...
by drhoward
Wed Apr 29, 2015 4:38 pm
Forum: Getting Started with LiveCode - Complete Beginners
Topic: Message box popping up in middle of a run
Replies: 3
Views: 2642

Re: Message box popping up in middle of a run

Thank you! This worked. It was not clear to me from the dictionary writeup that the result flag would be handled in this manner.
by drhoward
Wed Apr 29, 2015 10:26 am
Forum: Getting Started with LiveCode - Complete Beginners
Topic: Message box popping up in middle of a run
Replies: 3
Views: 2642

Message box popping up in middle of a run

I wrote a program that appears to be working properly. However, a single line message box keeps popping up and I can't find out why. I've pinned it down to the execution of a single line of code. Here is the section of code that contains that line: I've used the editor for this blog to highlight the...
by drhoward
Tue Apr 21, 2015 11:30 pm
Forum: Getting Started with LiveCode - Complete Beginners
Topic: String parsing
Replies: 7
Views: 4457

Re: String parsing

My thanks to all of you. This feature was not available in programming languages that I've used in the past. It's been over 30 years since I programmed professionally, and I had not used a stack based language of this type.
by drhoward
Tue Apr 21, 2015 3:56 pm
Forum: Getting Started with LiveCode - Complete Beginners
Topic: String parsing
Replies: 7
Views: 4457

Re: String parsing

Part of it started working when I completely exited LiveCode and then used the program again later. This has happened once before while debugging another section of code. I guess that sometimes a stack has to be closed and reopened before proceeding with the debugging process. Usually using the appl...
by drhoward
Tue Apr 21, 2015 9:14 am
Forum: Getting Started with LiveCode - Complete Beginners
Topic: String parsing
Replies: 7
Views: 4457

String parsing

In my program I'm reading a text file and then parsing it using itemDelimiter. The parsing seems to work if I read a tab delimited file and "set the itemDelimiter to tab". I can then access word 1, word 2 etc. and any leading spaces are ignored. However, if I use a comma delimited text file, and "se...

Go to advanced search