Need help with auto marking

Discussion forum for all Windows batch related topics.

Moderator: DosItHelp

Post Reply
Message
Author
lamera32
Posts: 5
Joined: 27 Dec 2009 16:04

Need help with auto marking

#1 Post by lamera32 » 27 Dec 2009 16:19

Hello my friends, i'm new in this sphere, i have a one question, how *bat file automaticly mark this http://i46.tinypic.com/314thjd.jpg , and copy this marking information in "file1.txt" file
I mind when i click, let's say FILE.bat, to write ipconfig, and mark information from ipconfig, and copy in file1.txt like this ---> "copy con file1.txt"....
Thank you advance, and i sorry for my bad english

!k
Expert
Posts: 378
Joined: 17 Oct 2009 08:30
Location: Russia

#2 Post by !k » 27 Dec 2009 17:16

Code: Select all

ipconfig| findstr :> file1.txt

lamera32
Posts: 5
Joined: 27 Dec 2009 16:04

#3 Post by lamera32 » 28 Dec 2009 05:05

Man i love you, i so thank you for helping, you have a one beer from me!

lamera32
Posts: 5
Joined: 27 Dec 2009 16:04

#4 Post by lamera32 » 28 Dec 2009 05:54

i have one more question this

Code: Select all

@echo off
echo this will send a file
net send (IP to recipient) file1.txt
copy file1.txt
echo file sent
pause

Where send this file, what i change to send on the C:\Documents & Settings\Administrator\Desktop\d

!k
Expert
Posts: 378
Joined: 17 Oct 2009 08:30
Location: Russia

#5 Post by !k » 28 Dec 2009 09:10

May be
copy file1.txt "C:\Documents & Settings\Administrator\Desktop\d"
:?
Folder "d" on Desktop must already exist

lamera32
Posts: 5
Joined: 27 Dec 2009 16:04

#6 Post by lamera32 » 29 Dec 2009 03:53

ok when i write the directory, and let say folder1 --> C:\Documents & Settings\Administrator\Desktop\folder1, this folder alone will be created?

!k
Expert
Posts: 378
Joined: 17 Oct 2009 08:30
Location: Russia

#7 Post by !k » 29 Dec 2009 08:35

No. COPY command can not create folders.
You must create the folder manually;
or the command MKDIR;
or use the XCOPY command

Code: Select all

echo D| xcopy file1.txt "C:\Documents & Settings\Administrator\Desktop\d" /Y

Code: Select all

echo D| xcopy folder1 "C:\Documents & Settings\Administrator\Desktop\folder1" /Y

lamera32
Posts: 5
Joined: 27 Dec 2009 16:04

#8 Post by lamera32 » 04 Jan 2010 17:26

can you write me how the code should look into a fortune, because do not get it all information..?

Post Reply