cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Toolkit VC++ : How to play with Orientations

Garnet

Toolkit VC++ : How to play with Orientations

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

Tags (2)
1 REPLY 1

Re: Toolkit VC++ : How to play with Orientations

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