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

how save recoreed in the database

Answer Posted / venky

string cns=@"server=.\SQLEXPRESS;Database=emp;Integrated Security=SSPI";

cn=new SqlConnection(cns);

string sql = "select * from mytable";
DataSet ds = new DataSet();
SqlDataAdapter adpt=new SqlDataAdapter(sql,cn);

adpt.Fill(ds,"emp1");

.....after altering table....

sqlcommandbuilder cbdr=new sqlcommandbuilder(adpt);

adpt.Update(ds,"emp1");

your changes automaically save into databases...

Is This Answer Correct ?    1 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is form and its types?

989


How is anchoring different from docking?

1174


What is the synonym of form?

891


How many types of dialog boxes windows provides?

1066


What are windows based applications?

933


which property is used to change to some value to access a identity column in datacontrols?

2100


What are controls in windows forms?

994


Explain about crystal report in brief?

945


Name the template that is used to create a user-defined component.

917


What is form and meaning?

914


Which window allows viewing the resources of the servers, such as services, processes and the event log?

988


What is window form application?

938


Is typeform free?

929


Explain the difference between listbox and combo box?

958


Which method of the messagebox class is used to display a message in the message box?

979