Oct 2, 2008 at 6:19pm UTC
First let me say that I am not a C++ programmer. I dabble a little in VB and a lot in Lisp for AutoCAD. I have a program that was written for me in C++ for AutoCAD and I was trying to recompile it using a newer version of C++ than it was written in and I have several of these errors and I do not have access to the older version of C++.
char kwd [128];
char msg [128];
char prompt [128];
double def;
char ctemp [64];
struct resbuf *rb;
rb = ads_getargs();
strncpy (kwd,rb->resval.rstring,sizeof (kwd) - 1);
strncpy (msg,rb->resval.rstring,sizeof (msg) - 1);
error C2644: cannot convert parameter 2 from 'ACHAR *' to 'const char *'
def = atof (rb->resval.rstring);
error C2644: cannot convert parameter 1 from 'ACHAR *' to 'const char *'
ads_rtos (def,4,4,ctemp);
ads_rtos (def,2,lprec,ctemp);
error C2644: cannot convert parameter 4 from 'char [64]' to 'ACHAR *'
stat = ads_initget (bit,kwd);
stat = ads_getstring (0,prompt,ctemp);
error C2644: cannot convert parameter 2 from 'char [128]' to 'const ACHAR *'
stat = ads_getreal (prompt,&value);
error C2644: cannot convert parameter 1 from 'char [128]' to 'const ACHAR *'
ads_getinput (ctemp);
ads_retstr (ctemp);
error C2644: cannot convert parameter 1 from 'char [64]' to 'const ACHAR *'
ads_rtos (value,2,4,ctemp);
ads_rtos (value,2,2,ctemp);
error C2644: cannot convert parameter 4 from 'char [64]' to 'ACHAR *'
str = rb->resval.rstring;
error C2644: '=': cannot convert from 'ACHAR *' to 'char *'
Like I said. I don't know anything about C++ so any answers need to be clear enough for a dummy.
Thanks.