Newbie Question: saving form data to sql

G

Guest

Hey folks I'm reletivly new to ASP.Net and Visual studio. I have VS2005
Standard edition and I'm currently working on my own web site with it.

What I want to do and I can actually see myself doing this in a lot of
different scenerios. is create a form where the user can enter information
and when they submit the form they save the data to the sql database as a new
record. I know theres Form view that seems similar to what I want to do but I
find that it pulls existing records (which I don't want) I want the form to
save a new record(insert).

if i have to hand write this to wire up the textbox, checkboxes etc controls
that make up the form fields using the existing datasource that I created
using the sqldatasource control can anyone explain or point me to a good link
that would explain how to do this?
 
G

Guest

If you just want an insert form, you can set the Default Mode property to
insert for a FormView. If you prefer to do it programmatically you can use
the ChangeMode method of the Form View to put it in insert mode when you
choose.

There is also a details view that will allow you to put buttons that, in
addition to the options above for FormView, will allow you to add edit,
delete, or insert record buttons into a form with no code.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,770
Messages
2,569,583
Members
45,075
Latest member
MakersCBDBloodSupport

Latest Threads

Top