473,385 Members | 1,707 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,385 software developers and data experts.

Web Object objects NOT Appearing in aspx.cs

I need to add a method to the "onload" event of the <body> tag. The body tag
has been set to:

<body id="bodyComments" runat=server>

However, "bodyComments" is not recognizable in the web page's aspx.cs page.
(I have had similar problems with the <form> tag but found it eventually
appears if I close and relaunch VS.Net). I have relaunched VS this time but
no luck. What I am trying to do is shown in VS.Net help section on Javascript
so it "should" work?

I am using VS.Net 2003, version 1.1.4322 SP1. This problem existed before
applying SP1.

Thanks.
Nov 18 '05 #1
2 1465
Did you declare the Control in your CodeBehind class?

protected System.Web.UI.HtmlControls.HtmlGenericControl bodyComments;

--
HTH,
Kevin Spencer
..Net Developer
Microsoft MVP
I get paid good money to
solve puzzles for a living

"ASP Yaboh" <AS******@discussions.microsoft.com> wrote in message
news:5E**********************************@microsof t.com...
I need to add a method to the "onload" event of the <body> tag. The body tag has been set to:

<body id="bodyComments" runat=server>

However, "bodyComments" is not recognizable in the web page's aspx.cs page. (I have had similar problems with the <form> tag but found it eventually
appears if I close and relaunch VS.Net). I have relaunched VS this time but no luck. What I am trying to do is shown in VS.Net help section on Javascript so it "should" work?

I am using VS.Net 2003, version 1.1.4322 SP1. This problem existed before
applying SP1.

Thanks.

Nov 18 '05 #2
Kevin,

Thank you that worked.

Are there any ASP.Net references that you could recommend? I'm new to
ASP.Net (but not C#), and I find my current resources lacking. Especially
when I use a MS example from their help (this <body> tag issue), and, correct
me if I am wrong, I see no mention on that help page of adding the
HTMLGenericControl to my aspx.cs page.

Thanks again for your time.
"Kevin Spencer" wrote:
Did you declare the Control in your CodeBehind class?

protected System.Web.UI.HtmlControls.HtmlGenericControl bodyComments;

--
HTH,
Kevin Spencer
..Net Developer
Microsoft MVP
I get paid good money to
solve puzzles for a living

"ASP Yaboh" <AS******@discussions.microsoft.com> wrote in message
news:5E**********************************@microsof t.com...
I need to add a method to the "onload" event of the <body> tag. The body

tag
has been set to:

<body id="bodyComments" runat=server>

However, "bodyComments" is not recognizable in the web page's aspx.cs

page.
(I have had similar problems with the <form> tag but found it eventually
appears if I close and relaunch VS.Net). I have relaunched VS this time

but
no luck. What I am trying to do is shown in VS.Net help section on

Javascript
so it "should" work?

I am using VS.Net 2003, version 1.1.4322 SP1. This problem existed before
applying SP1.

Thanks.


Nov 18 '05 #3

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

Similar topics

6
by: Martin | last post by:
I'd like to be able to get the name of an object instance from within a call to a method of that same object. Is this at all possible? The example below works by passing in the name of the object...
4
by: Marcel Balcarek | last post by:
Hello, I have a page (page1.aspx) that builds some complex .NET objects. I successfully pass these objects to another different window (page2.aspx). How can I persist these objects on a POST...
4
by: Bill Thorne | last post by:
We have a COM object that has been wrappered for use in .NET and which can make calls which can take a while to execute. These are mainframe integration calls that might perform a lot of data...
15
by: randyr | last post by:
I am developing an asp.net app based on a previous asp application. in the asp applications global.asa file I had several <object id="id" runat="server" scope="scope" class="comclass"> tags for...
26
by: yb | last post by:
Hi, Is there a standard for the global 'window' object in browsers? For example, it supports methods such as setInterval and clearInterval, and several others. I know that w3c standardized...
2
by: avanhalen | last post by:
To embed flash objects in my pages, I read them from a database. A script file (Filedownload.aspx) reads it from the database, and streams it to the browser. Here are two example flash objects...
3
by: GoogleEyeJoe | last post by:
Dear ladies and gents, I'm trying to determine whether the .NET Framework implements a means of transactional processing without the need for a database. Essentially, I'd like to enlist...
2
by: David Thielen | last post by:
Hi; I have a small XML file that I need to read/change from my app. Is there some easy way to map from XML to my objects so I can just read it in to my objects, change the objects as needed,...
1
by: markla | last post by:
Hi, I have an Entity data model built in Entity Framework, which sources data primarily from an MS SQL 2008 database, and sources some static (data dictionary) values from code-based objects. I...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 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 former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
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:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
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
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
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...

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.