Generation of inline code in ASP.NET by XSL [modified]
-
I'm trying to create ASPX page with DataGrid, that includes template column, which looks like TextBox. I order to enable data binding to textbox I'm using the following syntax: using XSL. I supposed, the XSL code should be the same, while escaping '<','>' etc.: . In this case I'm getting the following error: Parser Error Message: Code blocks are not supported in this page, because it is not compiled. Please, assist. Alex -- modified at 10:06 Wednesday 29th August, 2007
-
I'm trying to create ASPX page with DataGrid, that includes template column, which looks like TextBox. I order to enable data binding to textbox I'm using the following syntax: using XSL. I supposed, the XSL code should be the same, while escaping '<','>' etc.: . In this case I'm getting the following error: Parser Error Message: Code blocks are not supported in this page, because it is not compiled. Please, assist. Alex -- modified at 10:06 Wednesday 29th August, 2007
It is objecting to the "<%# ... %>" code which gets placed in the .aspx page before it gets compiled. By the time you place your code in the page, the page has already been compiled. Also, why place a textbox in this way when you can do it statically in design mode?
"We make a living by what we get, we make a life by what we give." --Winston Churchill
-
It is objecting to the "<%# ... %>" code which gets placed in the .aspx page before it gets compiled. By the time you place your code in the page, the page has already been compiled. Also, why place a textbox in this way when you can do it statically in design mode?
"We make a living by what we get, we make a life by what we give." --Winston Churchill
Is there any workaround? Is it possible to implement this in code-behind file?
-
Is there any workaround? Is it possible to implement this in code-behind file?
There are a some ways but you have to stay away from the code blocks. You may need to as your question in the ASP.NET Forum to get a better answer, but you can use XSL in the creation of a custom control or during the binding processs you can add content to a cell or even modify the whole row. However, you have to stay away from coding blocks.
"We make a living by what we get, we make a life by what we give." --Winston Churchill
-
There are a some ways but you have to stay away from the code blocks. You may need to as your question in the ASP.NET Forum to get a better answer, but you can use XSL in the creation of a custom control or during the binding processs you can add content to a cell or even modify the whole row. However, you have to stay away from coding blocks.
"We make a living by what we get, we make a life by what we give." --Winston Churchill
Thanks anyway :)