我想在WebNavigator按下新增時,WebFormView有個label會直接帶入登入者的姓名?
可在WebFormView的DataBound的事件中寫入,程式如下:
protected void WebFormView1_DataBound(object sender, EventArgs e)
{
if (WebFormView1.CurrentMode == FormViewMode.Insert)
{
Label KeyinNameLabel = (Label)WebFormView1.FindControl("KeyinNameLabel");//KeyinNameLabel為該Label的ID
KeyinNameLabel.Text = CliUtils.fUserName;
}
}
WebNavigator的自訂Control的ControlText失效,自訂的Control都不會顯示出ControlText的內容,反而顯示ControlName?
1.打開Srvtools下的WebNavigator.cs,找到protected virtual void createButton(HtmlTextWriter writer, ControlItem ctrl, WebGridView gdView)方法,在開始的switch中將default: tooltiptext = ctrl.ControlName; break;修改為 default: tooltiptext = ctrl.ControlText; break;
2.Rebuild Srvtools
3.重新InitEEP
在MyWeb中如果新增了一個資料夾,結果新增項目的WebNavigator的圖示都無法顯示出來?
網頁設計因?很多都是使用相對路徑的,所以改變資料夾的深度(比如資料夾內再加資料夾)會導致類似的問題,網頁的設計應在網站的下一層,即您說的MyWeb這一層。