skill syntax question

R

Rick Mattern

Guest
I am trying to create a script that will work with ADEXL's job
policies and the script needs to build
the command line.

Whats the correct syntax to put the 2 two togther?

This will get the command field

axlGetAttachedJobPolicy()->jobsubmitcommand


and lets say it has the following:
-J newJob

This line will replace the jobsubmitcommand:

axlSetJobPolicyProperty( "ADEXL_mmsim_m" "jobsubmitcommand" "nc run -D
-C mmsim_m_2 " )

I need it to look like this:

axlSetJobPolicyProperty( "ADEXL_mmsim_m" "jobsubmitcommand" "nc run -D
-C mmsim_m_2 -J newJob " )

so how can I put the 2 togther? strcat or something? It looks
like axlSetJobPolicyProperty() will not evaluate any variable .

Thanks
 
On Jul 22, 8:46 pm, Rick Mattern <rmatt...@inphi.com> wrote:
I am trying to create a script that will work with ADEXL's job
policies and the script needs to build
the command line.

Whats the correct syntax to put the 2 two togther?

This will get the command field

axlGetAttachedJobPolicy()->jobsubmitcommand

and lets say it has the following:
-J newJob

This line will replace the jobsubmitcommand:

axlSetJobPolicyProperty( "ADEXL_mmsim_m" "jobsubmitcommand" "nc run -D
-C mmsim_m_2  " )

I need it to look like this:

axlSetJobPolicyProperty( "ADEXL_mmsim_m" "jobsubmitcommand" "nc run -D
-C mmsim_m_2  -J newJob " )

so how can I put the 2 togther?   strcat or something?   It looks
like   axlSetJobPolicyProperty()  will not evaluate any variable .

Thanks
Hi Rick,

I guess that you want something like
axlSetJobPolicyProperty( "ADEXL_mmsim_m" "jobsubmitcommand"
strcat("nc run -D -C mmsim_m_2 " axlGetAttachedJobPolicy()-
jobsubmitcommand))
Eventually first check that axlGetAttachedJobPolicy()-
jobsubmitcommand is not nil, otherway the strcat will fail.
Best Regards,
Marcel
 

Welcome to EDABoard.com

Sponsor

Back
Top