Re: Movenext and ASP.net
- From: "Mark Rae [MVP]" <mark@xxxxxxxxxxxxxxxxx>
- Date: Wed, 17 Jun 2009 15:39:44 +0100
"Ron H." <fdjks@xxxxxxxx> wrote in message news:EE6_l.11934$he4.5486@xxxxxxxxxxxxxxxxxxxxxxxxx
Ron,
Can anyone show me how to accomplish this task.
The biggest mistake people make when coming to ASP.NET from ASP Classic is to imagine that ASP.NET is somehow the "next version" of ASP Classic. It isn't - not even close. The best advice I can give you is to forget everything you ever knew about ASP Classic - (almost) none of it will be of any use to you at all in ASP.NET...
I would then advise you to get a copy of this: http://www.amazon.co.uk/Beginning-ASP-NET-3-5-2008-Professional/dp/1590598911/ref=sr_1_1?ie=UTF8&s=books&qid=1245249145&sr=8-1 and work your way through it.
Dim RS
Set RS = Server.CreateObject("ADODB.RecordSet")
RS.CursorType = adOpenStatic
RS.Open sqltext, "DSN=services"
RS.MoveFirst
%>
Firstly, ASP.NET uses ADO.NET, not ADO, so none of the above will be of any use to you in ASP.NET... ADO.NET uses DataSets, DataTables and DataReaders, not RecordSets.
<tr>
<td> <% Response.Write oRSp("ServiceName") %> </td>
<td> <% Response.Write oRSp("Price") %> </td>
</tr>
<% oRSp.MoveNext
Secondly, apart from some very specific and quite rare occasions, ASP.NET does not use Response.Write to "write out" HTML. ASP.NET is object-oriented, unlike ASP Classic which is essentially linear. So, to do things like create and populate HTML tables, you use things like the <asp:GridView /> web control. This involves creating the HTML markup for the web control on the aspx page and then wiring it up in your code behind page.
I realise that this isn't what you wanted to hear but, without acquiring the absolute basics of ASP.NET (which the above book will give you and more), then you really will find it almost impossible to get anywhere...
--
Mark Rae
ASP.NET MVP
http://www.markrae.net
.
- References:
- Movenext and ASP.net
- From: Ron H.
- Movenext and ASP.net
- Prev by Date: Re: Is there a way to keep the StreamWriter open?
- Next by Date: Re: Movenext and ASP.net
- Previous by thread: Re: Movenext and ASP.net
- Index(es):
Relevant Pages
|