IS it possilbe to inline code a porperty like Font-bold of control like linkbutton?
Font-Bold=”<%=(Display==1)?
true:false%>”
this doesn’t work.
Cannot create an object of type
‘System.Boolean’ from its string
representation ‘<%=(Display==2)?
true:false%>’ for the ‘Bold’
property.
No, you can’t use inline code on attributes of Runat=”server” elements.
Use the PreRender event of the page. Assuming the linkbutton has ID=”myLinkButton” :-