PDA

View Full Version : dos - file batch


icoborg
04-12-2008, 17:02
io uso winrar per dos.
spesso uso sempre lo stessa sequenza di comandi per comprimere o splittare file.
non ricordo come poter farmi chiedere il nome di origine che so d:\asd.avi
e quello obiettivo d:\asd.rar

ex eseguendo prova.bat esca fuori

file origine da comprimere ?:

nome file :?

^TiGeRShArK^
04-12-2008, 17:07
basta che in un file batch usi questa sintassi:

comando %1 %2

in questo modo basta che scrivi il nome del .bat seguito da sorgente e destinazione e il comando corrispondente verrā eseguito passandogli i due nomi dei file.
Per fare esattamente quello che chiedi tu era stato introdotto il comando choice a partire dal dos 6, ma secondo me č molto + comodo scrivere direttamente il nome del batch + i due file in questo caso :p

icoborg
04-12-2008, 17:10
basta che in un file batch usi questa sintassi:

comando %1 %2

in questo modo basta che scrivi il nome del .bat seguito da sorgente e destinazione e il comando corrispondente verrā eseguito passandogli i due nomi dei file.
Per fare esattamente quello che chiedi tu era stato introdotto il comando choice a partire dal dos 6, ma secondo me č molto + comodo scrivere direttamente il nome del batch + i due file in questo caso :p

sisi meglio ancora cosi figurati...era per far capire quello che intendevo

Hardware Upgrade Forum Database Error
Database Error Database error
The Hardware Upgrade Forum database has encountered a problem.

Please try the following:
  • Load the page again by clicking the Refresh button in your web browser.
  • Open the www.hwupgrade.it home page, then try to open another page.
  • Click the Back button to try another link.
The www.hwupgrade.it forum technical staff have been notified of the error, though you may contact them if the problem persists.
 
We apologise for any inconvenience.