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 do you understand from custom control?

1069


What is http post action?

974


When we use cookie less session? Explain its working?

983


How can you handle errors in Web API?

1066


How can we identify that the Page is Post Back?

950


Why should i prefer JSP over asp.net or any other web development language..??

1949


Explain what are the advantages of asp.net mvc framework? : asp.net mvc

1055


What is asp.net and how it works?

962


What is the use of ASP.NET routing?

1016


How many types of server controls do we have?Also explain differance between them taking an example of ASP.NET?

2883


What describes a query?

878


Can the validation occurs in server-side or client-side? If the validation occurs why should we do?

1007


What methods are fired during the page load? Init()

925


Explain about consistent programming model in the .NET framework?

1038


Explain the main function of url routing system in asp.net mvc? : asp.net mvc

963