Jump to content











Photo

Grub4dos batch file to list and pick a file


  • Please log in to reply
3 replies to this topic

#1 steve6375

steve6375

    Platinum Member

  • Developer
  • 7566 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films
  •  
    United Kingdom

Posted 05 May 2013 - 09:54 AM

Attached are two grub4dos batch files which you may find useful.

the %grub% variable should be set to the folder where the batch file LstFext.g4b lives - e.g.

 

# set batch file folder
set grub=/
# %1 is folder %2 is extension 
/PickaFile.g4b /MYISOS .ISO
echo %FCOUNT% files found
if "%CHOSEN%"=="0" pause --wait=3 No Files found or User Aborted! && configfile /menu.lst
if "%CHOSEN%"=="" pause --wait=3 User Aborted! && configfile /menu.lst
echo File chosen was %CHOSEN%

This will then list all the .iso files in the /MYISO folder and allow the user to pick from a list

 

 

CHOOSE .ISO FILE

 

(ESC or 0 = Abort)

 

1 = Fred.iso

2 = Doris.iso

3 = Bill.iso

 

Choose a number (1-3) : 2

 

3 files found

File chosen was Doris.iso

 

Feel free to modify them for your own purposes!

Attached Files


  • farhad likes this

#2 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 16066 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 05 May 2013 - 10:09 AM

Attached ...

Where? :unsure:

 

:cheers:

Wonko



#3 steve6375

steve6375

    Platinum Member

  • Developer
  • 7566 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films
  •  
    United Kingdom

Posted 05 May 2013 - 10:19 AM

Whoops! I forgot that bit! It's there now!



#4 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 16066 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 05 May 2013 - 10:31 AM

Whoops! I forgot that bit! It's there now!

Good :thumbsup:

:jaclaz:

 

:cheers:

Wonko






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users