Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to trap a change in a ListBox after a MESSAGEBOX()
Message
From
12/03/2016 12:37:13
Dragan Nedeljkovich (Online)
Now officially retired
Zrenjanin, Serbia
 
 
To
12/03/2016 11:52:48
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows 10
Miscellaneous
Thread ID:
01632877
Message ID:
01632924
Views:
47
>User clicks on a list. The item on which he clicked is highlighted. A message box appears. User responds to the message box. The message box disappears. The value of the list and the highlighted item are not in sync.
>
>If you think this is regular UI or if you're ok with events triggered by an user explicit action being "eaten away" after they occur, like they never happened, then good for you.
>
>It's not good for me.

Perhaps you could track, in the debugger, the moment when the highlighted item in the listbox changes, and the value of its .listindex, .value and perhaps the .selected[.listindex] and if .displayvalue has any meaning in a listbox, that too. Watch them as they were before the messagebox(), then step by step afterwards. Perhaps you'll catch something. Though, as in all things focus-related, the debugger has the focus and the rest of the focus behavior is more or less simulated.

A thing I'd try: after messagebox(), listbox.setfocus() (unless all of this is happening in a .valid(), then you can't do this).

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform