.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Register
 
Win Surprise Gifts!!!
Congratulations!!!


Top 5 Contributors of the Month
Easy Web
Imran Ghani
Post New Web Links

Client Name apposed to ID

Posted By:      Posted Date: September 28, 2010    Points: 0   Category :ASP.Net
 

Hello,

I looked around for a while first, but could find no post already.  I am trying to run some javascript on some servier side controls.  For example:

postdir.Attributes.Add(

"onkeyup", "if (this.value.length >= 3) document.formview1." & street.ClientID & ".focus();")

 or

postdir.Attributes.Add("onkeyup", "if (this.value.length >= 3) document.formview1.textbox2.focus();")

The problem is, the script syntax needs the client name, not the ID.  ClientID just give me the ID (id="ctl00_ContentPlaceHolder1_FormView1_LOCSTREETPOSTDIRTextBox") but the redered name is (name="ctl00$ContentPlaceHolder1$FormView1$LOCSTREETPOSTDIRTextBox").

I haven't used javascript in a while, so:

Is there a way I can get the "NAME" of the rendered server control, convert the ID to the NAME, or is there a different javascript syntax to use.

Thank you,




View Complete Post


More Related Resource Links

Use jQuery and ASP.NET AJAX to build a client side Repeater

  
By sending only data to the client, you can profoundly reduce the size of what you send and see a substantial increase in performance. You also allow yourself the ability to easily add features like light-weight sorting and paging on the client. This can not only improve your users' experience, but reduce server load and bandwidth requirements.

Client Side Gridview Pagination using JQuery

  
I would like to show how to use Client Side Gridview Pagination using Jquery Table Pagination Plugin by using Ryan Zielke.

Use jQuery and ASP.NET AJAX to build a client side Repeater

  
By sending only data to the client, you can profoundly reduce the size of what you send and see a substantial increase in performance. You also allow yourself the ability to easily add features like light-weight sorting and paging on the client. This can not only improve your users' experience, but reduce server load and bandwidth requirements.

To that end, I'm going to walk you through these four steps to effectively implementing a client side Repeater, using ASP.NET AJAX and jQuery:

Practical Multithreading for Client Apps

  
Writing applications that use multiple threads is often considered an advanced programming task, prone to errors. In this month's column, I'll focus on a practical application of multithreading in Windows® Forms applications with some real benefits, while attempting to keep things simple. My goal is to present multithreading in an approachable way that addresses a very common need: writing applications with a user interface that remain responsive to the user.

Use jQuery and ASP.NET AJAX to build a client side Repeater

  
By sending only data to the client, you can profoundly reduce the size of what you send and see a substantial increase in performance. You also allow yourself the ability to easily add features like light-weight sorting and paging on the client. This can not only improve your users' experience, but reduce server load and bandwidth requirements.

Adding Client-Side Confirmation When Deleting

  
The JavaScript confirm(string) function displays its string input parameter as the text inside a modal dialog box that comes equipped with two buttons - OK and Cancel (see Figure 1). The confirm(string) function returns a Boolean value depending on what button is clicked (true, if the user clicks OK, and false if they click Cancel).

want to execute url without showing that page or url to client.

  

hello friends,

I need ur help,what i want to do is to execute a url ("To send a text message to client") on client registration but without showing that url page, in short executing url without displaying any page or url to the client.

please help and thanks in advance.


Client script not running

  

Dear all,

in my MVC 2 application, and in the shared Master Page I wrote this little script for menu handling :

<script src="../../Scripts/jquery-1.4.1.js" type="text/javascript"></script>
<script type="text/javascript"> $(document).ready(function () {   
       
     $('#nav li').hover(  
         function () {  
             //show its submenu  
             $('ul', this).slideDown(100);  
   
         },   
        function () {  
           //hide its submenu  
            $('ul', this).slideUp(100);           
         }  
     );  
       
 });</script>


The script, that shows menu items when the

Problem to obtain client IP on web service

  

Friends,

I'm having problems to obtain the client IP on web service. Here's my scenario:

One server with Windows 2003, hosting the web service using .Net Framework 2.0, with IP 10.0.2.50 and host name ServerTransaction.
Other server with Windows 2003, hosting a web application using .Net Framework 2.0, that consuming the web service on  ServerTransaction, with IP 10.0.2.51 and host name ServerApplication.
Many other computers on the local network (IPs: 10.0.2.80, 10.0.2.81, 10.0.2.82, ...) acessing the web application on ServerApplication.

On the code of the web service I've tried to use HttpContext.Current.Request.UserHostAddress or HttpContext.Current.Request.ServerVariables("REMOTE_ADDR") or HttpContext.Current.Request.ServerVariables("HTTP_X_FORWARDED_FORR"), but always I can only get the IP of ServerApplication (10.0.2.51).

Any idea or tip?


Thanks and sorry for my bad english.


Smart Client: Building Distributed Apps with NHibernate and Rhino Service Bus, Part 2

  

Smart client applications are responsive and promote interactivity with the user. In this article, we continue building a smart client application using NHibernate for data access and Rhino Service Bus for reliable communication with the server.

Oren Eini

MSDN Magazine August 2010


Smart Client: Building Distributed Apps with NHibernate and Rhino Service Bus

  

Smart client applications are responsive and promote interactivity with the user. In this article, we start the processes of planning and building a smart client application using NHibernate for data access and Rhino Service Bus for reliable communication with the server.

Oren Eini

MSDN Magazine July 2010


Data Points: Building An Out-of-Browser Client With Silverlight 3

  

Silverlight 2 applications are restricted to running inside a browser. However, Silverlight 3 applications can run inside the browser or out. Here we build a social networking app as a standalone Silverlight 3 application.

John Papa

MSDN Magazine June 2009


Cutting Edge: Explore Rich Client Scripting With jQuery, Part 2

  

Achieving cross-browser compatibility for events is no easy task. The jQuery event handling API addresses the differences in event handling across browsers, allowing you to write more predictable JavaScript.

Dino Esposito

MSDN Magazine April 2009


Cutting Edge: Explore Rich Client Scripting With jQuery, Part 1

  

Thanks to selectors and function chaining, jQuery allows you to write compact, cross-browser code.

Dino Esposito

MSDN Magazine March 2009


Cutting Edge: ASP.NET AJAX and Client-side Templates.

  

AJAX is meant to go beyond mere partial page rendering. Find out where Dino Esposito thinks dynamic pages are headed in the future with ASP.NET AJAX.

Dino Esposito

MSDN Magazine June 2008


Extreme ASP.NET: Web Client Software Factory

  

The Web Service Software Factory is designed to provide guidance and enhanced tools for building Web services using ASMX or WCF.

Fritz Onion

MSDN Magazine August 2007


Extreme ASP.NET: Client-Side Web Service Calls with AJAX Extensions

  

Microsoft AJAX Library and the ASP.NET 2.0 AJAX Extensions provide a number of compelling features ranging from client-side data binding, to DHTML animations and behaviors. Learn all about them here.

Fritz Onion

MSDN Magazine January 2007


Categories: 
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend