[ADMB Users] Running from remote directory
dave fournier
otter at otter-rsch.com
Tue Oct 26 00:17:44 PDT 2010
I think all that is needed is to
add a bit of code to strip off the full path
part in model7.cpp before one strips off the
.exe (windows stuff)
int n=adprogram_name.size();
// strip off the full path to get just the file name
int n1=1;
for (i=adprogram_name.size()-1;i>1;i--)
{
if ( adprogram_name(i)== directory_prefix )
{
n1=i+1;
break;
}
}
// strip off the .exe if it is there
for (i=n1+1;i<=adprogram_name.size()-1;i++)
{
if ( adprogram_name(i)=='.'
&& adprogram_name(i+1) != directory_prefix )
{
n=i-1;
break;
}
}
adprogram_name=adprogram_name(n1,n);
More information about the Users
mailing list