Search found 45 matches
- 06 Jun 2018, 15:44
- Forum: Ask for Help (v1)
- Topic: Loading JSON response? Topic is solved
- Replies: 6
- Views: 1739
Re: Loading JSON response? Topic is solved
If you don't include Coco's library correctly, you will see only one empty msgbox with the code above. So, what means "doesn't work as I've written it" and "exactly same results as before" ? How does the string look that you get from the API? With single quotation marks? Well, you might have to cha...
- 06 Jun 2018, 15:22
- Forum: Ask for Help (v1)
- Topic: Loading JSON response? Topic is solved
- Replies: 6
- Views: 1739
Re: Loading JSON response? Topic is solved
You should use double quotation marks for strings in Autohotkey, not single ones - the latter ones have no special meaning in Autohotkey, afaik. But to use literal " s in a string within an expression, use two "" quotation marks in a row as an escape sequence : Within an expression, two consecutive...
- 06 Jun 2018, 14:41
- Forum: Ask for Help (v1)
- Topic: Loading JSON response? Topic is solved
- Replies: 6
- Views: 1739
Loading JSON response? Topic is solved
Ok, forgive me if my brain is fried today & this is obvious, but I'm back... I call an API with a function & receive a dictionary as a result. I want to call one of the keys of that dictionary. Researching it, I find this awesome library: https://autohotkey.com/boards/viewtopic.php?t=627 and load it...
- 06 Jun 2018, 13:33
- Forum: Ask for Help (v1)
- Topic: Datatypes in AHK?
- Replies: 5
- Views: 1785
Re: Datatypes in AHK?
= and := are different when assigning variables. payload = {"k": "v"} ; This is a string MsgBox % payload ; ==> {"k": "v"} payload := {"k": "v"} ; This is an object MsgBox % payload ; ==> MsgBox % payload.k ; ==> v Write your object like this: payload := {} ; Create an empty object payload.original...
- 06 Jun 2018, 13:32
- Forum: Ask for Help (v1)
- Topic: Datatypes in AHK?
- Replies: 5
- Views: 1785
Re: Datatypes in AHK?
what even is going on here? in the first instance youre passing an Associative Array(dictionary, if u like), which is of type 'Object' in the second instance youre passing something made to look like an associative array, which is of type 'String' createShortLink(url, payload) presumably expects an...
- 06 Jun 2018, 12:35
- Forum: Ask for Help (v1)
- Topic: Datatypes in AHK?
- Replies: 5
- Views: 1785
Datatypes in AHK?
If autohotkey doesn't have explicit datatypes, then I'm having a very hard time understanding why something is failing... I've created a function calls an API & which works perfectly when I call it explicitly: createShortlink("http://localhost:82/build", {"original_url": "http://autohotkey.com", "re...
- 06 Jun 2018, 10:39
- Forum: Ask for Help (v1)
- Topic: POST request to non-authorized API Topic is solved
- Replies: 6
- Views: 2488
Re: POST request to non-authorized API Topic is solved
ok, this should work: Require CreateFormData objParam := {"original_url": "http://autohotkey.com", "response_type": "json"} CreateFormData(body, hdr_ContentType, objParam) WinHTTP := ComObjCreate("WinHTTP.WinHttpRequest.5.1") WinHTTP.Open("POST", "http://mysite.com/build") WinHTTP.SetRequestHeader(...
- 06 Jun 2018, 08:03
- Forum: Ask for Help (v1)
- Topic: POST request to non-authorized API Topic is solved
- Replies: 6
- Views: 2488
Re: POST request to non-authorized API Topic is solved
try: Body := "{""original_url"":""http://autohotkey.com"",""response_type"":""json""}" Solid theory which I had not considered, but no luck. Edit responding to your edit: WinHTTP := ComObjCreate("WinHTTP.WinHttpRequest.5.1") WinHTTP.Open("POST", "http://mysite.com/build") Body := "original_url=http...
- 06 Jun 2018, 07:43
- Forum: Ask for Help (v1)
- Topic: POST request to non-authorized API Topic is solved
- Replies: 6
- Views: 2488
POST request to non-authorized API Topic is solved
I researched first & came across this link where Jackie Sztuk _Blackholyman gives someone else the answer I was looking for. However when I tested it myself, it didn't work. My AHK code looks like this: WinHTTP := ComObjCreate("WinHTTP.WinHttpRequest.5.1") WinHTTP.Open("POST", "http://mysite.com/bui...
- 01 Dec 2017, 11:49
- Forum: Ask for Help (v1)
- Topic: ScreenCapture isn't working for me. Obsolete? Topic is solved
- Replies: 2
- Views: 992
Re: ScreenCapture isn't working for me. Obsolete? Topic is solved
Thank you. Works perfectly now
- 01 Dec 2017, 11:28
- Forum: Ask for Help (v1)
- Topic: ScreenCapture isn't working for me. Obsolete? Topic is solved
- Replies: 2
- Views: 992
ScreenCapture isn't working for me. Obsolete? Topic is solved
Following this thread , I've copied the ScreenCapture function posted by poo_noo. I then used the command engunneer posted (modified slightly) and obviously both AHKs are in the same folder. #include ScreenCapture.ahk out := A_Desktop . "\test.bmp" MsgBox, % out CaptureScreen(0, false, out) return ...
- 28 Sep 2017, 14:44
- Forum: Ask for Help (v1)
- Topic: Will paypal $30 to whoever helps me successfully connect to PGSQL with ADO
- Replies: 4
- Views: 1629
Re: Will paypal $30 to whoever helps me successfully connect to PGSQL with ADO
Absolutely amazing! I can't thank you enough. I'll DM you requesting your Paypal e-mail. If qwerty12 is so generous solving your request for free (btw, thx 4 that. Much appreciated :thumbup: ) why not think about to sponsor AHK's foundation instead?! https://autohotkey.com/foundation/#contributions...
- 27 Sep 2017, 23:50
- Forum: Ask for Help (v1)
- Topic: Will paypal $30 to whoever helps me successfully connect to PGSQL with ADO
- Replies: 4
- Views: 1629
Re: Will paypal $30 to whoever helps me successfully connect to PGSQL with ADO
Absolutely amazing! I can't thank you enough. I'll DM you requesting your Paypal e-mail.
- 27 Sep 2017, 20:48
- Forum: Ask for Help (v1)
- Topic: Will paypal $30 to whoever helps me successfully connect to PGSQL with ADO
- Replies: 4
- Views: 1629
Will paypal $30 to whoever helps me successfully connect to PGSQL with ADO
I've posted a few times and the community seems pretty convinced that a person can connect to a PostgreSQL database using the ADO SQL library . However I have not been able to get it to work. I've set up a dummy server here and provided the credentials: https://pastebin.com/NeeNeZj1. If anyone knows...
- 19 Apr 2017, 11:01
- Forum: Ask for Help (v1)
- Topic: Connecting to postgresql
- Replies: 0
- Views: 808
Connecting to postgresql
I've seen a few posts on the topic but no resolution. So it's either very simple & I'm missing it or maybe not possible? Using the IsNull/ahkDBA library for an easy UI, I've tried with two connection strings constructed from ( connectionstrings.com ). ADO Driver={PostgreSQL};Server=localhost;Port=54...
- 19 Apr 2017, 09:53
- Forum: Off-topic Discussion
- Topic: Thank you Autohotkey!
- Replies: 3
- Views: 1531
Re: Thank you Autohotkey!
That's great, I'm interested to know what part of ahk if any you turned into a career ? It's helped in probably more ways that I can list. But to give you some idea: * Prior to AHK I wrote in HTML & some actionscript. So the bulk of all of my programming knowledge came from AHK. Even if I'm mostly ...
- 18 Apr 2017, 18:39
- Forum: Off-topic Discussion
- Topic: Thank you Autohotkey!
- Replies: 3
- Views: 1531
Thank you Autohotkey!
Ten years ago this forum helped turned me from a young sapling into a programmer. People used to yell RTFM a lot more in those days but I lived by that damn documentation and it made all of the difference. Today, a decade later, I was adding a portion of the site where I pay tribute to the open sour...
- 03 Mar 2017, 23:28
- Forum: Ask for Help (v1)
- Topic: SOLVED: Help with a HTTP POST request with a binary (PDF) response Topic is solved
- Replies: 1
- Views: 3305
Re: Help with a HTTP POST request with a binary (PDF) response Topic is solved
People much smarter than myself figured it out here: https://autohotkey.com/board/topic/71528-com-winhttprequest-responsestream/page-2. I vaguely modified it to call it more easily below. To define the function: httpGetter(RequestType := "" ,URL := "" ,Payload := "" ,FullFilePath := "" ,OpenAfterSav...
- 03 Mar 2017, 19:24
- Forum: Ask for Help (v1)
- Topic: SOLVED: Help with a HTTP POST request with a binary (PDF) response Topic is solved
- Replies: 1
- Views: 3305
SOLVED: Help with a HTTP POST request with a binary (PDF) response Topic is solved
I have to call an API & collect the PDF response. After looking at a few options, it looks like Blackholyman's code in this link is the easiest . However, the response provided by the server is a binary file (PDF) which I need to download onto my computer. I'm still googling but I'm only getting oth...
- 20 Feb 2017, 14:26
- Forum: Ask for Help (v1)
- Topic: Possible to intercept text input & manipulate?
- Replies: 5
- Views: 1569
Re: Possible to intercept text input & manipulate?
I suggests that you post a link to the QR reader you are using or explain how it work from the perspective of your ahk script. For instance is it a command line utility that can be called from ahk or is it an application that needs to be worked around ? Good point, I just assumed that people were f...