Community Tip - Did you get called away in the middle of writing a post? Don't worry you can find your unfinished post later in the Drafts section of your profile page. X
Hello All,
I want to change the Orientation of current Solid model using toolkit.
Please let me know if there is any function for the same?
Please find the attachment for more details.
Warm regards,
Madhavi
Hello Madhavi,
i am not shure if you solve the problem but it is very easy:
#if PROE_VERSION >= 30
{
ProMdlType modelType;
status = ProMdlTypeGet (modelId, &modelType);
if ((modelType == PRO_MDL_PART) || (modelType == PRO_MDL_ASSEMBLY))
{
ProView tmpView = NULL;
ProLine *viewNames = NULL;
ProLine *alternateViewNames = NULL;
int i;
int countViews;
int countViewNames;
int countAlternateViewNames;
status = displayModel(modelId, -1); => use ProMdlDisplay() and ProMdlActivate()
if (status == PRO_TK_NO_ERROR)
{
status = ProViewNamesGet(modelId, &viewNames, &alternateViewNames, &countViews);
status = ProArraySizeGet(viewNames, &countViewNames);
status = ProArraySizeGet(alternateViewNames, &countAlternateViewNames);
for (i = 0; i < countViewNames; i++)
{
status = ProViewRetrieve(modelId, viewNames[i], &tmpView);
status = ProViewRefit(modelId, tmpView);
}
for (i = 0; i < countAlternateViewNames; i++)
{
status = ProViewRetrieve(modelId, alternateViewNames[i], &tmpView);
status = ProViewRefit(modelId, tmpView);
}
}
status = ProArrayFree((ProArray *)&viewNames);
status = ProArrayFree((ProArray *)&alternateViewNames);
}
}
#endif
Martin