How to create and connect a Database(SQL).

Undefined Equation

New member
Joined
Feb 19, 2012
Messages
1
Programming Experience
Beginner
Hello, I have a project that has SQL as backend.

I want to run this project in my computer. I think I need two things to run it, create a database and connect it to the project. Can anyone tell me how to do it?
I made a Database, but I am not sure if it works.

Name of Datasource:
PHP:
Data Source=PRAKASH-PC\SQLEXPRESS;Initial Catalog=MedicalStore;Integrated Security=True
The name of program is MedicalStore. It was originally in Vb.net 2008 but I converted it into VS.net 2010. I tried running it on both but it doesnt works. When I run it, I get the error
PHP:
SqlException was unhandled
at dr = cmd.ExecuteReader

Can anyone give me exact steps of creating and connecting the database and if anything else is required to do. Also if it depends on .NET Framework and SQL version 2005 or 2008, how to figure it out from project that which version it requires. Also if the database name and server name has to specified according to the project, how to find what name it should be.(I mean which might be the type of form in it the name are specified, there are around 30 forms in this project)

Thanks for the help and please its urgent. :D
 
Try
    dr = cmd.ExecuteReader
Catch excSQL As SQLException
    MsgBox "Error " & excSQL.Number & ": " excSQL.Message
End Try
 
Back
Top