Retroceder   Foros del Web > Programación para sitios web > AJAX

Respuesta
 
Herramientas Desplegado
Antiguo 13-sep-2007, 08:54   #1 (permalink)
maralbust está en el buen camino
 
Avatar de maralbust
 
Fecha de Ingreso: febrero-2004
Ubicación: Santiago
Mensajes: 565
gridview y ajax

hola a todos, tengo el sgte codigo, donde uso, ajatoolkit y vb.net, el llenado de la grilla lo hago desde code behind.

Código:
<asp:UpdatePanel ID="updatePanel" runat="server">
	<Triggers>
		<asp:AsyncPostBackTrigger ControlID="btnConsultar" EventName="Click" />
	</Triggers>
	<ContentTemplate>
	<div id="div_dtgDetalle_Prof" runat="server" visible="false" style="overflow:scroll; width:600px; height:153px;">
		<asp:GridView ID="dtgDetalle_Prof" runat="server" BackColor="Transparent"
		BorderColor="Silver" BorderStyle="Ridge" BorderWidth="3px" CaptionAlign="Left"
		CellPadding="4" EmptyDataText=" " Font-Bold="True" Font-Names="Microsoft Sans Serif"
		Font-Size="X-Small" ForeColor="White" Height="22px" HorizontalAlign="Justify"
		RowHeaderColumn="1" Style="left: 0px; font-family: 'Microsoft Sans Serif'; position: static;
		top: 0px" UseAccessibleHeader="False" Width="894px">
		<FooterStyle BackColor="#99CCCC" BorderColor="White" ForeColor="DarkBlue" />
			<Columns>
				<asp:CommandField HeaderText="Staff" ShowSelectButton="True" />
				<asp:CommandField HeaderText="Seleccion" ShowSelectButton="True" />
				<asp:BoundField DataField="TIPO_PRESTADOR" ReadOnly="True" HeaderText="Tipo Prestador" >
		<ItemStyle CssClass="hiddencol" />
		<HeaderStyle CssClass="hiddencol" />
		</asp:BoundField>
		<asp:BoundField DataField="LA_CORRELATIVO" ReadOnly="True" HeaderText="Correlativo la" >
		<ItemStyle CssClass="hiddencol" />
		<HeaderStyle CssClass="hiddencol" />
		</asp:BoundField>
		<asp:BoundField DataField="CODIGO_INTERNO" ReadOnly="True" HeaderText="Codigo interno" >
		<ItemStyle CssClass="hiddencol" />
		<HeaderStyle CssClass="hiddencol" />
		</asp:BoundField>
		<asp:BoundField DataField="RUT" ReadOnly="True" HeaderText="Rut" />
		<asp:BoundField DataField="DIGRUT" ReadOnly="True" HeaderText="DV" />
		<asp:BoundField DataField="Nombre" ReadOnly="True" HeaderText="Razon Social" />
		<asp:BoundField DataField="LUGAR_ATENCION" ReadOnly="True" HeaderText="Lugar Atención" />
		<asp:BoundField DataField="COMUNA" ReadOnly="True" HeaderText="Comuna" />
		<asp:BoundField DataField="CIUDAD" ReadOnly="True" HeaderText="Ciudad" />
		<asp:BoundField DataField="REGION" ReadOnly="True" HeaderText="Region" />                                    
		</Columns>
		<RowStyle BackColor="White" BorderColor="White" BorderStyle="Outset" BorderWidth="2px"
		Font-Bold="False" Font-Names="Microsoft Sans Serif" Font-Size="XX-Small" ForeColor="#003399"
		Height="17px" HorizontalAlign="Center" VerticalAlign="Middle" />
		<EditRowStyle BorderColor="Black" BorderStyle="Outset" BorderWidth="2px" Font-Names="Microsoft Sans Serif"
		Font-Size="XX-Small" Height="17px" HorizontalAlign="Center" VerticalAlign="Middle" />
		<SelectedRowStyle BackColor="#009999" BorderColor="White" Font-Bold="True" ForeColor="#CCFF99" />
		<PagerStyle BackColor="#99CCCC" ForeColor="#003399" HorizontalAlign="Left" />
		<HeaderStyle BackColor="SteelBlue" BorderColor="SkyBlue" BorderStyle="Inset" BorderWidth="0px"
		Font-Bold="True" Font-Names="Microsoft Sans Serif" Font-Size="XX-Small" ForeColor="Lavender"
		Height="28px" HorizontalAlign="Center" VerticalAlign="Middle" Width="300px" />
		</asp:GridView>
	</div>
	</ContentTemplate>
</asp:UpdatePanel>

<ajaxToolkit:UpdatePanelAnimationExtender ID="upae" BehaviorID="animation" runat="server" TargetControlID="updatePanel">
	<Animations>
		<OnUpdating>
			<Parallel duration="0">
				<%-- place the update progress div over the gridview control --%>
				<ScriptAction Script="onUpdating();" />  
				<%-- disable the search button --%>                       
				<EnableAction AnimationTarget="btnConsultar" Enabled="false" />
				<%-- fade-out the GridView --%>
				<FadeOut minimumOpacity=".5" />
			</Parallel>
		</OnUpdating>
		<OnUpdated>
			<Parallel duration="0">
				<%-- fade back in the GridView --%>
				<FadeIn minimumOpacity=".5" />
				<%-- re-enable the search button --%>  
				<EnableAction AnimationTarget="btnConsultar" Enabled="true" />
				<%--find the update progress div and place it over the gridview control--%>
				<ScriptAction Script="onUpdated();" /> 
			</Parallel> 
		</OnUpdated>
	</Animations>
</ajaxToolkit:UpdatePanelAnimationExtender>
igual es largo, la cosa es que cuando cargo por primera vez la grilla, lo hace perfecto, muestra el gif del loading, pero cuando hago un select desde la grilla o mejor dicho selecciono una fila, se que da pegado cuando deberia pasar a otra grilla, si pongo un breakpoint y traceo termina todos los procesos bien, como podria solucionar esto.

saludos a todos
__________________
..:: NADA SE PIERDE SOLO SE TRANSFORMA ::..
maralbust está desconectado   Responder Citando
Respuesta

No hay votos aún.


Herramientas
Desplegado

Normas de Publicación
No puedes crear nuevos temas
No puedes responder temas
No puedes subir archivos adjuntos
No puedes editar tus mensajes

BB code is Activado
Caritas están Activado
[IMG] está Activado
Código HTML está Desactivado


La Zona horaria es GMT -6. Ahora son las 14:09.


Message Board Statistics

LinkBacks Enabled by vBSEO 3.1.0

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93