
14/10/2003, 17:09
|
| | Fecha de Ingreso: septiembre-2003
Mensajes: 96
Antigüedad: 21 años, 5 meses Puntos: 0 | |
Ok, gracias...
Mira, en mi archivo pru1.aspx.vb tengo el siguiente codigo:
Public Class WebForm1
Inherits System.Web.UI.Page
Protected WithEvents Label1 As System.Web.UI.WebControls.Label
Dim str As String = "select * from Curriculum"
Dim oConn As New System.Data.OleDb.OleDbConnection("Provider=Micros oft.Jet.OLEDB.4.0;Data source=c:\Inetpub\wwwroot\base\Prueba.mdb;")
Dim dAdap As New System.Data.OleDb.OleDbDataAdapter(Str, oConn)
Protected WithEvents DataList1 As System.Web.UI.WebControls.DataList
Dim ds As New DataSet()
#Region " Web Form Designer Generated Code "
'This call is required by the Web Form Designer.
<System.Diagnostics.DebuggerStepThrough()> Private Sub InitializeComponent()
End Sub
Private Sub Page_Init(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Init
'CODEGEN: This method call is required by the Web Form Designer
'Do not modify it using the code editor.
InitializeComponent()
End Sub
#End Region
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
'Put user code to initialize the page here
dAdap.Fill(ds)
DataList1.DataSource = ds
DataList1.DataBind()
End Sub
End Class
y en el html tengo:
<%@ Page Language="vb" AutoEventWireup="false" Codebehind="pru1.aspx.vb" Inherits="WebApp.WebForm1"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
<HEAD>
<title>WebForm1</title>
<meta content="Microsoft Visual Studio.NET 7.0" name="GENERATOR">
<meta content="Visual Basic 7.0" name="CODE_LANGUAGE">
<meta content="JavaScript" name="vs_defaultClientScript">
<meta content="http://schemas.microsoft.com/intellisense/ie5" name="vs_targetSchema">
</HEAD>
<body MS_POSITIONING="GridLayout">
<form id="Form1" method="post" runat="server">
<asp:label id="Label1" style="Z-INDEX: 101; LEFT: 341px; POSITION: absolute; TOP: 23px" runat="server" ForeColor="Navy" Font-Size="Larger" Font-Names="Arial Black" Width="101px" Height="14px">CURRICULUM</asp:label>
<asp:DataList id="DataList1" style="Z-INDEX: 102; LEFT: 278px; POSITION: absolute; TOP: 121px" runat="server"></asp:DataList></form>
<asp:DataList id="DataList1"
runat="server"></asp:DataList><BR><ItemTemplate></ItemTemplate><BR><%#
Container.DataItem("nombre_campo")
%><BR></ItemTemplate><BR></asp:DataList>
</body>
</HTML>
Gracias por tu valiosisisisima ayuda! |