I'm new to ASP.NET, as subject, how to use asp.net to connection SQL Server...

How to remote connect "localhost\Instancename", for example connect 192.168.0.2/sqlserver2

share|improve this question
2  
Any of a billion ways. You need to be more specific. – Mystere Man Mar 24 '11 at 19:17
Lightswitch is great for beginners: microsoft.com/visualstudio/en-us/lightswitch – Thomas Li Mar 24 '11 at 19:19
feedback

closed as not a real question by Mystere Man, marc_s, Jeff Atwood Mar 25 '11 at 9:38

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, see the FAQ.

1 Answer

up vote 1 down vote accepted

You don't use ASP.NET to connect to a database directly. ASP is used to call backend function written in other languages like C#/VB.NET etc. which will fetch data and populate controls in the UI. e.g, You click a button. ASP will transform this click to a C# event (assuming that backend is in C#). The C# event handler will fetch data from DB and dump it into an ASP.NET table that you have on the UI (or wherever you want).

I think this will be a good place to start: http://www.asp.net/data-access/tutorials . It has everything you need, both in VB and in C#.

share|improve this answer
Thank, but how to remote connect "localhost\Instancename", for example connect 192.168.0.2 – Ironman Mar 24 '11 at 19:55
feedback

Not the answer you're looking for? Browse other questions tagged or ask your own question.