How to Insert a TextBox value in to Sql database using
C#.Net coding

Answers were Sorted based on User's Feedback



How to Insert a TextBox value in to Sql database using C#.Net coding..

Answer / jayatirtha joshi

assign the textbox valuu to a string than using sqlcommand
in c# writing insert querry . insert the value into the
database.
ex; sqlcommand cmd=new sqlcommand("insert into emp values
('"+textbox1.text+"'),con");
cmd.executenonquerry();

Is This Answer Correct ?    24 Yes 3 No

How to Insert a TextBox value in to Sql database using C#.Net coding..

Answer / abcd

sqlcommand cmd=new sqlcommand("insert into dept values
('"+txtbox1.text+"'),con");
cmd.executenonquerry();

Is This Answer Correct ?    6 Yes 1 No

Post New Answer

More Dot Net Framework Interview Questions

What is shadowing?

6 Answers   IBM,


What is the use .glimpse in mvc?

1 Answers  


What is serialization ?

7 Answers   IBM, Karrox, MMTS,


Types of assemblies that can be created in dotnet ?

2 Answers   MMTS,


What are differences between entity framework and l2s? : Entity framework

1 Answers  


I can't be bothered with all this CAS stuff. Can I turn it off

1 Answers  


What are the methods in Thread class?

3 Answers  


How .net assemblies are registred as private and shared assembly ?

2 Answers   Infosys, MMTS,


What is RouteConfig.cs in ASP.Net MVC 4?

1 Answers  


How we can handle the exception at controller level in ASP.Net MVC?

1 Answers  


How can you return string result from Action in ASP.Net MVC?

1 Answers  


How the ‘page lifecycle’ of ASP.Net MVC does works?

1 Answers  


Categories