relative paths in *.bat file for extras ?

I want to show you what I'm doing some evenings in my spare time.
At first I want to say that this is ONLY A PRIVATE HOBBY PROJECT, I don't want to "kill" eCC, But eventually wake up Andreas a bit ;-)

Moderator: DerMicha75

User avatar
Vicman
PLATINUM member
Posts: 1233
Joined: 17 Jun 2007, 16:12
Location: Germany,Bochum

relative paths in *.bat file for extras ?

Unread post by Vicman » 15 Nov 2014, 07:49

Hi Micha, Sebastiaan & Co,

i want to put some extras in ECC2 as *.bat file.

In Example :

I put a pdf file to the folder-structure :
E:\ECC2\user\vic20\extras\000_books\COMPUTE!'s_First_Book_of_VIC_Games.pdf

The *.bat files are stored in ECC2 for example in :
E:\ECC2\user\vic20\extras\E3\E3831C38\vic20_E3831C38_guide_1[COMPUTE!'s First Book of VIC Games].bat

This is the *.bat i use for this :
"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" e:\ECC2\user\vic20\extras\000_books\COMPUTE!'s_First_Book_of_VIC_Games.pdf

It works for me....but :
not all users have ecc2 on E:\ or acrobat reader in the same folder.....

So my Question :
what is the correct *.bat command to use relative path to open the pdf on each PC ?

I found this, but don't know how to use it correctly :
Spoiler: show
You can get all the required file properties by using the code below:

FOR %%? IN (file_to_be_queried) DO (
ECHO File Name Only : %%~n?
ECHO File Extension : %%~x?
ECHO Name in 8.3 notation : %%~sn?
ECHO File Attributes : %%~a?
ECHO Located on Drive : %%~d?
ECHO File Size : %%~z?
ECHO Last-Modified Date : %%~t?
ECHO Parent Folder : %%~dp?
ECHO Fully Qualified Path : %%~f?
ECHO FQP in 8.3 notation : %%~sf?
ECHO Location in the PATH : %%~dp$PATH:?
)
EDIT :
O.K this bat works also for me......but still the problem with relative path for ECC2....
start "AcroRd32.exe" /b e:\ECC2\user\vic20\extras\000_books\COMPUTE!'s_First_Book_of_VIC_Games.pdf

mhh....it works also as *.bat,if i don't use e:
So, is this the solution for all users ?
start "AcroRd32.exe" /b \ECC2\user\vic20\extras\000_books\COMPUTE!'s_First_Book_of_VIC_Games.pdf

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest