Reputation: 115
How can use Tcl command in windows-7 ? I want to copy one file to other locaiton using a .bat file.
Upvotes: 0
Views: 965
Reputation: 137567
How can use Tcl command in windows-7 ?
Windows (of all versions) has never come with a Tcl interpreter pre-installed, By far the simplest way is to get a copy of ActiveTcl installed.
Once you've got that installed, either run it interactively and just type your Tcl command in at the prompt, or use a text editor (like Notepad) to make a file (conventionally with extension .tcl
) that contains the command or commands to execute; you'll probably be able to make the file run by just double-clicking on it.
I want to copy one file to other locaiton using a .bat file.
That's not really got much to do with Tcl. With Tcl, you would use:
file copy {C:\Where\To\Copy\From.txt} {C:\Where\To\Copy.to}
Note, we've put the filenames in {
curly braces}
here so that we can use backslashes; if we weren't doing that, we'd need to use double-backslashes instead (\\
) or forward slashes (/
).
The alternative, if you're really wanting to use a .bat
file, is to look up what the cmd.exe commands COPY
and (less likely) XCOPY
do. But that's not a Tcl question.
Upvotes: 2