문제

I've got a List and a Document Library. Both have their own content types. In those content types is a site column, a multiline one with Rich Text.

In this column, I'm coding a simple link with html markup.

The custom list displays a clickable hyperlink like this "GOOGLE" which is alright.

The Document Library, however, displays the code with the html markup.

How is this possible, provided the column is the same used in both content types?

How can I fix this in the document library?

도움이 되었습니까?

해결책

Found how to resolve this matter :

SPField field = myList.Fields["MultilineColumn"]; 

SPSecurity.RunWithElevatedPrivileges(delegate()
{
    oWeb.AllowUnsafeUpdates = true;
    (field as SPFieldMultiLineText).RichText = true;
    field.Update();
    oWeb.AllowUnsafeUpdates = false;
});

//Then add html to the multiline column. 
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 sharepoint.stackexchange
scroll top