elhacker.net cabecera Bienvenido(a), Visitante. Por favor Ingresar o Registrarse
¿Perdiste tu email de activación?.

 

 


Tema destacado: Como proteger una cartera - billetera de Bitcoin


+  Foro de elhacker.net
|-+  Programación
| |-+  Scripting
| | |-+  Varias dudas con Batch
0 Usuarios y 1 Visitante están viendo este tema.
Páginas: [1] Ir Abajo Respuesta Imprimir
Autor Tema: Varias dudas con Batch  (Leído 2,795 veces)
.......................................

Desconectado Desconectado

Mensajes: 83


Apaga la TV y enciende tu mente


Ver Perfil
Varias dudas con Batch
« en: 26 Marzo 2007, 23:11 pm »

Buenas, alguien me podria explicar lo que dice aqui sobre la linea que sigue a echo off?

:a.bat
::
@ECHO OFF

c:

It is used as a separator between the title and the file itself. Although they do not affect the running, or contribute to the mis-running, of the batch file, they should be used here because DOS will display an unnecessary prompt on the screen for any blank line before an "ECHO OFF" command.


Otra cosa me podeis explicar que dice aqui sobre la line de despues de :a.bat?
It is used as a separator between the title and the file itself. Although they do not affect the running, or contribute to the mis-running, of the batch file, they should be used here because DOS will display an unnecessary prompt on the screen for any blank line before an "ECHO OFF" command.

Y finalmente esta explicacion que habla sobre la linea @echo off

The fourth line is required to tell DOS not to display the succeeding lines on the screen, and the "@" symbol tells DOS not to show the line itself. The first command in typical batch files usually is "ECHO OFF". "Echo" means that the keys struck on the keyboard are "echoed" (displayed) on the screen. Since a batch file is just a series of commands, what is typed in the file would be echoed on the screen as DOS executes each of those lines, just as though you were typing each instruction at the command line. However, in most cases, the user is only interested in the end result and does not need to see everything that DOS is doing. Using the "Echo Off" command means each command issued by the file as it works toward completing the requested task will not appear on the screen. Again, if you wish even that line to be hidden, add the "at" sign ( @ ) before it, as in the example above.

Tambien me gustaria saber si al poner este comando es lo mismo que poner CD WP60:

CD\WP60

Otra pregunta, es lo mismo poner start programa.exe que programa? y si solo pones programa solo acepta exes y bats no?

Gracias y saludos.


« Última modificación: 26 Marzo 2007, 23:21 pm por seibur » En línea

Kefren


Desconectado Desconectado

Mensajes: 515


0x1BADB002


Ver Perfil WWW
Re: Varias dudas con Batch
« Respuesta #1 en: 27 Marzo 2007, 00:32 am »

SaluDOS

Pues con respecto a lo primero, la verdad es que no tengo ni idea porque mi nivel de ingles deja mucho que desear...

Citar
Tambien me gustaria saber si al poner este comando es lo mismo que poner CD WP60:

CD\WP60

Pues te puedo decir que no funciona y lo ultimo...

Citar
es lo mismo poner start programa.exe que programa? y si solo pones programa solo acepta exes y bats no?

Pues si, es lo mismo, puedes poner por ejemplo:

Código:
start archivo.txt

o:

Código:
archivo.txt

Ambas son buenas, las dos abriran el archivo con el Bloc de Notas o con el programa que tengas asignado a la extensión .txt

SaluDOS


En línea

Visita mi blog -> The Bit Developer
sirdarckcat
Aspirante a supervillano
Colaborador
***
Desconectado Desconectado

Mensajes: 7.029


No estoy loco, soy mentalmente divergente


Ver Perfil WWW
Re: Varias dudas con Batch
« Respuesta #2 en: 27 Marzo 2007, 02:31 am »

:a.bat
no sirve de nada

::
no sirve de nada..

@echo off
apaga el "prompt" (solo se ve lo que sacan los comandos.. no los comandos en si..

cd\WP60 (si estas en c:) te va a mandar a la carpeta: c:\WP60

Saludos!!
En línea

.......................................

Desconectado Desconectado

Mensajes: 83


Apaga la TV y enciende tu mente


Ver Perfil
Re: Varias dudas con Batch
« Respuesta #3 en: 27 Marzo 2007, 22:49 pm »

Me podrias dar un ejemplo de la salida que tiene al hacer echo off comparado con @echo off es que no lo acano de entender.

Gracias.
En línea

sirdarckcat
Aspirante a supervillano
Colaborador
***
Desconectado Desconectado

Mensajes: 7.029


No estoy loco, soy mentalmente divergente


Ver Perfil WWW
Re: Varias dudas con Batch
« Respuesta #4 en: 28 Marzo 2007, 01:13 am »

ok :P
Código:
echo off
echo HOLA MUNDO
saca:
Código:
c:\>echo off
HOLA MUNDO
y

Código:
@echo off
echo HOLA MUNDO

saca:
Código:
Hola mundo

Saludos!!
En línea

Páginas: [1] Ir Arriba Respuesta Imprimir 

Ir a:  

Mensajes similares
Asunto Iniciado por Respuestas Vistas Último mensaje
[Batch] Varias preguntillas...
Scripting
ypsilon 3 3,150 Último mensaje 31 Agosto 2011, 01:15 am
por leogtz
Dudas de batch, cookies y exploradores
Hacking
-r3- 0 1,618 Último mensaje 3 Julio 2012, 02:38 am
por -r3-
varias dudas con código batch y como hacer para saber la ip
Scripting
r7pyrred 2 3,004 Último mensaje 24 Noviembre 2012, 01:06 am
por r7pyrred
[Batch]Dudas sobre Batch
Scripting
No se que Colocar 4 3,333 Último mensaje 16 Agosto 2016, 21:26 pm
por No se que Colocar
[BATCH] Dudas varias
Scripting
baldovi_6 5 2,661 Último mensaje 30 Diciembre 2018, 10:03 am
por baldovi_6
WAP2 - Aviso Legal - Powered by SMF 1.1.21 | SMF © 2006-2008, Simple Machines