Table Field not updating correctly

Got a LiveCode personal license? Are you a beginner, hobbyist or educator that's new to LiveCode? This forum is the place to go for help getting started. Welcome!

Moderators: heatherlaine, Klaus, FourthWorld, kevinmiller

bogs
Posts: 2186
Joined: Sat Feb 25, 2017 10:45 pm

Re: Table Field not updating correctly

Post by bogs » Thu Aug 30, 2018 1:09 pm

Well, using IDEs so far back in the chain as I do, I haven't had to think about it much :oops: but I think -
  • Your solution is clever , and
  • it appears to supply a work around to the issue, and
  • your thinking is valid (it is weird to me also, but I lack enough knowledge to know exactly why, so weird more in a "curiosity" way).
In a side note, just changing the cell editing technique from clicking with a mouse to using the arrow keys to navigate instead seems to not produce the issue (i.e. it works as I'd expect it to). Also weird :wink:
Image

bwmilby
Posts: 204
Joined: Wed Jun 07, 2017 5:37 am
Location: New Orleans, LA
Contact:

Re: Table Field not updating correctly

Post by bwmilby » Thu Aug 30, 2018 1:21 pm

Looking at the code, I can see why arrow keys work. Knowing that should make finding a solution easier. I kind of doubt that it is random, I’m guessing there will be a pattern too.
Brian Milby

Script Tracker https://github.com/bwmilby/lc-misc/tree/master/ScriptTracker

dunbarx
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 5526
Joined: Wed May 06, 2009 2:28 pm
Location: New York, NY

Re: Table Field not updating correctly

Post by dunbarx » Thu Aug 30, 2018 2:24 pm

I kind of doubt that it is random, I’m guessing there will be a pattern too.
I think so too. Something "sticks" in the innards of a table field when a "cell" has had something put into it. The craziness occurs upon exiting the "phantom" field LC creates to simulate text entry in a "cell". The team should be able to isolate the problem readily.

So many parenthetical words in this discussion.

Craig

bogs
Posts: 2186
Joined: Sat Feb 25, 2017 10:45 pm

Re: Table Field not updating correctly

Post by bogs » Thu Aug 30, 2018 2:31 pm

bwmilby wrote:
Thu Aug 30, 2018 1:21 pm
Looking at the code, I can see why arrow keys work.
Please, for those of us in the slower camp, feel free to elaborate :D
Image

bwmilby
Posts: 204
Joined: Wed Jun 07, 2017 5:37 am
Location: New Orleans, LA
Contact:

Re: Table Field not updating correctly

Post by bwmilby » Thu Aug 30, 2018 2:38 pm

There is code (handlers) to go to the next/previous row/cell (one for each direction). When navigating that way, tabs are automatically inserted. My guess is that something is amiss with the calculation of tabs that need to get inserted when clicking on an arbitrary cell. The location is good in one sense because it puts the virtual cell (field) where it needs to go, but then the data does not end up in the correct spot.
Brian Milby

Script Tracker https://github.com/bwmilby/lc-misc/tree/master/ScriptTracker

bogs
Posts: 2186
Joined: Sat Feb 25, 2017 10:45 pm

Re: Table Field not updating correctly

Post by bogs » Thu Aug 30, 2018 3:05 pm

Ahhhhhhh, thank you for the explanation Brian! That makes it a lot clearer (for me anyway).
Image

dunbarx
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 5526
Joined: Wed May 06, 2009 2:28 pm
Location: New York, NY

Re: Table Field not updating correctly

Post by dunbarx » Thu Aug 30, 2018 3:46 pm

Brian is likely on to something.

And maybe that is why it matters if a "cell" has (or has not) been pre-loaded under script control. There are no phantom fields and none of the concomitant messages generated by user action. The tabs are "loaded" via a different methodology (a handler), and somehow those tabs stick, "stabilizing" the table field.

Craig

Post Reply

Return to “Getting Started with LiveCode - Complete Beginners”