|
Home > Archive > Microsoft Content Management Server > September 2006 > kb article 873203
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
|
|
|
| I was looking at kb article 873203 to clean up web pages with deleted
resources. The last procedure doesn't make sense. It looks like it's
missing something in each of the case statements and there is a value for
ropValue and it's not even declared. The number of brackets done even match.
Please advise. Thanks.
public void CmsPosting_PlaceholderPropertyChanging( Object sender,
PropertyChangingEventArgs e )
{
string propName = e.PropertyName;
string propValue = e.PropertyValue as string;
switch (propName)
{
case "Html" : // handle HtmlPlaceholder
ropValue = HandleImageTags(propValue);
propValue = HandleAnchorTags(propValue);
break;
}
case "Src" : // handle ImagePlaceholder
case "Url" : // handle AttachmentPlaceholder
{
propValue = HandleImgAndAttPlaceholderTypes(propValu
e);
break;
}
}
e.PropertyValue = propValue;
}
| |
| Stefan [MSFT] 2006-09-28, 7:25 am |
| Hi Helen,
this method has bugs.
ropValue should read propValue.
Cheers,
Stefan
--
This posting is provided "AS IS" with no warranties, and confers no rights
"hkwan" <hkwan@discussions.microsoft.com> wrote in message
news:D18C2835-0D54-4292-BBB3-9E045F3CFE37@microsoft.com...
>I was looking at kb article 873203 to clean up web pages with deleted
> resources. The last procedure doesn't make sense. It looks like it's
> missing something in each of the case statements and there is a value for
> ropValue and it's not even declared. The number of brackets done even
> match.
> Please advise. Thanks.
>
> public void CmsPosting_PlaceholderPropertyChanging( Object sender,
> PropertyChangingEventArgs e )
> {
> string propName = e.PropertyName;
> string propValue = e.PropertyValue as string;
> switch (propName)
> {
> case "Html" : // handle HtmlPlaceholder
> ropValue = HandleImageTags(propValue);
> propValue = HandleAnchorTags(propValue);
> break;
> }
> case "Src" : // handle ImagePlaceholder
> case "Url" : // handle AttachmentPlaceholder
> {
> propValue = HandleImgAndAttPlaceholderTypes(propValu
e);
> break;
> }
> }
> e.PropertyValue = propValue;
> }
>
>
>
| |
|
| Hi Stefan,
I think you're right. ropValue is not the only bug. The case statement
don't make sense nor the brackets.
I'm thinking the file must have gotten corrupted some how. Is there a
place I can get a cleaner version of it? Thank you.
Helen.
"Stefan [MSFT]" wrote:
> Hi Helen,
>
> this method has bugs.
> ropValue should read propValue.
>
> Cheers,
> Stefan
>
> --
> This posting is provided "AS IS" with no warranties, and confers no rights
>
>
> "hkwan" <hkwan@discussions.microsoft.com> wrote in message
> news:D18C2835-0D54-4292-BBB3-9E045F3CFE37@microsoft.com...
>
>
>
| |
| Stefan [MSFT] 2006-09-29, 7:22 am |
| Hi Helen,
the logic is correct.
Just correct the typo and the braces and the method should work correct.
Cheers,
Stefan
--
This posting is provided "AS IS" with no warranties, and confers no rights
"hkwan" <hkwan@discussions.microsoft.com> wrote in message
news:C9165F20-7DD8-4230-83E3-69801780DB7B@microsoft.com...[vbcol=seagreen]
> Hi Stefan,
>
> I think you're right. ropValue is not the only bug. The case statement
> don't make sense nor the brackets.
>
> I'm thinking the file must have gotten corrupted some how. Is there a
> place I can get a cleaner version of it? Thank you.
>
> Helen.
>
> "Stefan [MSFT]" wrote:
>
|
|
|
|
|