Event ValueChanged not raised when edit item |
Post Reply |
Author | |
Peter59
Groupie Joined: 19 July 2007 Status: Offline Points: 61 |
Post Options
Thanks(0)
Posted: 20 February 2009 at 12:55am |
Hello,
I try to give my users the opportunity to edit a large quantity of values - in the attached example the actual stock after an inventory. Every value has to be confirmed wether it is equal to the nominal stock or not to get a feedback, what is booked (value entered) already. My idea was to set the item.value in column "actual stock" to -1, but item.caption to 0 and update the according database record in the ValueChanged event. But ValueChanged is not raised, when the user enters the same "value" (item.caption) as displayed, although item.value is different. Is ValueChanged event in real a "CaptionChanged" event? uploads/20090220_005405_Test_ItemEdit.zip See attached example. |
|
Product: Xtreme SuitePro (ActiveX) version 15.2.1
Platform: Windows 7 64 Bit Language: Visual Basic 6.0 SP6 |
|
Aaron
Senior Member Joined: 29 January 2008 Status: Offline Points: 2192 |
Post Options
Thanks(0)
|
Hi Peter,
If you look into ValueChanged event you will see that Item.Value is indeed the value you entered in ReportItem.
If you would add: MsgBox Item.Value & " - " & Item.Caption (in ValueChanged event) and you will see that Item.Value contains value you entered and if you close msgbox the value will be the same as before. So it looks like the value is lost or doesn't update Caption ???
You could add in ValueChanged event: Item.Caption = Item.Value and now you see the value gets updated.
|
|
Product: Xtreme SuitePro (ActiveX) version 15.0.2
Platform: Windows XP (32bit) - SP 2 Language: Visual Basic 6.0 Zero replies is not an option.... |
|
Peter59
Groupie Joined: 19 July 2007 Status: Offline Points: 61 |
Post Options
Thanks(0)
|
Hi Aaron,
thanks for spending your time with my problem. Yes of course (and I noticed it already), ValueChanged is raised, when I enter a different value than the one displayed! But did you try to enter the same value? In detail:
|
|
Product: Xtreme SuitePro (ActiveX) version 15.2.1
Platform: Windows 7 64 Bit Language: Visual Basic 6.0 SP6 |
|
Aaron
Senior Member Joined: 29 January 2008 Status: Offline Points: 2192 |
Post Options
Thanks(0)
|
Hi Peter,
When you edit item and value is the same, why fire ValueChanged event? It works like it should.
What are you trying to accomplish anyway? Maybe there is another way
|
|
Product: Xtreme SuitePro (ActiveX) version 15.0.2
Platform: Windows XP (32bit) - SP 2 Language: Visual Basic 6.0 Zero replies is not an option.... |
|
Peter59
Groupie Joined: 19 July 2007 Status: Offline Points: 61 |
Post Options
Thanks(0)
|
Hi Aaron,
ok, it was a long week for all of us, we are awaiting the weekend and sometimes things are difficult to understand Did you read carefully my above example? Item.Value is -1, entered string is 0. I expected the ValueChanged event raised. I try to ask my question in another way (in awaiting an answer from support team) When Edit mode is entered, what do I change: the value or the caption of the item? Thanks for dicussing my problem, Peter |
|
Product: Xtreme SuitePro (ActiveX) version 15.2.1
Platform: Windows 7 64 Bit Language: Visual Basic 6.0 SP6 |
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |