acedCmd for ObjectARX 2015 and 2016

acedCmd for ObjectARX 2015 and 2016

abdulhaseeb114
Contributor Contributor
1,220 Views
4 Replies
Message 1 of 5

acedCmd for ObjectARX 2015 and 2016

abdulhaseeb114
Contributor
Contributor

Hello,

 

my below coding for ObjectARX 2014 is working well,

 

const resbuf *cmdlist;
cmdlist = acutBuildList(RTSTR, _T("_QSAVE"), 0);
acedCmd(cmdlist);

 

but I need the same to be work with my ObjectARX 2015 and 2016.

 

Please help me.

0 Likes
Accepted solutions (1)
1,221 Views
4 Replies
Replies (4)
Message 2 of 5

Alexander.Rivilis
Mentor
Mentor
Accepted solution

What about this code:

 

 

#include "acedCmdNF.h"
//....
acedCommandS(RTSTR, _T("_QSAVE"), 0);

?

 

Відповідь корисна? Клікніть на "ВПОДОБАЙКУ" цім повідомленням! | 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

0 Likes
Message 3 of 5

abdulhaseeb114
Contributor
Contributor

Thanks For your help this Working good.....

0 Likes
Message 4 of 5

tbrammer
Advisor
Advisor

Just some notes:

  1. You can replace acedCmd(cmdlist) by acedCmdS(cmdlist) as well.
  2. You should read the section "acedCommand Migration" in <ObjectARX 2015>\docs\readarx.chm.
    Using acedCmdS() and acedCommandS() is fine if your command is passed completely to the call - like in your case. Otherwise you have to use acedCommandC() / acedCmdC() which is quite hard to understand and implement. Better get rid of those acedCommand() calls!
  3. Be aware that your code won't compile under ARX 2014 and earlier if you simply change to the "S-versions". To solve this problem you can put the following #define statements into stdafx.h:
#if ACADVER < 20 
    //ARX 2014 and earlier (ACADVER is a preprocessor definition that I set in each project configuration)
    #define acedCommandS acedCommand
    #define acedCmdS acedCmd
#endif

 


Thomas Brammer ● Software Developer ● imos AGLinkedIn
If an answer solves your problem please [ACCEPT SOLUTION]. Otherwise explain why not.

Message 5 of 5

swaywood
Collaborator
Collaborator

Your answer is helpful, thanks so much.

0 Likes