My code is in c# asp.net 3.5
In the following code the "Msg" has many words with spaces and characters (eg:Failed to prepare Sync Favorites : Directory does not exist: \STL-FNP-02\ryounes$\Sync\Favorites). This "Msg" is pulled from database to a gridview. I am not able to create hyperlink for this "Msg" in gridview. Since it has spaces it is not creating hyperlink.
I need to create hyperlink for this "Msg" and latter use it in linq query.
I think one shud either use eval or url encoder. I am not sure how to do it. Can anyone say how to go about it?
<asp:HyperLinkField DataTextField="Msg" HeaderText="Msg" DataNavigateUrlFields="Msg"
DataNavigateUrlFormatString="Sync.aspx?Msg={0}" />