How to retrieve the full adress of a selected file form the Windows File Manager

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
User avatar
mikeyww
Posts: 26602
Joined: 09 Sep 2014, 18:38

Re: How to retrieve the full adress of a selected file form the Windows File Manager

Post by mikeyww » 28 Nov 2021, 21:15

I suggest a separate post (thread) for each subject.

Here is the monitor.

Code: Select all

For objItem in ComObjGet("winmgmts:").ExecQuery("SELECT * FROM Win32_DisplayConfiguration")
 monitor := Trim(objItem["DeviceName"])
MsgBox, 64, Monitor, %monitor%

Lepes
Posts: 141
Joined: 06 May 2021, 07:32
Location: Spain

Re: How to retrieve the full adress of a selected file form the Windows File Manager

Post by Lepes » 29 Nov 2021, 01:12

Offtopic:
ctrl + 1 to ctrl + 0 are assigned to show favorites programs on FreeCommander by default, although you have nothing on Favorites slots.
Go to Extras Menu, Assign shortcuts menuitem ( the icon is a keyboard, I'm sorry I have spanish language on FreeCommander) and delete those shortcuts, then, you can use with autohotkey.

Nicolas25
Posts: 39
Joined: 22 Oct 2021, 09:17

Re: How to retrieve the full adress of a selected file form the Windows File Manager

Post by Nicolas25 » 29 Nov 2021, 11:39

Thank you very much for your answers.

Best regards,

Nicolas.

Nicolas25
Posts: 39
Joined: 22 Oct 2021, 09:17

Re: How to retrieve the full adress of a selected file form the Windows File Manager

Post by Nicolas25 » 03 Dec 2021, 05:18

Hello,

I use the same computer, but with two different monitors (screens): one screen at home and one one at the office.

The screen dpi is different on the two nonitors. My program AHK need to be a little different, depending the monitor used:

For this, I need to put an "if" to control the screen DPI:

Code: Select all

DPI := A_ScreenDPI

if (%DPI% = %192%)
{
msgbox, The screen Dpi is 192
}

This works good and the Msgbox open.

But if I put the following code, the Msgbox open also (and this is not normal) !!!


Code: Select all

DPI := A_ScreenDPI

if (%DPI% = %11111%)
{
msgbox, The screen Dpi is 192
}
Why ? What is my mistake ?

Thank you very much in advance for your kind help.

Best regards,

Nicolas
[/b]

gregster
Posts: 8921
Joined: 30 Sep 2013, 06:48

Re: How to retrieve the full adress of a selected file form the Windows File Manager

Post by gregster » 03 Dec 2021, 06:07

Wrong if-syntax. In expression syntax, variable names don't get %-ed (as long as you are not doing a double-deref; and numbers shouldn't be put between %s anyways, as long as they are not variable names - and you really shouldn't use numbers as variable names)

Code: Select all

if (DPI = 192)

Nicolas25
Posts: 39
Joined: 22 Oct 2021, 09:17

Re: How to retrieve the full adress of a selected file form the Windows File Manager

Post by Nicolas25 » 03 Dec 2021, 10:25

Thank you very much for your help and explanation. It's just what I needed.

I wish you a good week-end.

Nicolas

Post Reply

Return to “Ask for Help (v1)”