AJAX :: "Invalid Argument." Error When Programmatically Changing Tabs
Feb 26, 2010
I have a TabContainer that has a button in one of the tabs. When i click on the button, I need to save a few items to the database and then select a different tab.
In both instances, I receive a scripting error message "Invalid argument." from the file "ScriptResource.axd".
After continuing or ignoring these errors (ussually three of them), the page finishes refreshing and the correct tab is selected. I'm just not sure how to get rid of these error messages or why I get them.
I am using a tabcontrol from AJAX. I have 5 TabPanels in this TabControl.
In the 4:th TabPanel(ActiveTabIndex="3"). I am using some AsyncFileUpload controls inside an updatepanel.
If I now sets the ActiveTabIndex="3" and F5(Start Debugging) the website in the browser, I can see this TabPanel and everything starts out fine.
If I now tries to press any of the other 4 tabpanels or sets the ActiveTabIndex to 0,1,2,4 or 5 before F5(Start Debugging), the debugging breaks and highligths this text in a code file and says "Invalid argument" in an Error MessageBox.
Getting an error whenever we click a particular button/link on our site. It is generating a javascript "Invalid Argument" error. I know in the other posts it is typically because it is a syntax error in the javascript however it only just seems to have started happening and it doesn't happen on all pcs.
ie. in our client's environment if I remote onto their web server and view the uat website I get the javascript error. If I remote onto their sql server and view the uat website I don't get the javascript error. If it was a syntax error then I would always get the error wouldn't I?
both browsers are the same version of IE6 (yeah I know...) :) I have tried deleting temporary internet files - including viewing the files and deleting them myself - but no joy.
client uses citrix.. and they're all getting the error :(
Update - I haven't posted specific code as there is too much to post (and I'm not sure where the error is occurring). The "button" launches a new window which in turn opens up a couple of aspx pages and calls lots of javascript. So the window opens ok, and there's a function that gets called to resize the window - but before it calls the resizing of the window/content it throws the invalid argument error. Am busy trying to get alerts to trigger to see if I can see where it's falling over but so far no luck.
Again not sure why this error doesn't occur when I use a particular PC (same browser version)
When i tried to edit a record present in a gridview I am getting the following error "Invalid postback or callback argument.Event validation is enabled using <pages Enable event validation="true"/> in configuration or <% @ page EnableEventValidation="true" %> in a page.For security purposes,this feature verifies that arguments to postback or callback events originate from server control that originally render them.If data is valid and expected,use the ClientScriptManager.RegisterForEventValidation method in order to register the postback or callback data for validation."
I am making a call to a WCF service(Existing) from another WCF Service(New, my service), which is configured as Anonymous access. I did a service reference of my service to web application both under same solution file and web app is configured as Windows Authentication. When I call the existing WCF Service from my web app directly, everything works fine, but when I call the same existing WCF Service from my service, I got a "user does not have valid credentials" error. To avoid this error, I published my service to a server and referenced that URL to my web app. Though I got past the error, now, I am getting "Invalid Argument" error. No further information on the error.
Error source is MSCORLIB. There is no problem in the code of my service and the existing service, because if the same value that I get from the existing service is hard coded, then everything works fine. The existing service is used by many other app and it works fine. So, its a tested service. I tried to find a solution of "invalid argument" and I found few threads where others are facing the same problem when they publish a WCF service, but I did not find any proper solution for this.
I am getting this wired error when I try to add another control on my user control. Is there a limitaion on how many controls we can have on a single user control?
I have a user control in the sidebar(in my web site) for display title and picture of any of news. his usercontrol in all of the pages is observable. when user click on the picture navigate to the page News.aspx for more details. first time i can but in second time when i click on another picture in the News.aspx i get an error like below:
Invalid postback or callback argument. Event validation is enabled using <pages enableEventValidation="true"/> in configuration or <%@ Page EnableEventValidation="true" %> in a page. For security purposes, this feature verifies that arguments to postback or callback events originate from the server control that originally rendered them. If the data is valid and expected, use the ClientScriptManager.RegisterForEventValidation method in order to register the postback or callback data for validation. but when i reload the page the problem is solved my code is:
Recently, I added a button, a textbox and a jquery code. On click of button the textbox value was been captured in the dropdown. All my code is working fine. But, when I fill the other data and submit the form, It gives me the below error.
Invalid postback or callback argument. Event validation is enabled using <pages enableEventValidation="true"/> in configuration or <%@ Page EnableEventValidation="true" %> in a page. For security purposes, this feature verifies that arguments to postback or callback events originate from the server control that originally rendered them. If the data is valid and expected, use the ClientScriptManager.RegisterForEventValidation method in order to register the postback or callback data for validation.
I googled for quite a while but nothing I found helped me. The answers suggested where all about fancy JavaScript or custom configurations. I just havea normal web form with a master page that has a modalpopup. -added the ajaxtoolkit but IE shows me:Error: Invalid Argument.URI: http://localhost:1208/ScriptResource.axd?d=pKdY9U1I1OjDYFCUSzzytcNPhPGr2JZpgs7XKvpYLd1NLv90pLAd1EGivV7JpLltn-d4ijVikxETLevfjx3TDw2&t=ffffffffd2a9b7c7
Typically I get this error when I am using AJAX, but I'm not using any AJAX at all in this page. Yet I'm getting this error. Invalid postback or callback argument Here is my code.
I'm having this wierd issue I hope you could help me with.I have two drop down lists in my page, and an accordion.When a value is chosen for the first DDl it loads specific values from my database into the second ddl.I've put the second one inside an Update panel, and added the first DDL as AsyncTrigger, so whenever someone chooses a value from the first DDL it loads the second one without refreshing the page.After a value has been chosen for the second DDl the accordion should be populated with data.I've ran some tests and noticed that choosing a value from the second DDL won't populate the accordion, so I've added another PostBack trigger to the second DDL- the ddl itself.Sometimes it works fine- I choose a value from ddl2 and the accordion shows fine, but sometimes I get this error message:Invalid postback or callback argument. Event validation is enabled using <pages enableEventValidation="true"/> in configuration or <%@ Page EnableEventValidation="true" %> in a page. For security purposes, this feature verifies that arguments to postback or callback events originate from the server control that originally rendered them. If the data is valid and expected, use the ClientScriptManager.RegisterForEventValidation method in order to register the postback or callback data for validation."Before putting the second ddl inside the update panel everything worked well so I'm a bit baffled here.
Using ASP.NET VB, I have a form with some text boxes and a Gridview. If a user clicks the Edit button on a row in the gridview, and then tries to submit the form with a row still in edit mode on the Gridview, this error is generated -
"Invalid postback or callback argument. Event validation is enabled using in configuration or <%@ Page EnableEventValidation="true" %> in a page. For security purposes, this feature verifies that arguments to postback or callback events originate from the server control that originally rendered them. If the data is valid and expected, use the ClientScriptManager.RegisterForEventValidation method in order to register the postback or callback data for validation. "
I am getting the following error on on clikcing checkbox from checkbox list in my project.
Error:
Invalid postback or callback argument. Event validation is enabled using <pages enableEventValidation="true"/> in configuration or <%@ Page EnableEventValidation="true" %> in a page. For security purposes, this feature verifies that arguments to postback or callback events originate from the server control that originally rendered them. If the data is valid and expected, use the ClientScriptManager.RegisterForEventValidation method in order to register the postback or callback data for validation.
If i set <pages enableEventValidation="false"/> then on clicking the submit button the information is not saved in database just page is refreshed.
aspx.cs file code:
protected void btnSubmit_Click(object sender, EventArgs e) { if (con.State == ConnectionState.Closed) { con.Open(); } SqlCommand cmd = new SqlCommand(@"insert into MainTable values(@CollegeName,@AffilatedWith,@CollegeType,@Country,@City,@State,@EstablishmentYear,
but when I click on image button below error happen:Invalid postback or callback argument. Event validation is enabled using <pages enable EventValidation="true"/> in configuration or <%@ Page EnableEventValidation="true" %> in a page. For security purposes, this feature verifies that arguments to postback or callback events originate from the server control that originally rendered them. If the data is valid and expected, use the ClientScriptManager.RegisterForEventValidation method in order to register the postback or callback data for validation.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.ArgumentException: Invalid postback or callback argument. Event validation is enabled using <pages enableEventValidation="true"/> in configuration or <%@ Page EnableEventValidation="true" %> in a page. For security purposes, this feature verifies that arguments to postback or callback events originate from the server control that originally rendered them. If the data is valid and expected, use the ClientScriptManager.RegisterForEventValidation method in order to register the postback or callback data for validation.
But I have another problem, my gridview is inside UpdatePanel and when I click on prev or next button I get exception: "Sys.WebForms.PageRequestManagerServerErrorException: Invalid postback or callback argument. Event validation is enabled using <pages enableEventValidation="true"/> in configuration or <%@ Page EnableEventValidation="true" %> in a page. For security purposes, this feature verifies that arguments to postback or callback events originate from the server control that originally rendered them. If the data is valid and expected, use the ClientScriptManager.RegisterForEventValidation method in order to register the postback or callback data for validation."
Do you know what should I do to make it work?I don't think that I should change enableEventValidation to "false" maybe I should use ClientScriptManager.RegisterForEventValidation? But I don't know how to use it.
i use cascading dropdown lists (in a user registration form) and when the user hits the submit button i get the error: "Invalid postback or callback argument" I've seen on the net that this is a problem dating back many years but still haven't found a solution to this. I've read about changing EnableEventValidation to false, but this poses a security risk.
I m using the Ajax Tab Container, I want to apply the change of tabs by the press of TAB Key and also changing of tabs by press of 1,2,3,4 keys to respective tabs. Provide the code for the same.
i have had this problem before but haven't found a solution yet. The solutions that i have come across are either bad for security or worked on old versions of the .Net framework. I am using VB.net with framework 3.5 and i get the following error when clicking on a button that is a trigger for an updatepanel:
Invalid postback or callback argument. Event validation is enabled using <pages enableEventValidation="true"/> in configuration or <%@ Page EnableEventValidation="true" %> in a page. For security purposes, this feature verifies that arguments to postback or callback events originate from the server control that originally rendered them. If the data is valid and expected, use the ClientScriptManager.RegisterForEventValidation method in order to register the postback or callback data for validation.
The msg states that you need to use the ClientScriptManager.RegisterForEventValidation but i can't find anywhere which shows a working example of this in VB.net & in .net framework 3.5. Can anyone give me a step by step guide on how to resolve this postback validation error?
When user cliick on the control before page fully loaded it goes to error page.
Following is the trace.
Execution Error
Invalid postback or callback argument. Event validation is enabled using <pages enableEventValidation="true"/> in configuration or <%@ Page EnableEventValidation="true" %> in a page. For security purposes, this feature verifies that arguments to postback or callback events originate from the server control that originally rendered them. If the data is valid and expected, use the ClientScriptManager.RegisterForEventValidation method in order to register the postback or callback data for validation.
I have a web page that contains a number of update panels containing collapsed panels, some of which have data loaded on expand.To achieve this I have added a java script function:
function pageLoad() { $find('cpe1').add_expandComplete(postBack1); $find('cpe2').add_expandComplete(postBack2); [code]....
With the PostBack1 - 4 functions clicking hidden buttons that are triggers for the update panels (and inside the panels) that then run the loads. In some of these it binds a grid to an object datasource in others it just fils in some screen elements from a database table.
What I am finding is that the ones which load screen elements work perfectly. The FIRST one of the two grid binding ones also works perfectly, and it doesn't matter which I open first (both up1 and up2 will work if they are first and correctly bind the grid). However if I open either of the grid binding panels then attempt to open any other panel I receive:
"Sys.WebForms.PageRequestManagerServerErrorException: Invalid postback or callback argument. Event validation is enabled using <pages enableEventValidation="true"/> in configuration or <%@ Page EnableEventValidation="true" %> in a page. For security purposes, this feature verifies that arguments to postback or callback events originate from the server control that originally rendered them. If the data is valid and expected, use the ClientScriptManager.RegisterForEventValidation method in order to register the postback or callback data for validation."
However this only occurs if I hit either up1 or up2, I can open and close up3 and up4 as often as I like with no error as long as I do not open up1 or up2.Turning off Page event validation does solve the problem, but I am concerned about page vulnerability.
I have a Cascading drop down list that is working fine to load the correct lists however I would like to have the last one initiate a query and display a datagrid on the same page containing the results of the query. Without Ajax involved this seems rather easy by using autopostback on the drop downs. If I could do it through Ajax that would be great but I can settle with having the page to reload to display the data. Right now I'm not sure how to do either. I enabled autopostback on the last drop down and wrote a method for it but I get an error at runtime saying:
I am using Jqgrid3.6 integrated with .net application and its working fine for all the features except the row delete . i.e. When i have multiselect option and if i delete all the rows at that time i get the error message as "URL Not Set" or "Invalid Argument". Can any body tell me what can be the issue and how to resolve the same