Messages - wolf.b [ switch to compact view ]

Pages: [1] 2 3 4 5 6 ... 13next
I have a gmail account and checked the first time for mail about 2 1/2 years after opening, and it still worked.



Hi Jim,

thanks for the hints. My response is quite likely much too late, but I wasn't around for a while.

I have tried the environment variable %CD% that you mentioned in a batch file like this:


echo %CD%

The output this batch file creates when called from within the directory where it is stored is as expected:


and the output when called from from the root directory is this:


I noticed that the variable is inconsistent in adding a trailing backslash as the the ending character.

CopyMyFiles.cmd is stored in C:\Scripts
At the command prompt, you change directories to F:\Data
From there you type in the command
The %CD% variable will contain the value F:\Data.

I agree with everything you say, but would you not get the same behaviour when omitting the %CD%\ from your suggested CopyMyFiles.cmd?

copy data.exe c:\windows\system32\data
copy pic.jpg C:\Documents and Settings\Administrator\Desktop

I might have misunderstood the original question, but it seems to me that the question was to find a way to refer to the directory where the batch file is located (USB device?), rather than storing the batch on the hard drive.



Developer's Corner / Re: A little help with an AHK web-browser?
« on: November 22, 2007, 01:39 AM »
Hi wreckedcarzz,

the author (Sean) said something about IEControl.ahk here:

I uploaded the standard library IE.ahk, which can be downloaded from the first post in this thread.
I'll discontinue the support of the old IEControl.ahk, so updated COM.ahk accordingly to be used with IE.ahk.

The mentioned download link is in the first post.

Problem #2: URL bar does not work. I have had success with it, after I removed the quotation marks from this line:

IE_LoadURL(pwb, "AddressBar")

like so:

Gui, Submit, NoHide
IE_LoadURL(pwb, AddressBar)
Gui,2: Hide

Problem #3: I also have the same problem with the Enter key in your example. :(
Confusingly there is this post which states that the problem with the Enter key has been solved by using the mozilla activex control, but I don't understand a word of it. Maybe you can make sense out of it. I think it relates to a AutoHotkey script that, like yours, uses the "library".

Problem #4,5: I don't understand where you want to move the webpage to? sorry

I hope that helps a little


Only today I noticed that there is another question unanswered:

and the line: @echo off, that removes extra spaces right?

It toggles the "default batch echo" state OFF, which is otherwise ON. Now to understand what the default batch echo does, take the following code:

echo on
echo 1
echo 2

echo off
echo 3
echo 4

What happens here is this:
echo on     : this line will switch the echo state ON (unnecessary, it is ON anyway), and put out a message about the new state: ECHO is on
echo 1      : this will put out the string "1"
echo.        : this will put out a empty line
echo 2      : this will put out the string "2"
               : this will put out a prompt (C:\TestCopy\>) or similar
echo off    : this will switch the default batch echo off, and put out a message about the new state: ECHO is off
echo 3      : this will put out the string "3"
echo         : this will put out a message about the state of the default batch echo: ECHO is off
echo 4      : this will put out the string "4"

The output of that batch is very messy. Quite often I want to have empty lines in my code (for structuring) and I don't want to see the prompt echoed to the screen. That is why I have put "echo off" in the first line of the batch file in reply #3. If you remove the "@" sign from that batch you will still see the message "ECHO is off", because when the batch starts, the echo is on, and the first command will create some output. It switches the echo off for all the following lines, not for itself.

The "@" sign in front of any line switches the echo off for that particular line only. So in a batch with only one line you could write:

@for %%f in (myicon.ico, myieshortcut.url) do copy "C:\TestCopy\%%f" "C:\Documents and Settings\All Users\Desktop\TestCopy\datafolder"

and get the same effect (avoid messy output).


Post New Requests Here / Re: IDEA: a Self-Contained Archive
« on: November 19, 2007, 07:24 PM »
Please make an effort to try to find existing programs that do what you are asking for before you post an Idea request; this section is not meant to be a coding excercise, so if the program already exists (as freeware), then there is little point having someone here re-implement it.

I have just found the above here
- DC forums
-- Software
--- Coding Snacks
---- Post New Requests Here
----- Topic: When writing code means you've failed.. READ IN
and would like to ask for guidance, please.

I believe that psionics has been directed to come here, and I am offering a helping hand, but it will be a coding exercise. The functionality of the code is of limited use (even if it is working as laid out), as it only provides a customised front-end to an existing application. Where shall we go with this?


Pages: [1] 2 3 4 5 6 ... 13next
Go to full version