Searching the HTML code of the MainBody

Hello, I was wondering how I could access the html for the MainBody property. I am basically trying to find part of the code using regular expressions but when i use the CurrentPage["MainBody"].ToString(), I don't get the html code. string strMainBody = CurrentPage["MainBody"].ToString(); string ImageRegEx = "([^>]+)"; Match m = Regex.Match(strMainBody, ImageRegEx); Label1.Text = "Label" + m.ToString(); Thanks. Victor
Jul 31, 2007 16:45
Is it that you don't get the HTML from the property or is it the RegExp that doesn't work? Regards HAXEN
Aug 01, 2007 10:05
Hi Victor Your approach is correct, but you should rephrase your regex pattern into something like this: \
Aug 01, 2007 12:29
You need to access the MainBody property as a PropertyLongString i order to get hold of the HTML code. PropertyLongString mainBody = (PropertyLongString)CurrentPage.Property["MainBody"];
Aug 01, 2007 14:57
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.