hi..friends here i penned about the today popular buzz AJAX in web development. i know so many folks dont know the correct usage of ajax,AJAX terms asynchronous javascript and xml, Ajax is universal one,you can use this ajax in php,vb,c# and asp.net and many programming lanuages
Ajax has been used in popular search engine google,In google you can find ,when you are strat to type a message it show some related result in a box,how it happen by using ajax.
everytime it get request from the server without refreshing the whole page, this process can be achived by using update panel.
In an update panel one more function was there ,i.e trigger,many folks dont know the proper function of trigger..By using trigger we can fire a button from an outside the update panel ,thats is no need to kept the button inside the pannel,we can call the button using trigger....see the examble you can easily understand the process of update panel
In this coding you can watch i kept the button outside the update panel, here by using AsyncPostBackTrigge we fire the button
client side coding:
Here you have to add BUtton,Textbox,update panel and script manager.
---------------------------------------------------------------------------
[code]
''<table cellpadding="0" cellspacing="0" align="center" width="500">
''<tr>
''<td>
''<asp:Button ID="buttonclick" runat="server" Text="click1" />
'' <asp:ScriptManager ID="ScriptManager1" runat="server">
''</asp:ScriptManager>
''<asp:UpdatePanel ID="UpdatePanel1" runat="server">
''<ContentTemplate >
''<asp:TextBox ID="txthello" runat="server"></asp:TextBox>
''</ContentTemplate>
'''<Triggers>
''<asp:AsyncPostBackTrigger ControlID ="buttonclick" EventName ="click" />
'' </Triggers>
''</asp:UpdatePanel>
''</td>
''</tr>
''</table>
[/code]
server side coding:
Protected Sub buttonclick_Click1(ByVal sender As Object, ByVal e As System.EventArgs) Handles buttonclick.Click
txthello.Text = "using trigger"
End Sub
i hope this blog will helpful to know about AJAX usage....
plz post your valoable commnets here...
0 comments:
Post a Comment