Adding label to asp.net page

  • Thread starter Thread starter Doogie
  • Start date Start date
D

Doogie

I added this label inside a <div>:

<asp:label id="lblNegRate" runat="server" style="color:Red"
text="* Denotes a negotiated rate." />

and when I run my app, I get this error:

"sys.argumentexception: value must not be null for controls and
behaviors"

I don't understand what the error is trying to tell me. Anyone have
any ideas?
 
I added this label inside a <div>:

    <asp:label id="lblNegRate" runat="server" style="color:Red"
text="* Denotes a negotiated rate." />

and when I run my app, I get this error:

"sys.argumentexception: value must not be null for controls and
behaviors"

I don't understand what the error is trying to tell me.  Anyone have
any ideas?

Actually it turns out that this line is the problem:
<script type="text/javascript" language="javascript" src="../Includes/
wz_tooltip.js" visible="true" />

I had modified it from this:
<script type="text/javascript" language="javascript" src="../Includes/
wz_tooltip.js" visible="true" ></script>
Essentially remove the </script> and replacing it with a /> value.
Not sure why that error occurs because that should be valid (and I
have an identical line - different js page reference - in a line above
it and I did the same thing and it works). Must be something wrong
with wz_tootip.js perhaps? Why would the error only occur when I
change the way I end the script tag then? Very odd.
 
It's a known issue - basically, try it one way and if it doesn't work tryit
the other way...

Also, you need to remove language="javascript" from all your script tags, as
that property has been deprecated for over 12 years...

--
Mark Rae
ASP.NET MVPhttp://www.markrae.net- Hide quoted text -

- Show quoted text -

Will do. I actually didn't put it in there, it was there and I was
trying to clean up other stuff I saw and didn't know that it was
deprecated. Thanks. :)
 
Back
Top