irienaoki0407
irienaoki0407

Reputation: 1

database for vb.net and asp.net

is it possible to use same database for both vb.net appplication and asp.net?? and if is possible, how can to connect it??? now..i'd build vb.net application and asp.net in my laptop... it can connect..but i wonder how to make the database connect for vb.net and asp.net in real... thank you in adnvance

Upvotes: 0

Views: 450

Answers (2)

StingyJack
StingyJack

Reputation: 19469

Short answer... Yes.

Databases are meant to be shared by many different applications as well as many different types of applications.

For VB.net and ASP.NET (in the code behind), you can use the same code to access the database...

Using _conn as New SqlConnection(connectionString)
  'Do Stuff'
End Using

For databases to use for free, you can get MS SQL Express edition, Oracle XE, MySql, and a few others.

Upvotes: 1

Walter
Walter

Reputation: 2560

If you write your data access layer (DAL) as a web service (or WCF application) then both your ASP.NET site and Winforms app can call the DAL and have access to the same data in the same database.

Upvotes: 0

Related Questions