Skip to main content
13-Aquamarine
August 20, 2024
Solved

"ProBomballoonAllCreate" API returns PRO_TK_NOT_DISPLAYED error

  • August 20, 2024
  • 2 replies
  • 1448 views
Hi all,
 
Unable to create balloons from repeat region bom table. I'm getting return error (Drawing not displayed) for last line api "ProBomballoonAllCreate". but drawing is already displayed. Also Only one dwg table present inside drawing.
 

https://www.ptc.com/en/support/article/CS276430 . Already tried with this solution, but still no luck

 
\\
status = ProDrawingFromTmpltCreate(model_name, drawing, &model, PRODWGCREATE_DISPLAY_DRAWING, &newdrawing, &errors);
int drw_windowID;
status = ProMdlWindowGet(newdrawing, &drw_windowID);
ProWindowActivate(drw_windowID);
ProWindowRepaint(drw_windowID);
ProDwgtable *tables = NULL;
status = ProDrawingTablesCollect(newdrawing, &tables);
int regionId ;
status = ProDwgtableCellRegionGet(newdrawing, &tables[0], 0, 1, &regionId);
status = ProBomballoonAllCreate(newdrawing, &tables[0], regionId);
 
\\
 
VA_3544793_0-1724179339678.png

Thanks.

Best answer by VA_3544793

Yes, I fixed it. In API "ProDrawingFromTmpltCreate" argument "PRODWGCREATE_DISPLAY_DRAWING" changed to "PRODWGCREATE_WRITE_ERRORS_TO_FILE" has solved this

2 replies

12-Amethyst
October 3, 2024

I'm not familiar with Toolkit, but should this code reference the drawing view, and not the new drawing for the BOM balloons?

RPN
18-Opal
November 6, 2024

I guess you have it already fixed, but the drawing must be displayed in a Window.

VA_354479313-AquamarineAuthorAnswer
13-Aquamarine
November 19, 2024

Yes, I fixed it. In API "ProDrawingFromTmpltCreate" argument "PRODWGCREATE_DISPLAY_DRAWING" changed to "PRODWGCREATE_WRITE_ERRORS_TO_FILE" has solved this