Webforms 背后的代码:在 Aspx 页面中编写 FindControl IF 语句

问题描述

我有一些这样的 html:

<table cellpadding="2" class="summary" style="font-family: sans-serif; font-size: 12px; color: Black;">

我该如何做这样的事情:

<table cellpadding="2" class="summary" style="font-family: sans-serif; font-size: 12px; color: Black; background-color: <%= FindControl("pageType").value == null ? "#000000" : "#ff0000"     %>">

那么如何返回一个控件值并在html中设置数据?

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)