Feb 09, 2010, 1:02 PM
C# Code in Markup-Script-Tag or Codebehind
Hello,
I just found it, that I do not need to recompile my whole solution,
when I change C# Code inside a <script runat="server">-Tag in Markup.
This only takes seconds to test something instead of 2-3 Minutes for writing the code in codebehind,
stopping the debugger, restarting the debugger.
Does anybody of you know any disadvantages of writing code in markup?
For example that the Customer can see the sourcecode.
Or is it slower on runtime if the code is in the markup file or... whatever?
Regards,
Martin
I just found it, that I do not need to recompile my whole solution,
when I change C# Code inside a <script runat="server">-Tag in Markup.
This only takes seconds to test something instead of 2-3 Minutes for writing the code in codebehind,
stopping the debugger, restarting the debugger.
Does anybody of you know any disadvantages of writing code in markup?
For example that the Customer can see the sourcecode.
Or is it slower on runtime if the code is in the markup file or... whatever?
Regards,
Martin