How to create type 66 elements or XDATA and save them in DWG mode when working in V8 MDL.
There are essentially two ways that an application may store data within a design file:1) By attaching linkages to standard elements.2) By creating and storing application (Type 66) elements.In MicroStation V8 (08.00.02.20) and prior, neither of these types of data are saved when a DGN file is saved to DWG . Not to mention that this data is also discarded if it is created while editing a DWG file. For this reason, applications have been restricted to working solely in DGN files.There have been some changes so that both linkage data and type 66 application elements can be saved from DGN to DWG and this data is al so maintained within a DWG file. The changes were incorporated in MS v8.1 (08.01.00.07 and higher) and are available. This new cap ability is off by default and can be enabled by setting the MS_DWGSAVEAPPLICATIONDATA configuration variable. The application elements are stored as XRECORDS and the linkages as XDATA, although this implementation detail is transparent to DGN based applications.There are MDL functions, mdLinkage_xxxXDataxxx(), that will allow developers to write XDATA and XRECORDS to DWG models. There is an example called Dictionary that illustrate how to implement this functionality. This example and many other can currently be found on "MicroStation On The Web-> Utilities->MDL General"http://microstation.bentley.com/files/motw/resources/utilities/V8MDLExamples.zip