Question Retrieving data from database in MS Visual Studio 2010

Izzy123

New member
Joined
Sep 29, 2010
Messages
1
Programming Experience
Beginner
Hi, I have an aspx form that is meant to add a new prescription for a doctor system. I've created the database and dataset needed, but the problem is that the doctorID and patientID has to be able to select from the database, not entered in as a plain text. The form look something like this (I did this in DetailsView in MS Visual Studio 2010):



DoctorID: [textbox]

PatientID: [textbox]

prescription details: [textbox]

Insert Cancel



as you can see, only the prescription details needed to be entered in and the doctorID and patientID needed to be selected from the database (in a dropdown list maybe) and it shouldnt allow any text to be entered in. I did the above tables using a DetailsView in Microsoft Visual Studio 2010. However I can't seem to make the doctor and patient ID field be dropdown box which allow me to choose the current doctor and patient in the Doctor and Patient table in the databse. Can anyone tell me how to do it with Design View in Visual Studio? Cause the source view is kinda confusing for me.

Thanks in advance!
 

Latest posts

Back
Top