Search found 2229 matches

by SparkOut
Wed Aug 05, 2020 7:49 pm
Forum: Getting Started with LiveCode - Complete Beginners
Topic: Grouping. \
Replies: 6
Views: 209

Re: Grouping. \

in the menu bar, you can toggle the "select grouped" option, it looks like that is the case here. You probably don't need to group them again, I expect they are still grouped. Just toggle select grouped and see if behaviour reverts to how you expect.
by SparkOut
Wed Aug 05, 2020 7:42 pm
Forum: Getting Started with LiveCode - Experienced Developers
Topic: [SOLVED] Averaging massive sets of data
Replies: 11
Views: 371

Re: Averaging massive sets of data

Array is (again) the way to go here. (Also you can easily give an array to the average function, without having to make a long list, or keep a sum and count, although Richard has shown a comprehensive way to deal with this set of circumstances).
by SparkOut
Tue Aug 04, 2020 10:22 pm
Forum: Getting Started with LiveCode - Experienced Developers
Topic: [SOLVED] Something is not right with my data
Replies: 45
Views: 1267

Re: Something is not right with Livecode Strings

Er, what's causing this is they way you are putting (or not putting) data into the array. Can we see some source data and how you are taking the records and putting it into the array? When I said "one line", you realise it is one line in a loop to iterate over your source data? At least I presume so...
by SparkOut
Tue Aug 04, 2020 9:04 pm
Forum: Getting Started with LiveCode - Experienced Developers
Topic: [SOLVED] Something is not right with my data
Replies: 45
Views: 1267

Re: Something is not right with Livecode Strings

So how are you retrieving the records? If you do the array population with the single line I showed, then each new value will only create a new key if there was not one with that name already. Unless you have some other decrypted results that are not the same as the other month names, then you can o...
by SparkOut
Tue Aug 04, 2020 7:58 pm
Forum: Getting Started with LiveCode - Experienced Developers
Topic: [SOLVED] Something is not right with my data
Replies: 45
Views: 1267

Re: Something is not right with Livecode Strings

The combine command will work to make it readable, but it won't sort the months into month order. Pick whatever you need from here -- double-check the results with a visual check that there are only 12 valid month name keys in the array put the keys of varMonthCount --or answer the keys of varMonthC...
by SparkOut
Tue Aug 04, 2020 7:22 pm
Forum: Getting Started with LiveCode - Experienced Developers
Topic: [SOLVED] Something is not right with my data
Replies: 45
Views: 1267

Re: Something is not right with Livecode Strings

As Richard says, it looks like we need to see where the assignment of ccMonthDecrypted is made. Personally I wouldn't use an if/then or switch structure for this, it's crying out for an array. One line: add 1 to varMonthCount[(ccMonthDecrypted)] The added advantage of this is that you can see exactl...
by SparkOut
Sun Aug 02, 2020 10:10 pm
Forum: Getting Started with LiveCode - Complete Beginners
Topic: Nested stack properties...
Replies: 24
Views: 748

Re: Nested stack properties...

What "doesn't work"? Chances are if it works in IDE but not as standalone then there are settings in the "inclusions" tab of the standalone builder that are missing. If you let the standalone builder search for inclusions, it it not very reliable, especially with more recent libraries. It may well b...
by SparkOut
Sun Aug 02, 2020 9:06 pm
Forum: Getting Started with LiveCode - Complete Beginners
Topic: Nested stack properties...
Replies: 24
Views: 748

Re: Nested stack properties...

Custom properties are convenient, and less volatile than variables, but when baked into a standalone, the startup condition is fixed. If you want to update a custom property during use of the app, no problem while it is in memory. You can open your app, read the original property value, update it an...
by SparkOut
Sun Aug 02, 2020 8:24 am
Forum: Getting Started with LiveCode - Complete Beginners
Topic: Vertically Centering Cursor in Field *Solved*
Replies: 22
Views: 930

Re: Vertically Centering Cursor in Field

Yes, we all do stuff like that. I didn't mean you were at fault, I just didn't want to steal credit from jacque for her suggestion.
by SparkOut
Sun Aug 02, 2020 4:25 am
Forum: Getting Started with LiveCode - Complete Beginners
Topic: Vertically Centering Cursor in Field *Solved*
Replies: 22
Views: 930

Re: Vertically Centering Cursor in Field

Glad it worked. This is actually an implementation of what jacque suggested in the first reply to your question. :D
by SparkOut
Sat Aug 01, 2020 6:59 pm
Forum: Getting Started with LiveCode - Complete Beginners
Topic: Nested stack properties...
Replies: 24
Views: 748

Re: Nested stack properties...

You can store any type of data in a custom property - even a binary file to "embed" a video file for instance. This is extremely useful, whether you can access the data directly or not. Taking a property and copying to a variable to have a "working copy" is pretty straightforward, although not quite...
by SparkOut
Sat Aug 01, 2020 6:41 pm
Forum: Getting Started with LiveCode - Complete Beginners
Topic: Vertically Centering Cursor in Field *Solved*
Replies: 22
Views: 930

Re: Vertically Centering Cursor in Field

Try this in the field script on textChanged centerCursor end textChanged on selectionChanged centerCursor end selectionChanged on centerCursor put the top of me into tTop put the height of me / 2 into tYoff put tTop + tYoff into tYmid put item 2 of the selectedLoc into tYLoc put tYmid - tYLoc into t...
by SparkOut
Sat Aug 01, 2020 5:34 pm
Forum: Getting Started with LiveCode - Complete Beginners
Topic: Vertically Centering Cursor in Field *Solved*
Replies: 22
Views: 930

Re: Vertically Centering Cursor in Field

What if you set a very large bottom margin on the field so that the last visible line of the text is spaced half-way up the height of the field, and then in the field script (without any other code) on textChanged set the vScroll of me to the formattedHeight of me end textChanged For me, that seems ...
by SparkOut
Fri Jul 31, 2020 11:41 pm
Forum: Getting Started with LiveCode - Complete Beginners
Topic: Nested stack properties...
Replies: 24
Views: 748

Re: Nested stack properties...

Yes, it is a bit odd but it's easy enough to copy to a variable for work and then store again. You get used to it. Similarly you can't do something like set the cCounter of me to the cCounter of me + 1 you have to copy the value out, add 1, then write the new value back. Also to delete a key you hav...
by SparkOut
Fri Jul 31, 2020 11:19 pm
Forum: Getting Started with LiveCode - Complete Beginners
Topic: Nested stack properties...
Replies: 24
Views: 748

Re: Nested stack properties...

As far as I know, you can't directly set a custom property more than one level deep. You can set an element of a custom property to an array so as to have subnodes, but I think you will not be able to address an individual subnode element of a custom property without copying the data out into a vari...

Go to advanced search