I'm not clear about the property AutoPostBackFlags-ValueChanged of EditorControl in datagrid.
I met a problem . There is a item of birthday and a item of age in datagrid.when the birthday item is modified ,the age item is calucated again in server side .
To do the calucation ,I set AutoPostBackFlags-ValueChanged = on.
The problem is here.when Mouse is clicked out of the grid after the birthday item modified,the modified data is vanished .the original data come back again.
what other setting is nesessary when AutoPostBackFlags-ValueChanged = on?
thank you.
Hi rei tei,
I would like to share with you link from our documentation, where is explained the purpose of this property:
AutoPostBackFlags Property
Obviously, if you set "Off", no postback will be triggered on cell changing. "On" will trigger full postback, "Asynch" - for AJAX.
If you used "On" value of that property, probably the original data of grid will be rendered, because the changes are stored nowhere.
What you can do about it?
Well, first, are you sure that full postback is needed instead of partial postback. I would like to advise you to avoid full postbacks if you can and use "Asynch" if your scenario allows it. This is far more effective (e.g.: 2k transfered instead of 340k).
However, even if you use "On" value for ValueChanged, you should handle data updating, so it will be stored and will be loaded in the future.
I'm using
and handle the update method in my datasource (which in my case is ObjectDataSource). I'm sending you a sample that demonstrate these explanations.
Hope this helps you!
Petko Petkov
thank you for your advise.
I downloaded the AutoCrud.zip,and found there is nothing in the AutoCrud.zip.
where did I do incorrectly?please tell me how to do with it!
Hello,
I'm just following up to see if you need any further assistance with this issue. If so please let me know.
Thank you very much.
I can't resolve it yet .
I want to set the property autopostbackflag of the birthday item with "on".
I don't know the reason of the grid's row updating isn't detected when modify the birthday's data,click the mouse out of th grid .
I'm not clear about the grid .please tell me the reason of the problem.thanks.
It will be easier to resolve your issue if you prepare and send a small sample where the issue will be isolated. Once I receive it I will be able to continue my investigation. Could you please send me such sample?
I'm very sorry for replying so lately to you.
I wonder the post back event of birthday item and the rowupdating event of the grid are colliding when clicked the mouse out of the grid area after modifed the birthday item's data.
It is ok when I clicked the mouse in the grid .
By sample, I meant working project or web site in few files, archived and sent as attachment that need only a setting up from our side.
Do you handle manually the updating in RowUpdating?
I would like to provide you a small article from our documentation, related to editing behavior - Editing Behavior Overview (WebDataGrid)
I think it will be helpful for you!
Please, let me know do you need any further assistance!
>>Do you handle manually the updating in RowUpdating?
No,I just want to know whether the birthday Item's data is modified by using the row updating .
RowUpdating is a event of the WebDataGrid which is triggered before the beginning of the update of data. (More info - RowUpdating Event )
The handler of RowUpdating event receive as parameter the old and the new values used in the update process. When the data is updated in the grid, the event RowUpdated is fired.
If you do not implement specifically any kind of DB preservation in handlers of these events, then the data will be saved in the grid till the next postback, when it will be rebind with the initial data.
I hope this answer to your question! Please, let me know if there is anything else that bothers you!
Do you need any additional assistance?