[GUI] Use HTML and CSS for your GUIs!

Put simple Tips and Tricks that are not entire Tutorials in this forum
Stavencross
Posts: 59
Joined: 24 May 2016, 16:42

Re: [GUI] Use HTML and CSS for your GUIs!

26 Jan 2018, 19:02

kczx3 wrote:I can't get it to happen, though I am not using webapp.ahk. I simply used my own ActiveX control and modified the gui_KeyDown function from the AHK installer code. Maybe it is crashing because you are allowing all keys through as accelerators. I simply let through A/C/V and haven't seen your problem.

Code: [Select all] [Expand] [Download] GeSHi © Codebox Plus


Apologies on the delay in respose! I've implemented your idea of toning down what I let through (as you said, I was listening on all keys.)

I modified your line to:
if (Chr(wParam) ~= "[B,D,E,G-U,W,Y-Z]" || wParam = 0x74) ; Disable Ctrl+O/L/F/N and F5.
return

As "CONTROL + F" is important in my app. and we'll see what happens!

Thank you very much, I really feel like this is this answer I'll let ya'll know!
Stavencross
Posts: 59
Joined: 24 May 2016, 16:42

Re: [GUI] Use HTML and CSS for your GUIs!

26 Jan 2018, 19:05

Thought I would share what I've been building for the last 5 months. I keep it for myself as....well I won't lie, it makes me look REALLY good at work to be done with most my work within a week when everyone else takes 25 days.

I'm an account manager for a website company and I built an app using webapp.ahk and about.....15000 lines of custom code to automate most of my little processes.

It uses webapp.ahk, PHP, JS, HTML,CSS,SQL, and SOQL (Salesforce version of SQL)

https://drive.google.com/file/d/14VwXVx ... sp=sharing

check it out =)


Thanks again Joedf!
User avatar
kczx3
Posts: 615
Joined: 06 Oct 2015, 21:39

Re: [GUI] Use HTML and CSS for your GUIs!

26 Jan 2018, 20:51

Very impressive!
User avatar
joedf
Posts: 6439
Joined: 29 Sep 2013, 17:08
Facebook: J0EDF
Google: +joedf
GitHub: joedf
Location: Canada, Quebec
Contact:

Re: [GUI] Use HTML and CSS for your GUIs!

26 Jan 2018, 22:34

That's awesome! I'm really happy you saw the potential in this. :+1: :D
User avatar
kczx3
Posts: 615
Joined: 06 Oct 2015, 21:39

Re: [GUI] Use HTML and CSS for your GUIs!

27 Jan 2018, 15:29

I’d be curious how you’re using PHP and what JavaScript framework you’re using, if any.
User avatar
lmstearn
Posts: 149
Joined: 11 Aug 2016, 02:32
GitHub: lmstearn

Re: [GUI] Use HTML and CSS for your GUIs!

01 Feb 2018, 22:21

Looks great, thanks. :D
A soon as there is a convenient method to implement context help on the GUIs, then perhaps we can all dispense with the venerable HTMLHelp entirely!
:arrow: itros "ylbbub eht tuO kaerB" a ni kcuts m'I pleH
User avatar
joedf
Posts: 6439
Joined: 29 Sep 2013, 17:08
Facebook: J0EDF
Google: +joedf
GitHub: joedf
Location: Canada, Quebec
Contact:

Re: [GUI] Use HTML and CSS for your GUIs!

02 Feb 2018, 08:25

Well right now the new docs is implemented in JavaScript and preprocessed by ahk... essentially the htmlHelp still there as a browser display I guess?
User avatar
Off Topic
Posts: 43
Joined: 07 Oct 2017, 20:57

Re: [GUI] Use HTML and CSS for your GUIs!

05 Feb 2018, 16:20

Hey Joe, this thread is great -- I'm new to coding and have been eagerly learning my way towards this direction. Is it possible to also implement GSAP with this method? The ability to easily tween and ease would make a world of difference for the kind of GUI animation I'm after.
User avatar
kczx3
Posts: 615
Joined: 06 Oct 2015, 21:39

Re: [GUI] Use HTML and CSS for your GUIs!

05 Feb 2018, 20:39

That should be completely possible assuming that it is compatible with Internet Explorer.
User avatar
joedf
Posts: 6439
Joined: 29 Sep 2013, 17:08
Facebook: J0EDF
Google: +joedf
GitHub: joedf
Location: Canada, Quebec
Contact:

Re: [GUI] Use HTML and CSS for your GUIs!

05 Feb 2018, 22:25

as with what kczx3 has said, I don't see why it wouldnt work. :+1:
I say go ahead and try it out by playing with the example html files, let me know how it goes! ;)
Stavencross
Posts: 59
Joined: 24 May 2016, 16:42

Re: [GUI] Use HTML and CSS for your GUIs!

21 Feb 2018, 11:29

kczx3 wrote:I’d be curious how you’re using PHP and what JavaScript framework you’re using, if any.



Sorry about the delayed response here.

I use a mixture of php/ahk as my main drivers, I'll list the languages used and how below.


PHP runs on page load, it does some INI read/write so I don't have crazy long URL strings, but mostly I use PHP to:
1. Provide context sensitive links
a. If I've built my monthly presentation for client X then it shows a link to pop up the PDF. If I haven't built the presentation, it runs a function that auto-builds said presentation in powerpoint via COM interface.
b. It checks the status of my monthly "client review" case in salesforce and offers me an option to only open the case in salesforce, or to open the case in salesforce + 3 other links, depending upon its' status
2. Consume SalesForce & other APIs
a. Because my SalesForce team won't give me the access to cURL the SalesForce API, I found a pre-built interface for PHP that hits the SOAP API, so I had to build in PHP to use it.

SOQL is used to request information from SalesForce via the SOAP API, it's similar to SQL, but is their own dialect.

JavaScript passes information to AHK, calls AHK functions. I also use it in a few key places for table sorting.

AHK handles all navigation requests, and any/all input required - although I finally figured out what was causing my previous crashing issue, AHK guis/input boxes are still faster than drawing them on the app's page during the page load event.

HTML/CSS used as the basic building blocks

Hit me up via PM if you want to see a video demo I made - We were going to roll it out to the rest of our team but decided not to.
User avatar
joedf
Posts: 6439
Joined: 29 Sep 2013, 17:08
Facebook: J0EDF
Google: +joedf
GitHub: joedf
Location: Canada, Quebec
Contact:

Re: [GUI] Use HTML and CSS for your GUIs!

08 Mar 2018, 21:59

Eitherway, nice work! :+1:
Gicu
Posts: 111
Joined: 19 Aug 2014, 08:19
Location: Italy

Re: [GUI] Use HTML and CSS for your GUIs!

11 Mar 2018, 02:31

Thank you joedf!

I'm trying to log very long script steps...

Image

Code: [Select all] [Expand] [Download] (HtmlLogClass.ahk)GeSHi © Codebox Plus



Code: [Select all] [Expand] [Download] (Sample.ahk)GeSHi © Codebox Plus

User avatar
joedf
Posts: 6439
Joined: 29 Sep 2013, 17:08
Facebook: J0EDF
Google: +joedf
GitHub: joedf
Location: Canada, Quebec
Contact:

Re: [GUI] Use HTML and CSS for your GUIs!

12 Mar 2018, 08:27

Seems fancy :+1: but sadly I can’t see the image... :(
Gicu
Posts: 111
Joined: 19 Aug 2014, 08:19
Location: Italy

Re: [GUI] Use HTML and CSS for your GUIs!

12 Mar 2018, 08:51

do you mean the screenshot in the post?
User avatar
jeeswg
Posts: 4974
Joined: 19 Dec 2016, 01:58
Location: UK

Re: [GUI] Use HTML and CSS for your GUIs!

12 Mar 2018, 14:28

By quoting the post, you can find the original link:
https://www.dropbox.com/s/kgyva6i5k3g4v6d/11_03_18_08_09_14.png?dl=1
User avatar
joedf
Posts: 6439
Joined: 29 Sep 2013, 17:08
Facebook: J0EDF
Google: +joedf
GitHub: joedf
Location: Canada, Quebec
Contact:

Re: [GUI] Use HTML and CSS for your GUIs!

12 Mar 2018, 21:12

Oh I see it now, maybe it was a load issue... Very nice work! :+1:
Stavencross
Posts: 59
Joined: 24 May 2016, 16:42

Re: [GUI] Use HTML and CSS for your GUIs!

10 Apr 2018, 06:37

joedf wrote:Oh I see it now, maybe it was a load issue... Very nice work! :+1:



So I had an interesting thought. Do you think it would possible to have a web page on a webserver with the js to run an AHK function written in that would interact with the local computer?

For instance I go to a page on the web and AHK opens notepad on my local machine? I don't see how it would be different than opening said web page locally on my computer, as long as I have your webapp.ahk on my computer right?
User avatar
joedf
Posts: 6439
Joined: 29 Sep 2013, 17:08
Facebook: J0EDF
Google: +joedf
GitHub: joedf
Location: Canada, Quebec
Contact:

Re: [GUI] Use HTML and CSS for your GUIs!

10 Apr 2018, 08:08

You could try Sparrow-ahk (https://github.com/ahkscript/awesome-Au ... networking)
or something that is more up to date: AHKhttp (https://github.com/ahkscript/awesome-Au ... networking)

Return to “Tips and Tricks”

Who is online

Users browsing this forum: No registered users and 0 guests