Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

I am trying to redirect another site on button click.

Answer Posted / richard des jardins

Assign the OnClick property of the Button the the Method
that will handle the OnClick Event" OnClick
= "MyButton_Click" for C#. Alternatively for VB.NET ue the
Handles Keyword on the Method lie this :
Protected Sub MyButton_Click(ByVal Sender As Onbject, ByVal
e S EventArgs) Handles MyButton.Click
C#;
Protected Void MyButton_Click(Object sender, EventArgs e).

Inside the method handle the event:

Response.Redirect("")
Response.Transfer("",false)

This way, you can perform any other tasks you may want to
do such as writing to an event log, or updated a database
record before redirecting the user.

Is This Answer Correct ?    0 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What r the asp.net list controls and difference between them?

969


How can you implement the postback property of an asp.net control?

938


How will you load dynamic assembly? How will create assesblies at run time?

877


Describe session handling in a webfarm?

935


Define static member?

934


What parameters can you pass in the url of the api? Can get and post use the same url?

936


witch is the best insistute in sharpoint course.what abt future of share point course.

3336


How can we access static variable?

1041


What is the difference between cache and cookies?

953


Which method do you use to kill explicitly a users session?

1001


How does output caching work in ASP.NET?

901


How will you load dynamic assembly?

933


What are validator? Name the validation controls in asp.net?

961


How do you create a master page?

981


Explain in what order a destructors is called.

967