Quantcast
Channel: MicroStation Programming - Forum - Recent Threads
Viewing all articles
Browse latest Browse all 1677

[V8i mdl] MS crash when i try to use mdlDisplayPath_getInfoString function

$
0
0

Hi,

this code work in V8 2004 and when i try to use it in V8i, microstation crash on the mdlDisplayPath_getInfoString.

extern "C" DLLEXPORT char* GetInfoBulle(ElementId idElt){ ElementRef elemRef; DisplayPathP path ;
MSWChar chaineW[MAX_DISPLAYPATH_INFO_STRING ];
char * ret=NULL;

printf("test1\n");
elemRef = dgnCache_findElemByID(mdlModelRef_getCache(mdlModelRef_getActive()), idElt);
printf("test2\n");
path=mdlDisplayPath_new (elemRef,mdlModelRef_getActive());
printf("test3\n");
mdlDisplayPath_getInfoString(path,chaineW);
printf("test4\n");

Any idea?
I try to use the function with the path provide by 

mdlLocate_setFunction(LOCATE_PROVIDE_PATH_DESCRIPTION, test);
Public void test
(
DisplayPathP path,
MSWChar* description,
MSWChar* refStr
)
{
MSWChar chaineW[MAX_DISPLAYPATH_INFO_STRING ]; mdlDisplayPath_getInfoString(path,chaineW);}

and i had the same problem	
Regards
Seb

Viewing all articles
Browse latest Browse all 1677

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>