Creating a folder

For questions regarding programming in the EViews programming language.

Moderators: EViews Gareth, EViews Moderator, EViews Jason, EViews Matt

PMaier
Posts: 36
Joined: Sat Sep 11, 2010 10:12 am

Creating a folder

Postby PMaier » Tue May 01, 2012 2:16 pm

Hi,

I would like to use the shell command to create a folder, but pass the name of the folder using a string. E.g something like this:

Code: Select all

logmode logmsg %test = "c:\Test" logmsg %test shell mkdir %test
Alas, it does not work ("Unable to create process: The directory name is invalid in "SHELL MKDIR C:\TEST"."). Any ideas why?

Thanks, Philipp

PS I'm using Eviews 7.2.

EViews Gareth
Fe ddaethom, fe welon, fe amcangyfrifon
Posts: 13600
Joined: Tue Sep 16, 2008 5:38 pm

Creating a folder

Postby EViews Gareth » Tue May 01, 2012 2:30 pm

Did you try:

Code: Select all

logmode logmsg %test = "c:\Test" logmsg %test shell mkdir {%test}

PMaier
Posts: 36
Joined: Sat Sep 11, 2010 10:12 am

Re: Creating a folder

Postby PMaier » Wed May 02, 2012 5:04 am

I did. It doesn't work either. :-(

EViews Gareth
Fe ddaethom, fe welon, fe amcangyfrifon
Posts: 13600
Joined: Tue Sep 16, 2008 5:38 pm

Re: Creating a folder

Postby EViews Gareth » Wed May 02, 2012 11:02 am

Did you run that exact same code, and do you have permissions to create a directory in the root of c:?

I just ran both versions, and both successfully create the test folder.

PMaier
Posts: 36
Joined: Sat Sep 11, 2010 10:12 am

Re: Creating a folder

Postby PMaier » Wed May 02, 2012 11:33 am

Yes,

I ran exactly that code. I can manually create a folder c:\test, I can do it from the Windows command prompt, but not using the shell command.

Strange. Not the end of the world, but strange.

Oh well,

Philipp

etienne
Posts: 19
Joined: Wed Jun 12, 2013 10:32 am

Re: Creating a folder

Postby etienne » Fri Dec 06, 2013 8:59 am

Hi,

I have about the same problem since a couple of days. The "shell" command does't work anymore on my computer, though it does on my colleagues' ones, which share the same OS, software versions, privileges, etc. It used to work, I've been using it in a few programs since many months, and it still worked last week. No new software, config, or permissions change or other change I'm aware of on my computer. Of course, first thing I tried was to reboot, no success.

Whatever the exact shell command I use, for example the simple "shell dir", it returns something like : "Unable to create process: Le nom du répertoire est incorrect." Which means : "Unable to create process: The directory name is incorrect."

The similar "system" command in R on my computer works OK as before, nothing seems to have changed.

It's like EViews can't find anymore where is the cmd executable to launch. Could there be an EViews config file that became corrupt? Any ideas how I could fix it? Should EViews be re-installed on my computer?

Windows XP SP3, EViews 8 Enterprise Edition - Jun 13 2013 build

Best regards,

Étienne

EViews Gareth
Fe ddaethom, fe welon, fe amcangyfrifon
Posts: 13600
Joined: Tue Sep 16, 2008 5:38 pm

Re: Creating a folder

Postby EViews Gareth » Fri Dec 06, 2013 9:22 am

Your default directory in EViews is probably corrupt (most likely the directory has been deleted, or doesn't exist on the network any more). Change your default directory.

etienne
Posts: 19
Joined: Wed Jun 12, 2013 10:32 am

Re: Creating a folder

Postby etienne » Fri Dec 06, 2013 10:12 am

That was it!

Thanks!

Étienne


Return to “Programming”

Who is online

Users browsing this forum: No registered users and 2 guests