Ver Mensaje Individual
  #10 (permalink)  
Antiguo 15/10/2003, 11:28
marco_foros
 
Fecha de Ingreso: septiembre-2003
Mensajes: 96
Antigüedad: 20 años, 8 meses
Puntos: 0
Hola...

Mira, hice este pequeño programa con puro html (sin utilizar VS.NET). Según yo, está bien, pero cuando lo ejecuto, me devuelve un error(http://www.compite.org.mx/AspEjm/prubase.aspx). Esto me hace suponer que se pueda deber a un problema en mi servidor, pero no sé qué!

<%@ Import Namespace="System.Data" %>
<%@ Import Namespace="System.Data.OleDb" %>
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<script language="VB" runat="server">
Sub Page_Load(sender As Object, e As EventArgs)
Dim DS As DataSet
Dim MyConnection As OleDbConnection
Dim MyCommand As OleDbDataAdapter

MyConnection = New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0; Data source=c:\Inetpub\wwwroot\base\Prueba.mdb;")
MyCommand = New OleDbAdapter("select * from Curriculum", MyConnection)

DS = New DataSet()
MyCommand.Fill (DS,"Curriculum")

MyRepeater.DataSource = DS.Tables("Curriculum").DefaultView
End Sub
</script>
</head>
<body>
<asp:repeater id="MyRepeater" runat="server">
<headertemplate>
<table width="100%" style="font: 8pt verdana">
<tr style="background-color:DFA894">
<th>ID</th>
<th>Nombre</th>
<th>Puesto</th>
</tr>
</headertemplate>
<itemtemplate>
<tr style="background-color:FFECD8">
<td><%#DataBinder.Eval(Container.DataItem, "id") %> </td>
<td><%#DataBinder.Eval(Container.DataItem, "nombre") %> </td>
<td><%#DataBinder.Eval(Container.DataItem, "puesto") %> </td>
</tr>
</itemtemplate>
<footertemplate>
</table>
</footertemplate>
</asp:repeater>
</body>
</html>

SaludoS!