Hi
I wanted to write the following line in a program:
%typ="Ndc2_11"
include "creationmodux2010_{%typ}.prg"
Why would that not work? Is there an way to run different programs according to the value of a string variable?
Thank you very much for your kind help
Yours sincerely
Ferdy Adam
include + string var.
Moderators: EViews Gareth, EViews Jason, EViews Moderator, EViews Matt
Re: include + string var.
Have you tried the following?:
Code: Select all
%typ="Ndc2_11"
exec creationmodux2010_{%typ}
-
- Posts: 4
- Joined: Mon May 16, 2011 12:19 am
Re: include + string var.
thanks for that suggestion
i'm not used to usind the exec command
your suggestion actually does not work but this works:
%typ="g:\data\adam\modux\archivesModeles\prevision\Prevision2010\programs\lecturetransfdonnees2010_Ndc2_11.prg"
exec {%typ}
hence i have to specify to whole path but i can construct it from different string elements, which is what i wanted to do.
best regards
ferdy
i'm not used to usind the exec command
your suggestion actually does not work but this works:
%typ="g:\data\adam\modux\archivesModeles\prevision\Prevision2010\programs\lecturetransfdonnees2010_Ndc2_11.prg"
exec {%typ}
hence i have to specify to whole path but i can construct it from different string elements, which is what i wanted to do.
best regards
ferdy
Who is online
Users browsing this forum: No registered users and 34 guests