2012-06-27 32 views
0

嗨,我正在使用RichEditor。該編輯器將表格中的跨度和樣式保存起來。 所以,我用下面的方法來避免這種情況:HtmlDecode(DataBinder.Eval(Container.DataItem, "ImageDesc"))HtmlDecode方法的參數無效?

但它就像給錯誤:

HtmlCode有一些無效參數

我該如何解決這個.The C#代碼爲:

public string HtmlDecode(string strValue) 
    { 
     string functionReturnValue = null; 
     try 
     { 
      functionReturnValue = Server.HtmlDecode(strValue); 

     } 
     catch (Exception exc) 
     { 
      // ProcessModuleLoadException(this, exc); 
     } 
     return functionReturnValue; 
    } 

回答

0

strValue是否爲空?嘗試添加空測試。如果它爲空,則替換爲空字符串。