473,946 Members | 1,486 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

possible to manipulate pure HTML controls from code-behind?

Can I manipulate the properties of pure HTML controls (i.e. not server side
controls) from my aspx.cs Page_Load event? If so, I don't see the control
listed by intellisense. I gave the control a unique ID to boot. Is what
I'm trying impossible unless you are using a server side control?

Thanks
Nov 15 '05 #1
2 2257
Hi

I think you can't manipulate HTML control unless are server-side control
(runat = server)

If your HTM pure controls contain the runat=server attribute you can find
the control in the "System.Web.UI. HtmlControls" namespace therefore in the
Page_Load event:

protected System.Web.UI.H tmlControls.Htm lInputButton button2;

private void Page_Load(objec t sender, System.EventArg s e)
{
button2.Value = "Go";
}

Ciao
Giorgio

"Jeff" <ex****@exc.dom > ha scritto nel messaggio
news:3f******** **@newspeer2.td s.net...
Can I manipulate the properties of pure HTML controls (i.e. not server side controls) from my aspx.cs Page_Load event? If so, I don't see the control
listed by intellisense. I gave the control a unique ID to boot. Is what
I'm trying impossible unless you are using a server side control?

Thanks

Nov 15 '05 #2
Keep in mind also you can use the generic html control for things such
as <body> tags. (if you wanted to programmaticall y change body tag
attributes)

Giorgio Parmeggiani wrote:
Hi

I think you can't manipulate HTML control unless are server-side control
(runat = server)

If your HTM pure controls contain the runat=server attribute you can find
the control in the "System.Web.UI. HtmlControls" namespace therefore in the
Page_Load event:

protected System.Web.UI.H tmlControls.Htm lInputButton button2;

private void Page_Load(objec t sender, System.EventArg s e)
{
button2.Value = "Go";
}

Ciao
Giorgio

"Jeff" <ex****@exc.dom > ha scritto nel messaggio
news:3f******** **@newspeer2.td s.net...
Can I manipulate the properties of pure HTML controls (i.e. not server

side
controls) from my aspx.cs Page_Load event? If so, I don't see the control
listed by intellisense. I gave the control a unique ID to boot. Is what
I'm trying impossible unless you are using a server side control?

Thanks



Nov 15 '05 #3

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

Similar topics

10
2062
by: Tobias Nilsson | last post by:
I have almost exactly the same problem as the guy below. Is it NOT possible running .NET code locally in Internet Explorer WITHOUT a webserver???? / Tobias --------- My company has in the past created local browser applications with front end in HTML/JavaScript and backend in the form of a Java applet. The applet code contained the business code and calculations. Benefit of this approach is
1
5729
by: Nic | last post by:
Hi - I am battling to find the a resource, so maybe some one in here can help The problem is as follows: I am trying to build a mod_perl source code editor for the web - to edit Perl source code in a browser. The trick is that I want to add syntax highlighting to a HTML TEXTAREA tag. There are millions of resources for just normal text color and background colors (and images), but nothing on keyword highlighting.
9
2603
by: Edward Diener | last post by:
I received no answers about this the first time I posted, so I will try again. My inability to decipher an MSDN topic may find others who have the same inability and someone who can decipher and explain it. I have some questions about the instructions for creating a mixed mode DLL in the MSDN topic "Converting Managed Extensions for C++ Projects from Pure Intermediate Language to Mixed Mode" in the "Managed Extensions for C++ Reference"....
6
2663
by: Zingam | last post by:
Is it possible to insert a WinForm in a WebForm? I'd like for example to insert a managed directx viewer in a webform, that would display 3d graphics on the form? Is this possible? Regards, Z.
2
1213
by: Olivier Matrot | last post by:
Hello, I'm looking for a tool that is able to manipulate aspx source files (specifically <asp:datagrid> ) out of Visual Studio. The goal is to give aspx file to a web designer in order for him to acomodate our corporate web site design. This tool must know the HMTL rendering of standard server controls.
2
1781
by: Mark | last post by:
Hi, I am wanting to know if it is possible to embed a UserControl into a Page at runtime. What I am trying to do is allow a user to specify that they want a "contact form" or a "latest news" in their page by simply entering {contact form} or {latest news} in the HTML of their page. What I have is two asp.net user controls called ContactForm.ascx and LatestNews.ascx
8
1920
by: Daniel | last post by:
Hi, Does anyone know if it is possible to put an aspx page inside of another? OR run an aspx page and capture the output as a string and then write this out to a page.... So for example say you have a page that takes an id number as a query string and displays different things based on that id number. If you were able to loop through running the aspx pages with id=100, id=200,
21
2599
by: sks | last post by:
Hi , could anyone explain me why definition to a pure virtual function is allowed ?
0
1036
by: Ken Fine | last post by:
This supplements a question I asked earlier, about acting on ASP.NET controls of a particular type. I'm wondering how to loop through all controls on a page and manipulate user controls with custom properties set to a specific value -- can someone offer a code snip? What is the last point in the page lifecycle that I would still be "permitted" to do this? Thanks, -KF
1
1340
by: C. (http://symcbean.blogspot.com/) | last post by:
On Aug 12, 7:08 am, long_way <yilongwei....@gmail.comwrote: Hi, Wouldn't it just be simpler to use Google maps? I'm not overly familiar with greybox, but it should be fairly straightforward to amend the code. You need to seperate the problem of how to position the overlay with how to integrate it in greybox.
0
10155
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9981
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
11563
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
11153
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
11335
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10686
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
8249
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6111
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
3
3540
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.