I have attached an example project. My problem is that the ASPxButton click keepst postbacking, although I set the AutoPostback to false and on clientclick e.processOnServer = s._autoPostback;
Therefore no data is displayed in my grid. How do I solve this?
Disclaimer: The information provided on DevExpress.com and affiliated web properties (including the DevExpress Support Center) is provided "as is" without warranty of any kind. Developer Express Inc disclaims all warranties, either express or implied, including the warranties of merchantability and fitness for a particular purpose. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.
Confidential Information: Developer Express Inc does not wish to receive, will not act to procure, nor will it solicit, confidential or proprietary materials and information from you through the DevExpress Support Center or its web properties. Any and all materials or information divulged during chats, email communications, online discussions, Support Center tickets, or made available to Developer Express Inc in any manner will be deemed NOT to be confidential by Developer Express Inc. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.
Hello Jeroen,
Thank you for the sample. I've examined it and found no postbacks. If you take a look at the attached screencast, you'll see that there are two callbacks sent to the server: the first callback is sent by the ASPxCallback control, and the second callback is of the ASPxGridView.
By the way, the "s._autoPostback" property isn't described in documentation. I believe that you use a private field. Please replace it to a simple boolean value (true or false).
Thanks,
Vest
What I meant was that the IsPostback is true. In the attached movie it is also true when I push the button. It should be fasle shouldn't it?
Jeroen,
The difference between IsPostBack and IsCallback is described in the "Diff between IspostBack and IsCallback" forum post. However, technically the IsPostBack property is always equal to true when a request is sent to the server. That is why both properties should be checked during the request processing.
Thanks,
Vest
Well the problem I have is I'm collecting Data from a web service, I put the data in a session, because I don't want to call the web service everytime I sort, filter or page the grid. That works fine, but the problem is when I push the button, the session should be cleared, so the web service is being called. Any help on how to achieve this?
I now solved it using the afterperformcallback, which checks if de callback is not a customcallback (which is being called when the user presses the button). If not, the grid is bound again.
Hello Jeroen,
I'm glad that you fixed the issue.
Thanks,
Vest