Ver Mensaje Individual
  #1 (permalink)  
Antiguo 20/06/2011, 23:14
moz90
 
Fecha de Ingreso: mayo-2009
Mensajes: 94
Antigüedad: 14 años, 11 meses
Puntos: 0
Pregunta Crear Reporte Dinamico con Tablas apartir de BD

Hola Amigos del Foro tengo una duda a con respecto a como hacer un reporte y espero me puedan ayudar, basicamente lo que quiero hacer es plasmar un excel que me dieron en un reporte en asp.net.

Comenzare Explicandoles cual es mi dificultad para hacer el proyecto, tengo una tabla de proveedores donde se calculara, subtotales y muchas varias operaciones simples pero en este caso voy a resumir lo que quiero en una tabla simple.

Este seria el codigo;

Código:
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>TABLAS - REPORTE DINAMICOS </title>
    <style type="text/css">
        .style1
        {
            width: 91%;
        }
       
        .style2
        {
            width: 231px;
        }
        .style3
        {
            width: 274px;
        }
       
    </style>
</head>
<body>
    <form id="form1" runat="server">
    <div>
    
        <table class="style1">
            <tr>
                <td colspan="3">
                    PRUEBA - DEMO TABLAS PREDIFINIDAS</td>
            </tr>
            <tr>
                <td class="style2">
                    PROVEEDOR</td>
                <td class="style3">
                    &nbsp;</td>
                <td>
                    &nbsp;</td>
            </tr>
            <tr>
                <td class="style2">
                    DATO 1</td>
                <td class="style3">
                    <asp:Label ID="Label1" runat="server" Text="Label"></asp:Label>
                </td>
                <td>
                    <asp:Label ID="Label2" runat="server" Text="Label"></asp:Label>
                </td>
            </tr>
            <tr>
                <td class="style2">
                    DATO 2</td>
                <td class="style3">
                    <asp:Label ID="Label3" runat="server" Text="Label"></asp:Label>
                </td>
                <td>
                    <asp:Label ID="Label4" runat="server" Text="Label"></asp:Label>
                </td>
            </tr>
            <tr>
                <td class="style2">
                    SUB-TOTAL</td>
                <td class="style3">
                    <asp:Label ID="lblsub1" runat="server"></asp:Label>
                </td>
                <td>
                    <asp:Label ID="lblsub2" runat="server"></asp:Label>
                </td>
            </tr>
            <tr>
                <td class="style2">
                    TOTAL</td>
                <td class="style3">
                    <asp:Label ID="lbltotal1" runat="server"></asp:Label>
                </td>
                <td>
                    <asp:Label ID="lbltotal2" runat="server"></asp:Label>
                </td>
            </tr>
        </table>
        
    
    </div>
    </form>
</body>
</html>
Esta sera una tabla que calculara el total por Meses y en ese mes puede haber varios PROVEEDORES, ENTONCES TENDRIA Q CREAR UNA TABLA POR PROVEEDOR, Y LUEGO EL LBLTOTAL SUMAR LOS SUBTOTALES de cada proveedor, no tengo muy clara la idea de como hacer me han dicho q lo haga con el repeater pero EL PROBLEMA ES que los label no se pueden capturar, si me podrian dar la idea se los agradeceria en grande

gracias