tags:

views:

756

answers:

1

I have a server control ( linkbutton ) on the aspx page.

For some complicated reason - I need to set the postbackurl from client side for this button.

Is there a way to set the postback url from client side ?

I got some reference to javascript:WebForm_DoPostBackWithOptions method- but not sure how best to use it.

A: 

You can change the form's target using window.document.forms[0].target='otherpage.aspx'.
You'd also probably need to cancel event validation on the page posted to.

Kobi