Search found 761 matches

by teadrinker
Yesterday, 13:10
Forum: Ask For Help
Topic: Best way to get download folder path
Replies: 26
Views: 793

Re: Best way to get download folder path

Let's wait for @lexikos to say.
by teadrinker
Yesterday, 12:56
Forum: Ask For Help
Topic: Best way to get download folder path
Replies: 26
Views: 793

Re: Best way to get download folder path

Summary: On Windows 7 after deleting HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders\{374DE290-123F-4565-9164-39C4925E467B} both codes show blank value, on Windows 10 both codes show default downloads folder path (for me it's wrong). FOLDERID_Downloads := "{374DE290-123F-4...
by teadrinker
Yesterday, 11:29
Forum: Ask For Help
Topic: Best way to get download folder path
Replies: 26
Views: 793

Re: Best way to get download folder path

I should say that my downloads folder is not located in the default directory.
I'll try on Windows 10 later.
by teadrinker
Yesterday, 11:20
Forum: Ask For Help
Topic: Best way to get download folder path
Replies: 26
Views: 793

Re: Best way to get download folder path

But for me this code stops working after deleting that key, on Windows 7.
by teadrinker
Yesterday, 10:59
Forum: Ask For Help
Topic: Best way to get download folder path
Replies: 26
Views: 793

Re: Best way to get download folder path

lexikos wrote: Your most recent addition is better.
It seems that the code

Code: Select all

MsgBox % ComObjCreate("Shell.Application").NameSpace("shell:downloads").self.path
gets the value just from that key. @tmplinshi, try launch it.
by teadrinker
Yesterday, 08:09
Forum: Ask For Help
Topic: Best way to get download folder path
Replies: 26
Views: 793

Re: Best way to get download folder path

@lexicos
Could you give a short explanation, what is wrong with reading that value from the registry? Since the article you mention was written in 2003 and that key still exists, the probability that it will disappear in the near future is 0, isn't it?
by teadrinker
19 Jul 2019, 01:00
Forum: Ask For Help
Topic: Gui support for webp image format Topic is solved
Replies: 15
Views: 950

Re: Gui support for webp image format Topic is solved

Just for fun, the code in attachment (since it is too large) will work without any dll and libraries at all.
by teadrinker
18 Jul 2019, 20:04
Forum: Ask For Help
Topic: Gui support for webp image format Topic is solved
Replies: 15
Views: 950

Re: Gui support for webp image format Topic is solved

tmplinshi , interesting! Managed to decode webp without external ahk-libraries: webpUrl := "https://upload.wikimedia.org/wikipedia/commons/b/b2/Vulphere_WebP_OTAGROOVE_demonstration_2.webp" libwebp32Url := "https://s3.amazonaws.com/resizer-dynamic-downloads/webp/0.5.2/x86/libwebp.dll" libwebp64Url ...
by teadrinker
18 Jul 2019, 11:56
Forum: Ask For Help
Topic: Send Keystrokes to Desktop On Startup
Replies: 3
Views: 120

Re: Send Keystrokes to Desktop On Startup

Why TaskBarHider? To hide the taskbar launch this: HideShowTaskbar(true) HideShowTaskbar(action) { static ABM_SETSTATE := 0xA, ABS_AUTOHIDE := 0x1, ABS_ALWAYSONTOP := 0x2 VarSetCapacity(APPBARDATA, size := 2*A_PtrSize + 2*4 + 16 + A_PtrSize, 0) NumPut(size, APPBARDATA), NumPut(WinExist("ahk_class Sh...
by teadrinker
18 Jul 2019, 04:53
Forum: Ask For Help
Topic: Open Folder and Close if already open
Replies: 11
Views: 469

Re: Open Folder and Close if already open

Right, thanks.
by teadrinker
18 Jul 2019, 04:30
Forum: Ask For Help
Topic: Open Folder and Close if already open
Replies: 11
Views: 469

Re: Open Folder and Close if already open

@jeeswg
Is RTrim really needed?

Code: Select all

for window in ComObjCreate("Shell.Application").Windows
   MsgBox, % window.Document.Folder.Self.Path
by teadrinker
17 Jul 2019, 10:58
Forum: Ask For Help
Topic: HttpQuery function not working and showing empty msgbox, while it should show html codes of page?
Replies: 10
Views: 715

Re: HttpQuery function not working and showing empty msgbox, while it should show html codes of page?

This is some info that the server needs to determine what kind of data we sent, what to do with it and what the response we expect to receive.
Read more here.
by teadrinker
17 Jul 2019, 05:42
Forum: Ask For Help
Topic: how can I clear all variables?
Replies: 4
Views: 263

Re: how can I clear all variables?

test1 := 1 test2 := 1 test3 := [1] CleanGlobalVars() MsgBox, % "test1: " . test1 . "`n" . "test2: " . test2 . "`n" . "test3[1]: " . test3[1] CleanGlobalVars() { varsInfo := ScriptInfo("ListVars") RegExMatch(varsInfo, "s)Global Variables \(alphabetical\)\R-+\R\K.*", vars) Loop, parse, % vars, `n, `r...
by teadrinker
16 Jul 2019, 13:01
Forum: Ask For Help
Topic: HttpQuery function not working and showing empty msgbox, while it should show html codes of page?
Replies: 10
Views: 715

Re: HttpQuery function not working and showing empty msgbox, while it should show html codes of page?

Sorry, I have not been interested in that topic, can't say anything. How about to ask @Joe Glines? :)
by teadrinker
16 Jul 2019, 08:17
Forum: Ask For Help
Topic: File text array to actual array?
Replies: 4
Views: 181

Re: File text array to actual array?

Another approach: JSON = [{"container":{"spec1":"this is spec 1", "spec2":"this is spec2"}}] arr := JsonToAhkObj(JSON) MsgBox, % arr[1].container.spec2 JsonToAhkObj(json, flag := "") { static doc, JS := JsonToAhkObj("") if (json = "") { doc := ComObjCreate("htmlfile") doc.write("<meta http-equiv=""X...
by teadrinker
15 Jul 2019, 18:53
Forum: Ask For Help
Topic: Make tab active Topic is solved
Replies: 6
Views: 435

Re: Make tab active Topic is solved

You could also try this: SetBatchLines, -1 if !hWndFF := WinExist("ahk_class MozillaWindowClass ahk_exe firefox.exe") throw Exception("Firefox window not found") accFF := AccObjectFromWindow(hWndFF, OBJID_CLIENT := 0xFFFFFFFC) if !IsObject(accFF) throw Exception("Failed to get the accessible object"...
by teadrinker
15 Jul 2019, 09:00
Forum: Ask For Help
Topic: Screen capture - Selected area
Replies: 5
Views: 383

Re: Screen capture - Selected area

You can try the following code to select an area on the screen, see it in the GUI, and save it to a file. Press Ctrl + X to select an area. Press Esc to exit. #NoEnv SetBatchLines, -1 Return Esc:: ExitApp ^X:: StartSelection() { Hotkey, LButton, Select, On ReplaceSystemCursors("IDC_CROSS") } Select(...
by teadrinker
14 Jul 2019, 16:31
Forum: Ask For Help
Topic: HttpQuery function not working and showing empty msgbox, while it should show html codes of page?
Replies: 10
Views: 715

Re: HttpQuery function not working and showing empty msgbox, while it should show html codes of page?

The POST request is used in cases, when you need to send to the server some data, such as a file, JSON string or password/login. Unfortunately, there is no simple example to demonstrate this. The following code sends an image file to imgur.com and receives a JSON string that contains the identifier ...
by teadrinker
14 Jul 2019, 10:41
Forum: Ask For Help
Topic: HttpQuery function not working and showing empty msgbox, while it should show html codes of page?
Replies: 10
Views: 715

Re: HttpQuery function not working and showing empty msgbox, while it should show html codes of page?

As i want to make a POST request in https://cmyip.com/ then what should i do? The type of the request is here: whr.Open(" GET ", url, false) , so if you want to sent POST request, specify: whr.Open(" POST ", url, false) , but in this case you don't need it. As I want to search this ip address - 169...
by teadrinker
14 Jul 2019, 07:07
Forum: Ask For Help
Topic: HttpQuery function not working and showing empty msgbox, while it should show html codes of page?
Replies: 10
Views: 715

Re: HttpQuery function not working and showing empty msgbox, while it should show html codes of page?

Sabestian Caine The library you use is very-very outdated, just don't use it. You could using something like this instead: url := "https://cmyip.com/" whr := ComObjCreate("WinHttp.WinHttpRequest.5.1") whr.Open("GET", url, false) whr.Send() MsgBox, % html := whr.ResponseText RegExMatch(html, "(\d+\....

Go to advanced search