Sign in to follow this  
Followers 0
rcmaehl

GUI Ctrl Limits

5 posts in this topic

Okay, so I know AutoIt has a limit of 65532 Controls in a GUI and I'm making a Graphical IP Mapper, however I need an alternative to coloring labels to represent pixels on the screen for an entered IP address. Currently, because of the control limits I can only show the first net (e.g. 75 of 75.142.212.111). Is there any way to do something like set a pixel color in a GUI?

Important Info:

1. There is no standard function to do this in the Documentation

2. There will be 65540+ (this includes the Close/Minimize/Maximize default controls) controls on the GUI in the way I'm trying to currently do it which is above the maximum number of Controls

3. It's probably possible to do this with some sort of colorable ListView with 256 rows and columns, however I'm not too sure how to do so

Summary for dummies:

I need to make a COLORABLE 256x256 GRID of SQUARES in a GUI, and each square needs to be able to be colored INSTEAD of the entire GRID a single color.


My UDFs are generally for me. If they aren't updated for a while, it means I'm not using them myself. As soon as I start using them again, they'll get updated.

MY PROJECTS


Active: IRC UDF, WindowEx UDF
Discontinued: GithubBubbleSort UDF

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

Most of those IP addresses you're trying to color aren't needed, because you can't ever have anything using those IP addresses as they're reserved. Any IP that starts with 0, 127, 169 or is greater than 239 are invalid for IP addresses for example. And most networks don't allow mapping an IP address that ends in 0 or 255. So that might be of some help as it greatly reduces the number of boxes in the grid.

Also, you could use a ListView control and one of the example scripts that show how to color them. Also, using the LV UDF you can have as many controls as you want on the GUI because it doesn't use internal control IDs, it uses handles.

EDIT:Typo

Edited by BrewManNH

If I posted any code, assume that code was written using the latest release version unless stated otherwise. Also, if it doesn't work on XP I can't help with that because I don't have access to XP, and I'm not going to.
Give a programmer the correct code and he can do his work for a day. Teach a programmer to debug and he can do his work for a lifetime - by Chirag Gude
How to ask questions the smart way!

I hereby grant any person the right to use any code I post, that I am the original author of, on the autoitscript.com forums, unless I've specifically stated otherwise in the code or the thread post. If you do use my code all I ask, as a courtesy, is to make note of where you got it from.

Back up and restore Windows user files _Array.au3 - Modified array functions that include support for 2D arrays.  -  ColorChooser - An add-on for SciTE that pops up a color dialog so you can select and paste a color code into a script.  -  Customizable Splashscreen GUI w/Progress Bar - Create a custom "splash screen" GUI with a progress bar and custom label.  -  _FileGetProperty - Retrieve the properties of a file  -  SciTE Toolbar - A toolbar demo for use with the SciTE editor  -  GUIRegisterMsg demo - Demo script to show how to use the Windows messages to interact with controls and your GUI.  -   Latin Square password generator

Share this post


Link to post
Share on other sites

How about using GDI Functions? Wouldn't this be a good solution to having a 256 x 256 grid?


Regards,Hannes[spoiler]If you can't convince them, confuse them![/spoiler]

Share this post


Link to post
Share on other sites

#4 ·  Posted (edited)

Or use a graphics control and set single pixels to a specific color.

Edited by ProgAndy

*GERMAN* [note: you are not allowed to remove author / modified info from my UDFs]My UDFs:[_SetImageBinaryToCtrl] [_TaskDialog] [AutoItObject] [Animated GIF (GDI+)] [ClipPut for Image] [FreeImage] [GDI32 UDFs] [GDIPlus Progressbar] [Hotkey-Selector] [Multiline Inputbox] [MySQL without ODBC] [RichEdit UDFs] [SpeechAPI Example] [WinHTTP]UDFs included in AutoIt: FTP_Ex (as FTPEx), _WinAPI_SetLayeredWindowAttributes

Share this post


Link to post
Share on other sites

Or use a graphics control and set single pixels to a specific color.

;) How did I miss that in the Documentation. Thanks.


My UDFs are generally for me. If they aren't updated for a while, it means I'm not using them myself. As soon as I start using them again, they'll get updated.

MY PROJECTS


Active: IRC UDF, WindowEx UDF
Discontinued: GithubBubbleSort UDF

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0