Manual postback

  • Thread starter Thread starter James
  • Start date Start date
J

James

Hello:

I have seen several postings on this, but forgive me - I am having
difficulty understanding them.

I am trying to figure out how to manually cause a postback to happen
without a user having to click another button. I've seen a postings on
something called a __DoPostBack, but I don't know how to implement
this. Can anyone help me here?


James
 
Hi,

If one of the fields on the form set to be autopostback the __dopostback
function and __EVENTTARGET, __EVENTARGUMENT fields embedded into the
html code. to manually set postback you need to add those two fields to
the form and the __DoPostBack function. Without the __EVENTTARGET and
__EVENTARGUMENT fields the asp.net page wont know which control call
for the postback and for part of the controls which event to raise.

Natty Gur, CTO
Dao2Com Ltd.
28th Baruch Hirsch st. Bnei-Brak
Israel , 51114

Phone Numbers:
Office: +972-(0)3-5786668
Fax: +972-(0)3-5703475
Mobile: +972-(0)58-888377

Know the overall picture
 
Hello James,

The __doPostBack function is generated by ASP.NET as a helper function to
submit the form. It allows you to specify the target and argument of the
event which are passed in hidden-fields and then submits the form. It is
used by the provided controls (ie. LinkButton) and may be used by your
custom server controls also, to initiate a postback.

For details, please refer to MSDN topic:
"Generating Client-Side Script for Postback"
http://msdn.microsoft.com/library/en-us/cpguide/html/cpcongeneratingclient-s
idejavascriptforpostback.asp?frame=true

Hope it helps.

Best regards,
yhhuang
VS.NET, Visual C++
Microsoft

This posting is provided "AS IS" with no warranties, and confers no rights.
Got .Net? http://www.gotdotnet.com
--------------------
!From: (e-mail address removed) (James)
!Newsgroups: microsoft.public.dotnet.framework.aspnet
!Subject: Manual postback
!Date: 30 Jun 2003 15:55:43 -0700
!Organization: http://groups.google.com/
!Lines: 12
!Message-ID: <[email protected]>
!NNTP-Posting-Host: 192.44.136.113
!Content-Type: text/plain; charset=ISO-8859-1
!Content-Transfer-Encoding: 8bit
!X-Trace: posting.google.com 1057013743 18834 127.0.0.1 (30 Jun 2003
22:55:43 GMT)
!X-Complaints-To: (e-mail address removed)
!NNTP-Posting-Date: 30 Jun 2003 22:55:43 GMT
!Path:
cpmsftngxa09.phx.gbl!TK2MSFTNGP08.phx.gbl!newsfeed00.sul.t-online.de!t-onlin
e.de!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!sn-xit-03!sn-xit-06!sn-
xit-09!supernews.com!postnews1.google.com!not-for-mail
!Xref: cpmsftngxa09.phx.gbl microsoft.public.dotnet.framework.aspnet:31239
!X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
!
!Hello:
!
!I have seen several postings on this, but forgive me - I am having
!difficulty understanding them.
!
!I am trying to figure out how to manually cause a postback to happen
!without a user having to click another button. I've seen a postings on
!something called a __DoPostBack, but I don't know how to implement
!this. Can anyone help me here?
!
!
!James
!
 
Back
Top