Does anybody know why using "height" as the name and alias of a macro parameter should cause a parser error? Is it a reserved word?
Umbraco v4.0.2.1, asp.net v2.0, windows vista, IIS 6.0
Error message:
Server Error in '/' Application.
Parser Error
Description: An
error occurred during the parsing of a resource required to service
this request. Please review the following specific parse error details
and modify your source file appropriately.
Parser Error Message: Cannot
create an object of type 'System.Web.UI.WebControls.Unit' from its
string representation '[#col1Box1Height]' for the 'Height' property.
Source Error:
Line 7: <div class="yui-u first"> Line 8: Line 9: <umbraco:Macro height="[#col1Box1Height]" test2="[#col1Box1Header]" test3="[#col1Box1Text]" Alias="ScrollBox" runat="server"></umbraco:Macro> Line 10: <div> Line 11: <umbraco:Item field="Col1Box2Header" runat="server"></umbraco:Item>
I would not use height, width or ID as param names in one of my macros, changed the names (imageHeight, imageWidth, imageID) and it worked a treat. I did not get a parse error though, just no output?
Yes, I changed the name to boxHeight and the parser error disappeared. The macro still didn't output anything. I had created a test macro whilst trying to find the problem originally. This was working better so I copied my xslt into it and it all works just fine now.
Stil not sure about the reasons for any of this.
(I have now just had another problem with a document type disappearing - so maybe something is up with my database?)
macro parameter name causing parser error
Does anybody know why using "height" as the name and alias of a macro parameter should cause a parser error? Is it a reserved word?
Umbraco v4.0.2.1, asp.net v2.0, windows vista, IIS 6.0
Error message:
Server Error in '/' Application.
Parser Error
Description: An error occurred during the parsing of a resource required to service this request. Please review the following specific parse error details and modify your source file appropriately.Parser Error Message: Cannot create an object of type 'System.Web.UI.WebControls.Unit' from its string representation '[#col1Box1Height]' for the 'Height' property.
Source Error:
Source File: /masterPages/About(CorporateChannel)Homepage.master Line: 9
Version Information: Microsoft .NET Framework Version:2.0.50727.3074; ASP.NET Version:2.0.50727.3074
Looks like it, the unit is probably supposed to be a percentage or an integer.
I would not use height, width or ID as param names in one of my macros, changed the names (imageHeight, imageWidth, imageID) and it worked a treat. I did not get a parse error though, just no output?
Hi
Yes, I changed the name to boxHeight and the parser error disappeared. The macro still didn't output anything. I had created a test macro whilst trying to find the problem originally. This was working better so I copied my xslt into it and it all works just fine now.
Stil not sure about the reasons for any of this.
(I have now just had another problem with a document type disappearing - so maybe something is up with my database?)
Ruth
is working on a reply...