Questions tagged [dopostback]

__doPostBack is a javascript method that allows to trigger a postback from the client.

The __doPostBack is a function which makes a postback to the server with an target element ID, and it should also fire the corresponding Event on server-side automatically.

It is used to fire events on the server side (server-side events are referred to as "actions" in EWF). It takes two arguments:

  • eventTarget - The name of the component (for example "cxWebButton1") that the event is being fired for.

  • eventArgument - The event identifier, for example 'CLICK' for the onClick event.

173 questions
17
votes
5 answers

Is it OK to use __doPostBack()?

Is it OK to use __doPostBack() or it is not recommended because it is generated from ASP.Net and we are not sure if they changed it in a next version of ASP.Net.
Homam
  • 23,263
  • 32
  • 111
  • 187
10
votes
2 answers

Scraping with __doPostBack with link url hidden

I am trying to scrape search results from website that uses a __doPostBack function. The webpage displays 10 results per search query. To see more results, one has to click a button that triggers a __doPostBack javascript. After some research, I…
user3679030
  • 153
  • 1
  • 6
9
votes
4 answers

ASP.NET fails to detect IE10 causing _doPostBack is undefined JavaScript error

ASP.NET fails to detect IE10 causing the following error: _doPostBack is undefined JavaScript error or maintain FF5 scrollbar position. There is a bug in the browser definition files that shipped with .NET 2.0 and .NET 4, namely that they contain…
8
votes
1 answer

Force ASP.NET to generate JavaScript for all User Agents

I noticed recently in my ASP.NET web application that if I set my User Agent to an empty string (using a FireFox plug-in to spoof the user agent), then ASP.NET will not generate the javascript required to perform postbacks. More specifically, if you…
Adam
  • 3,063
  • 5
  • 35
  • 49
7
votes
1 answer

Sharepoint 2013 site NTLM authentication javascript doPostBack doesnt work in Safari&iPad

I have a really interesting problem. We have a site created with sharepoint 2013. We use Windows - NTLM authentication. In a page includes custom discussionListWebPart, we have a filter button which use javascript doPostBack function with webpart…
Habib Adıbelli
  • 1,181
  • 7
  • 14
7
votes
2 answers

IE10 "__doPostBack is undefined" solutions do not work

I have a web server running Windows Server R2 Standard, and am experiencing the issue described in this blog post:…
6
votes
2 answers

how to: get rid of __doPostBack from link buttons?

for example: this code: SignIn shows this as link in status…
b0x0rz
  • 3,953
  • 8
  • 52
  • 82
5
votes
6 answers

jQuery call __doPostBack on LinkButton

I have a LinkButton that I need to perform a click on to cause a postback. The actual link target is: javascript:__doPostBack('ctl00$c1$btnRefreshGrid',''); Clicking the link does perform the postback, as verified by a breakpoint in the code-behind.…
Mark Richman
  • 28,948
  • 25
  • 99
  • 159
4
votes
0 answers

doPost() is not seeing a Parameter

I am sure that a similar question has probably been asked already and I have been working on this for hours to the point where I'm like... this is getting ridiculous. Seeing that I suddenly have plenty of time and I am assuming a lot of you do too,…
4
votes
6 answers

__doPostBack not working for me

Is there an error in the way i use the __doPostBack? function displaymessage() { var scl = "aaaaaa"; var pageId = '<%= Page.ClientID %>'; __doPostBack(pageId, 'OtherInformation'); alert(scl); }
hhh3112
  • 2,167
  • 10
  • 36
  • 55
3
votes
1 answer

Scraping a website for multiple pages that contains _dopostback method and the URL doesn't change for the pages

I am using BeautifulSoup to scrape from the https://excise.wb.gov.in/chms/Public/Page/CHMS_Public_Hospital_Bed_Availability.aspx?Public_District_Code=019 There are a total of two pages of information and to navigate over the pages, there are several…
3
votes
1 answer

AJAX PageMethods conflict with Routing?

EDIT: Latest Info at the bottom of Post. I've got an Update Panel on a page that I force to postback with __doPostBack. Everything works fine when I browse it at /path/page.aspx. However, as soon as I access the page through a route like…
SventoryMang
  • 10,275
  • 15
  • 70
  • 113
3
votes
2 answers

Maintain Control focus across post backs using PostBackOptions.TrackFocus

Maintaining focus across post backs is an apparently difficult task. Searching Google, you will find a ton of people that desire the same thing, but all hook it up differently, and mostly, custom-ly. I would like to avoid a custom implementation,…
Sam Rueby
  • 5,914
  • 6
  • 36
  • 52
3
votes
1 answer

Bots, SEO and ASP.NET __doPostBack links

Does anyone know if, from using linkbuttons and imagebuttons in .net (which render to screen with javascript doPostback methods instead of normal links) you are somehow limiting or adversely affecting your site from an SEO point of view? Put more…
scaryjones
  • 119
  • 8
3
votes
2 answers

__doPostBack() function isn't working (asp.net)

I am trying to trigger button event from the JS code. But doPostBack in JS function reg() is not directing to the c# code. Please tell me what's wrong. Here is my code: