Question
IDCS3 Mac - Not able to generate a MulticolumnTextFrame
Hello everyone: <br /><br /> I have the following code in my plugin (Please note that for brevity's sake I have removed all of the tests, but be reassured that all InterfacePtrs get created just fine):<br /><br /> // Now we need to see if it all fits on one page or not<br /> InterfacePtr<IStoryList> storyList (doc, IID_ISTORYLIST);<br /><br /> int32 numStories = storyList -> GetUserAccessibleStoryCount(); // should be one<br /> UIDRef storyRef = storyList -> GetNthUserAccessibleStoryUID(0); // because there is only one<br /><br /> InterfacePtr<ITextModel> textModel(storyRef, IID_ITEXTMODEL);<br /><br /> InterfacePtr<IFrameList> frameList(textModel -> QueryFrameList());<br /><br /> UID textFrameUID = frameList -> GetNthFrameUID(0);<br /> UIDRef textFrameRef = UIDRef (db, textFrameUID);<br /><br /> InterfacePtr<IMultiColumnTextFrame> multitextFrame(db, textFrameUID, UseDefaultIID()); //multitextFrame is NULL<br /> if (multitextFrame == nil)<br /> {<br /> ASSERT_FAIL("Cannot obtain Multi Text Frame");<br /> break;<br /> }<br /><br />The IMultiColumnTextFrame does not get instantiated and when it is tested, so when the variable is tested for nil, the test is evaluated to true and the ASSERT_FAIL message is published and the code breaks from the rest of the do {} while() loop.<br /><br />textFrameUID has a value that *looks* appropriate (216), db is filled without any error, and the final argument is fairly straightforward. Does anyone see why my multitextFrame is not getting instantiated?<br /><br />TIA!<br />John