Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > adding runat=server to a control on aspx page, don't cause the IDE to add the control to the code behind

Reply
Thread Tools

adding runat=server to a control on aspx page, don't cause the IDE to add the control to the code behind

 
 
z. f.
Guest
Posts: n/a
 
      06-24-2004
Hi,

adding a control with runat=server to an aspx page (using code - not
designer view) - don't cause the control to be added to the code behind (.cs
ot .vb file)

only if i change the aspx view to designer and then to the HTML view again,
the code behing is changed to add the controls with runat=server property.

is there a way using the IDE commands to run this command that the IDE is
making "behind the scenes" when switching to designer and then to HTML view
again?

TIA, z.


 
Reply With Quote
 
 
 
 
Mikhail Arkhipov \(MSFT\)
Guest
Posts: n/a
 
      06-25-2004
No, when editing in HTML view, you have to declare control manually in the
code behind file.

Thanks
Mikhail Arkhipov (MSFT)
-- This post is provided "AS IS" with no warranties, and confer no rights.

"z. f." <> wrote in message
news:...
> Hi,
>
> adding a control with runat=server to an aspx page (using code - not
> designer view) - don't cause the control to be added to the code behind

(.cs
> ot .vb file)
>
> only if i change the aspx view to designer and then to the HTML view

again,
> the code behing is changed to add the controls with runat=server property.
>
> is there a way using the IDE commands to run this command that the IDE is
> making "behind the scenes" when switching to designer and then to HTML

view
> again?
>
> TIA, z.
>
>



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Adding items on an aspx page doesn't cause them to be created in the code behind. JB ASP .Net 2 03-07-2007 08:20 PM
adding main.aspx.vb & main.aspx.resx under aspx John M ASP .Net 1 05-29-2005 09:27 PM
How to bring aspx code (in HTML view) to the aspx.vb code-behind? Paolo Pignatelli ASP .Net 6 02-21-2005 01:55 AM
Adding controls through html doesn't add them in code behind John Dalberg ASP .Net 2 05-03-2004 05:48 PM
Re: Code Behind vs. no code behind: error Ben Miller [msft] ASP .Net 1 06-28-2003 01:46 AM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57