In the WinForm is very easy to achieve, press ENTER to perform related functions, textchanged events, and to obtain physical path, in the asp.net to achieve a bit of trouble, such articles more, but the code is more chaotic, special will I use this part of the code posted.
Allow the textbox to detect KeyPress, implement input and then enter.
In addition, to implement text changed to empty another textbox content, found that focus left the first textbox to clear the second textbox, so instead of the first textbox to get focus, empty the second textbox, All of this code is posted as follows (and code that gets the physical path): <textarea cols= "rows=" name= "code" class= "C-sharp" >public partial class Viewfourconer:portalmodulebase, iactionable {string m_applicationpath = ""; String mbtxtpath = ""; protected void Page_Load (object sender, EventArgs e) {try {m_applicationpath = Request.applicationpath; if (this.m_appli Cationpath = = "") This.m_applicationpath = "/"; if (!this.m_applicationpath.endswith ("/")) This.m_applicationpath + = "/"; First Judge/Mbtxtpath = Server.MapPath (M_applicationpath + "DESKTOPMODULES/FOURCONER/MB"); Input. Attributes.Add ("OnKeyPress", "Entertextbox ('" + Button1.clientid + ")"); Input. Attributes.Add ("onfocus", "cleartextbox" + output. ClientID + "')"); if (! IsPostBack) {}} catch (Exception ex) {exceptions.processmoduleloadexception (this, ex);}} Other unrelated method is not posted.}</textarea>
<mce:script language= "javascript" ><!--function Entertextbox (button) {if (Event.keycode = =) {Event.keycode = 9; Event.returnvalue = false; Document.all[button].click (); } function Cleartextbox (textbox) {document.all[textbox].value= "";}//--></mce:script>
These articles are good to talk about new things like using workflows in asp.net.
Http://www.codeproject.com/KB/aspnet/LINQCustomProfileProvider.aspx
Http://www.codeproject.com/KB/ajax/MakingGoogleIG.aspx
Http://www.codeproject.com/KB/ajax/Web20Portal.aspx
Note that the JS code.
Please put "Mce:script"
Replace with "script"
There is a problem with the CSDN code feature