Saturday, March 31, 2012

Why is this different using VS 2005

I am so confused or I guess it is just the IDE.

I drag a label into my source window(aspx) , change the default name etc and
in the code behind all is good. I can reference the label etc.

Now I go back to source window and just copy the line with the label.
Change the ID etc and (WAIT FOR IT), I cannot reference the lable in code.
I delete that line from the source and drag another in. Well of course I
can reference this one.

WHAT IS THE DIFFERENCE? I thought this was a RAD tool! It makes no sense
that the IDE with D&D capabilities would do something stupid like that.

Lloyd SheenSometimes you need to move from html view to design view. The code behind
relies on the designer file, which is sometimes updated when you switch
views.

--
Hope this helps,
Mark Fitzpatrick
Former Microsoft FrontPage MVP 199?-2006

"Lloyd Sheen" <a@.b.cwrote in message
news:234DE45A-1F70-4759-8478-A0B239900413@.microsoft.com...

Quote:

Originally Posted by

>I am so confused or I guess it is just the IDE.
>
I drag a label into my source window(aspx) , change the default name etc
and in the code behind all is good. I can reference the label etc.
>
Now I go back to source window and just copy the line with the label.
Change the ID etc and (WAIT FOR IT), I cannot reference the lable in code.
I delete that line from the source and drag another in. Well of course I
can reference this one.
>
>
WHAT IS THE DIFFERENCE? I thought this was a RAD tool! It makes no
sense that the IDE with D&D capabilities would do something stupid like
that.
>
Lloyd Sheen


It also has impact if you use the default stock project model in VS2005
(which is new in VS2005) vs Web Application Project model which reminds the
model in VS2003. In the latter there are designer files etc within the
project plus project files, which , in my opinion, seem to make VS work more
reliably

See: http://west-wind.com/weblog/posts/5601.aspx
--
Teemu Keiski
AspInsider, ASP.NET MVP
http://blogs.aspadvice.com/joteke
http://teemukeiski.net
"Lloyd Sheen" <a@.b.cwrote in message
news:234DE45A-1F70-4759-8478-A0B239900413@.microsoft.com...

Quote:

Originally Posted by

>I am so confused or I guess it is just the IDE.
>
I drag a label into my source window(aspx) , change the default name etc
and in the code behind all is good. I can reference the label etc.
>
Now I go back to source window and just copy the line with the label.
Change the ID etc and (WAIT FOR IT), I cannot reference the lable in code.
I delete that line from the source and drag another in. Well of course I
can reference this one.
>
>
WHAT IS THE DIFFERENCE? I thought this was a RAD tool! It makes no
sense that the IDE with D&D capabilities would do something stupid like
that.
>
Lloyd Sheen

0 comments:

Post a Comment