[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 386
  • Last Modified:

Visual studio .net Recordset

How can I create a recordset into asp.net project
0
chouproute
Asked:
chouproute
  • 3
  • 3
1 Solution
 
brdrokCommented:
what do you mean by creating a recordset into a asp.net project?

Do you mean creating a DataSet inside an asp.net project?  
0
 
ovalsquareCommented:
A record set is used in asp classic/vb etc. It has since been replaced by datatables, datasets (in memory results sets that can actually be a collection of more than one table, with relationships etc. - dumbed down explanation) and the datareader (not in memory, forward only). Benefits and drawbacks to all, but considerable improvement over the old way.

Ted
0
 
chouprouteAuthor Commented:
Can you explain how to work with Dataset,
just an example of code to help me to start.
0
Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

 
brdrokCommented:
ok...try this:

//set your sql statement
string sql = "SELECT * FROM Customers";

//setting up your connection object assuming it's njot a trusted connection
SqlConnection m_cn = new SqlConnection(@"Server=xxx.xx.x.xxx;Database=myDatabaseName;User  ID=userName;Password=yourPassword;Trusted_Connection=False");

//setting up your dataAdapter
SqlDataAdapter daCustomers = new SqlDataAdapter(sql, m_cn);

//create your dataset here
DataSet dsCustomer = new DataSet();

//fill your dataSet with customers rec ords.
daCustomers.Fill(dsCustomer, "Customers");

check out this link below.  i found it to be really useful to get the in and out of ado.net in general

http://samples.gotdotnet.com/quickstart/howto/doc/adoplus/ADOPlusOverview.aspx
0
 
chouprouteAuthor Commented:
HOw thanks a lot,
Is there any way with VB.NET to create a "browsable" datagrid(when we put the mouse over a line in the datagrid, she became on other color, and when we click on it,  a new page appear)

thanks

Marco
0
 
brdrokCommented:
check this link out.

http://aspnet.4guysfromrolla.com/articles/072104-1.aspx

there was one other site that had a dll file that one only needs to import it via "Add/Remove Items" and voila.  It's free too but can't seem to find it.  Gimme your e-mail and i'll sent it to you.

hope i'm not breaking any laws... =)


0
 
chouprouteAuthor Commented:
I already read the first link it dooesn't seem to work.....


my mail is tech.microage@globetrotter.net

Thanks again
0

Featured Post

What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

  • 3
  • 3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now