473,395 Members | 1,639 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

How to determine ID of object in custom web control

jef
I've got a rather simple custom web control that has an object declared
as HtmlControls.HtmlInputHidden

Mar 21 '06 #1
2 920
ClientID property

"jef" <je************@gmail.com> wrote in message
news:11**********************@e56g2000cwe.googlegr oups.com...
I've got a rather simple custom web control that has an object declared
as HtmlControls.HtmlInputHidden

Mar 21 '06 #2
My post appears to have gotten truncated... Google Groups doesn't
appear to work well with Safari.. here was the original post:

I've got a rather simple custom web control that has an object declared
as HtmlControls.HtmlInputHidden\0. I set the ID = 'PageNo' and the Name
= 'PageNo'. However, when I look at the page source in the browser,
the object's ID is "WebCtl3_PageNo' and the Name is "WebCtl3:PageNo".
I'm referencing the object in javascript as
document.all['WebCtl3_PageNo']\0 but that seems lame. I get the feeling
that the ID will somehow magically change to "WebCtl2_PageNo" or
"WebCtl4_PageNo" without me realizing it. Is there a better way? I
need to reference it in javascript... is there a way to iterate through
document.all and look for "*PageNo"?

Mar 21 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

18
by: Christopher W. Douglas | last post by:
I am writing a VB.NET application in Visual Studio 2003. I have written a method that handles several events, such as closing a form and changing the visible status of a form. I have some code...
2
by: Vern | last post by:
I have a custom control which has it's own OnValidating event handler. I would like to skip the validations if the Cancel/Exit button is pressed. Also, if possible, would like to skip the...
1
by: Tim Pacl | last post by:
I am building a custom server control. I need to determine whether the page the custom control resides in is in flow layout or grid layout. Because I am doing this from the server control, I need...
6
by: Brad | last post by:
I am creating a class (not a control) which implements IStateManager. I've created the class and all of the implementations (LoadView, SaveViewState, etc...). My Question is: How do I...
3
by: Steve | last post by:
Hi, I want to determine which key was pressed in a control, like a datagrid. I see that in the currentcellchanged event of a datagrid I can capture keystroke events. I have tried someting...
19
by: Simon Verona | last post by:
I'm not sure if I'm going down the correct route... I have a class which exposes a number of properties of an object (in this case the object represents a customer). Can I then use this...
3
by: Developer in California | last post by:
I am working on developing a generic Web framework using Master Pages in ASP.NET 2.0. What I have done is created a PageRenderer class which has a public method which will retrieve the path of the...
1
by: Jeffrey Frabutt | last post by:
Sorry about the repost... but my original post had funky characters that was causing it to get truncated. I've got a rather simple custom web control that has an object delcared as...
1
by: Don | last post by:
I'm getting the following exception displayed in the task list at design time for my project: "Code generation for property 'Controls' failed. Error was: 'Object reference not set to an...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.