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...

What is the difference between Server.Transfer and
Response.Redirect? Why would you choose one over the other?

Answer Posted / d

Put it inside <configuration> section

<connectionStrings>
<add key="conString" value="server=01HW154261\SQLEXPRESS;
database=MyDB; user id=; password=;" />
</connectionStrings>

SqlConnection con = new SqlConnection();

con.ConnectionString = ConfigurationManager.AppSettings
["conString"].ToString();

con.Open();

SqlDataAdapter adapter = new SqlDataAdapter("Select a.State
From State as a inner join Country as b on a.CountryID =
b.CountryID where b.CountryID = " + countryID, con);

DataSet dstCountry = new DataSet();

adapter.Fill(dstCountry);

con.Close();

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Define static constructor?

1069


What is the postback property in asp.net?

1034


Where can I get information on cookies in asp.net?

1059


Whats the difference between abstract factory pattern and factory pattern?

1072


How dataadapter.fill works?

1079


Give an example of cookie abuse.

1122


What are different types of authentication techniques that are used in connection strings to connect .net applications with microsoft sql server?

1060


What is globalization and localization in asp net?

1063


What is data caching?

1042


How many types of controls are there in asp.net?

1066


How to use ipostback?

1054


What is fulltrust?

1082


How long do session variables last?

1014


Explain how is a property designated as read-only?

1045


What are custom user controls in asp.net?

1055