Search found 507 matches

by BGM
18 Sep 2014, 13:59
Forum: Ask for Help (v1)
Topic: Quick swap focus to Instantbird and Back
Replies: 6
Views: 2121

Quick swap focus to Instantbird and Back

Hi, all, I use instantbird to talk to my coworkers. So whilst I am doing something, typing in another program, perhaps, I have to use my mouse and click in Instantbird's entry form to send a message, then use the mouse to return to where I left off. So I want to make a script that will let me, via h...
by BGM
26 Aug 2014, 13:20
Forum: Scripts and Functions (v1)
Topic: Include() - Dynamic include, sort of - AHK v1.1 & v2.0-a049
Replies: 12
Views: 4766

Re: Include() - Dynamic include, sort of - AHK v1.1 & v2.0-a

Coco, yes, actually I already have that in my own script, and for the same reason!
by BGM
26 Aug 2014, 11:28
Forum: Scripts and Functions (v1)
Topic: Include() - Dynamic include, sort of - AHK v1.1 & v2.0-a049
Replies: 12
Views: 4766

Re: Include() - Dynamic include, sort of - AHK v1.1 & v2.0-a

Coco, Scenario: Say you have an AHK app that implements some sort of plugin system and the rule is to put the extension(s) in the following directory your_script_dir/plugins Ha ha - I was just recently trying to do this! I couldn't figure out how to do it right, although I tried various approaches a...
by BGM
25 Aug 2014, 19:21
Forum: Scripts and Functions (v1)
Topic: Include() - Dynamic include, sort of - AHK v1.1 & v2.0-a049
Replies: 12
Views: 4766

Re: Include() - Dynamic include, sort of - AHK v1.1 & v2.0-a

Can you call this from any function during a running script?
by BGM
19 Aug 2014, 21:35
Forum: Ask for Help (v1)
Topic: Function to validate MAC address
Replies: 5
Views: 2374

Re: Function to validate MAC address

Ha ha! I never thought of that, but you are totally right! Thanks!
by BGM
19 Aug 2014, 09:14
Forum: Ask for Help (v1)
Topic: Function to validate MAC address
Replies: 5
Views: 2374

Re: Function to validate MAC address

Thanks, lexikos. Actually, I needed to get the address without anything but the letters themselves so I could use them to build filenames for polycom config files. I fixed my function to optionally allow for formatting for the linux dhcp server config: ;makes sure an address is the correct length an...
by BGM
18 Aug 2014, 11:11
Forum: Ask for Help (v1)
Topic: Function to validate MAC address
Replies: 5
Views: 2374

Re: Function to validate MAC address

Ah, so I came up with this, actually.

Code: Select all

validateMacAddress(whatmacaddress){
	testaddress := whatmacaddress
	testaddress := RegExReplace(testaddress,"[^A-Za-z0-9]")
	if(len(testaddress) != 12){
		alert("Uh, the macaddress seems misformed.")
		return false
	}else{
		return true
	}
}
by BGM
18 Aug 2014, 10:47
Forum: Ask for Help (v1)
Topic: Function to validate MAC address
Replies: 5
Views: 2374

Function to validate MAC address

Say, does anyone offhand have a snippet to validate a mac address (that I could borrow :) )?
by BGM
20 Jun 2014, 19:37
Forum: Scripts and Functions (v1)
Topic: tv - a treeview wrapper/function library
Replies: 36
Views: 14332

Re: tv - a treeview wrapper/function library

There's no barging around here! Ha ha. The problem with adding context menu and drag-n-drop is that this is a class library and should only contains functions, not subs, that way it doesn't matter where you include the file. Do you have any samples from your script? Even if they have bugs we could w...
by BGM
20 Jun 2014, 11:22
Forum: Scripts and Functions (v1)
Topic: tv - a treeview wrapper/function library
Replies: 36
Views: 14332

Re: tv - a treeview wrapper/function library

Just Me, you used a contstruct I am unfamiliar with:
parents := [this.parent(whatid)]
What is happening there with those square brackets?
by BGM
20 Jun 2014, 11:08
Forum: Scripts and Functions (v1)
Topic: tv - a treeview wrapper/function library
Replies: 36
Views: 14332

Re: tv - a treeview wrapper/function library

Just Me - ah, now that you explain it that way, it does work. In fact, I think it all works just right. Okay, now that it is working, I'm going to update the script at the head of the thread and add you and Joe as contributors. If you think of anything else to add to the library, please post! Thanks...
by BGM
20 Jun 2014, 09:06
Forum: Scripts and Functions (v1)
Topic: tv - a treeview wrapper/function library
Replies: 36
Views: 14332

Re: tv - a treeview wrapper/function library

@just me - thanks for getting in on this. I know you've been around in the authotkey community for a long time! Now, I've plugged in your function to my library. But your demo uses a different function name than the function. I prefer allChildrenHaveAttribute to nodeHasAttribute because "node" could...
by BGM
18 Jun 2014, 13:19
Forum: Scripts and Functions (v1)
Topic: tv - a treeview wrapper/function library
Replies: 36
Views: 14332

Re: tv - a treeview wrapper/function library

Good work, Joe. I tried, too, with an extra parameter for recursing, but never figured it out. Okay, so with subfamilies=true , that means if all the items in the tree (all the way down) are checked we get 1. If any are unchecked, we get 0. Thus, this works: tv.familyHasAttribute(a_eventinfo, "check...
by BGM
17 Jun 2014, 13:36
Forum: Scripts and Functions (v1)
Topic: tv - a treeview wrapper/function library
Replies: 36
Views: 14332

Re: tv - a treeview wrapper/function library

Thanks, Joe. This will be a great library when everything works. Let me know if you think of anything else to add.
by BGM
17 Jun 2014, 08:21
Forum: Scripts and Functions (v1)
Topic: tv - a treeview wrapper/function library
Replies: 36
Views: 14332

Re: tv - a treeview wrapper/function library

All right. I think I confused myself, too. It does seem to work as long as you don't specify any parameters. Something is amiss, however - if you set the second parameter to true, it reports incorrectly. In my original function (which didn't work), I used this logic: if(!this.familyHasAttribute(next...
by BGM
16 Jun 2014, 22:30
Forum: Scripts and Functions (v1)
Topic: tv - a treeview wrapper/function library
Replies: 36
Views: 14332

Re: tv - a treeview wrapper/function library

For example: A:1=> ( b:0, c:1) Return 0 for c, 0 for a?!? A:1=> ( b:1=> ( c:0, d:0)) return 1 for a, 0 for b??!? Ah, I see you are trying to get me back with logic of your own :D . I think you've got me. I thought I explained it pretty well in my last post. What part of my last post doesn't make se...
by BGM
16 Jun 2014, 19:08
Forum: Scripts and Functions (v1)
Topic: tv - a treeview wrapper/function library
Replies: 36
Views: 14332

Re: tv - a treeview wrapper/function library

Ha ha, Joe! Okay, if all the boxes are checked in a subfamily, it should return 1. If any of the boxes are unchecked, it should return 0. In my demo above, when you load it, all the boxes are checked except for "Mack's First Child". When you click in the subtrees, each item should know from the func...
by BGM
16 Jun 2014, 16:54
Forum: Scripts and Functions (v1)
Topic: tv - a treeview wrapper/function library
Replies: 36
Views: 14332

Re: tv - a treeview wrapper/function library

Nope - that returns 0 no matter what. :)
by BGM
16 Jun 2014, 16:29
Forum: Scripts and Functions (v1)
Topic: tv - a treeview wrapper/function library
Replies: 36
Views: 14332

Re: tv - a treeview wrapper/function library

The function is supposed to return 1 if ALL the the items in the tree have a certain attribute. If any item is missing the attribute, it returns 0. If you click on the first child, it reports correctly. The bug is only ever on the last child.
by BGM
16 Jun 2014, 16:25
Forum: Scripts and Functions (v1)
Topic: tv - a treeview wrapper/function library
Replies: 36
Views: 14332

Re: tv - a treeview wrapper/function library

Joe, that uh, does the same thing as my function did. If you click on "Mack's 2nd Child" it still shows 1 when it should show 0. But it doesn't crash!

Go to advanced search