Page 1 of 1

Using API functions in parallel rouitne

Posted: Wed Mar 21, 2007 1:54 pm
by umamahes
HI,

can any one help me how to write a c++ routine using api functions in parallel job.i wrote the code like below

#include <dsapi.h>
DSPROJECT DSOpenProject(
char *ProjectName
);
DSJOB DSOpenJob(
DSPROJECT ProjectHandle,
char *JobName
);
int DSGetJobInfo(
DSJOB JobHandle,
int InfoType,
DSJOBINFO *ReturnInfo
);

when i compiled this code i am getting the fowlling error

"dsApi.C", line 1.10: 1540-0836 (S) The #include file <dsapi.h> is not found.
make: 1254-004 The error code from the last command is 1.

Re: Using API functions in parallel rouitne

Posted: Wed Mar 21, 2007 2:12 pm
by ganesh123
umamahes wrote:
#include <dsapi.h>

when i compiled this code i am getting the fowlling error

"dsApi.C", line 1.10: 1540-0836 (S) The #include file <dsapi.h> is not found.
make: 1254-004 The error code from the last command is 1.
Not sure but may be $INCLUDE DSINCLUDE DSAPI.H

Posted: Wed Mar 21, 2007 6:25 pm
by ray.wurlod
dsapi.h is in the $DSHOME/dsdk/include directory

Re: Using API functions in parallel rouitne

Posted: Wed Mar 21, 2007 7:39 pm
by clj242021
umamahes wrote: "dsApi.C", line 1.10: 1540-0836 (S) The #include file <dsapi.h> is not found.
make: 1254-004 The error code from the last command is 1.
If you write a c++ routine using api functions ,you must use "dsapi.h" and
"vmdsapi.so"
dsapi.h is located in the directory $DSHOME/include
vmdsapi.so is located in the directory $DSHOME/lib

Re: Using API functions in parallel rouitne

Posted: Wed Mar 21, 2007 7:45 pm
by clj242021
umamahes wrote: "dsApi.C", line 1.10: 1540-0836 (S) The #include file <dsapi.h> is not found.
make: 1254-004 The error code from the last command is 1.
note:you must use correct parameter to compile the *.C ,otherwise DS can't execute the routine

HI

Posted: Wed Mar 21, 2007 8:05 pm
by umamahes
How can i give the path in the c++ code.

can you please give me an example with the code i have posted

Thaks
Uma

Re: HI

Posted: Thu Mar 22, 2007 2:05 am
by clj242021
umamahes wrote:How can i give the path in the c++ code.

can you please give me an example with the code i have posted

Thaks
Uma
copy the "dsapi.h" to you *.C directory