Skip to main content
Inspiring
July 2, 2024
Question

TOCFormatEntryInfo does not give fParaFormatStyle when entry style is selected as same style.

  • July 2, 2024
  • 0 replies
  • 111 views

 

I have created a TOC style with the entry style is selected as Same style. When I try to access TOCFormatEntryInfo fParaFormatStyle, it returns 0.

When the entry style is set to a different paragraph style, it returns the fParaFormatStyle. 

Is there a way to obtain the UID of the entry style when it is set as the same style?

InterfacePtr<ITOCStyleInfo> theTOCStyle(db, tocStyleID, UseDefaultIID());
BREAK_IF_NIL(theTOCStyle);

const FormatEntriesInfo& entryMap = theTOCStyle->GetTOCEntryMap();
for (int i = 0; i < entryMap.size(); ++i)
{
     TOCFormatEntryInfo tocFormatEntryInfo = entryMap[i].Value();
     paraStyleID = tocFormatEntryInfo.fParaFormatStyle;
}

 

This topic has been closed for replies.