Associative dimensions on custom entities not working in AutoCAD 2019.

Associative dimensions on custom entities not working in AutoCAD 2019.

tripathi.navneet18
Participant Participant
761 Views
1 Reply
Message 1 of 2

Associative dimensions on custom entities not working in AutoCAD 2019.

tripathi.navneet18
Participant
Participant

Associative dimensions on custom entities are not working in AutoCAD 2019. 
The functions "acdbEnableDimAssocForEntity" and "acdbDisableDimAssocForEntity" is not present in "AcDimX23.dll".

And since the above mentioned functions are not present it is returning null when trying to getProcAddress() as mentioned below.

_______________________________________________________________

HMODULE hModule = LoadLibrary(_T("AcDimX23.dll"));
exp_acdbEnableDimAssocForEntity fPtrEnableDimAssoc;
if (nullptr != hModule)


fPtrEnableDimAssoc =      (exp_acdbEnableDimAssocForEntity)GetProcAddress(hModule,"acdbEnableDimAssocForEntity");

// fPtrEnableDimAssoc is null after the above function call.

________________________________________________________________

 

And because of the above the associative dimensions are not working for the custom entities.

Please have a look into the attached image from the dependency walker for further clarification.

Is there any work around for this??

0 Likes
Accepted solutions (1)
762 Views
1 Reply
Reply (1)
Message 2 of 2

Alexander.Rivilis
Mentor
Mentor
Accepted solution

acdbEnableDimAssocForEntity function was moved to acdbNN.lib (and acdbNN.dll) in AutoCAD 2018 and since this version you need to use AcDimXNN.dll

You can easy define it and use without  call LoadLibrary and GetProcAddress :

 

enum Acad::ErrorStatus __cdecl acdbEnableDimAssocForEntity(class AcRxClass * cls);
enum Acad::ErrorStatus __cdecl acdbDisableDimAssocForEntity(class AcRxClass * cls);

 

 

Відповідь корисна? Клікніть на "ВПОДОБАЙКУ" цім повідомленням! | Do you find the posts helpful? "LIKE" these posts!
Находите сообщения полезными? Поставьте "НРАВИТСЯ" этим сообщениям!
На ваше запитання відповіли? Натисніть кнопку "ПРИЙНЯТИ РІШЕННЯ" | Have your question been answered successfully? Click "ACCEPT SOLUTION" button.
На ваш вопрос успешно ответили? Нажмите кнопку "УТВЕРДИТЬ РЕШЕНИЕ"


Alexander Rivilis / Александр Ривилис / Олександр Рівіліс
Programmer & Teacher & Helper / Программист - Учитель - Помощник / Програміст - вчитель - помічник
Facebook | Twitter | LinkedIn
Expert Elite Member