Jump to content

Computer timer limit


samir500
 Share

Recommended Posts

Hello guys,

i have a question, i want to make a basic computer timer limit with autoit (see picture). My first question is it possible or not. I was looking on koda , you have there a com object, and i found a datagrid. 

But you can't resize it, and you can only press one block. Or do i need to program it in a other programming/scripting language.

 

 

timer.jpg

Link to comment
Share on other sites

  • Moderators

It is definitely possible. But as there is already a product available, as you point out in your own post, why try to reinvent the wheel?

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
Share on other sites

56 minutes ago, JLogan3o13 said:

It is definitely possible. But as there is already a product available, as you point out in your own post, why try to reinvent the wheel?

You are right. But i want to make my own for my kids it's fun to do it, i only need a timer, because i have everything setup with mmc  the policies.

Can somebody point me in the right direction.

Link to comment
Share on other sites

  • Moderators

Start by looking at the GUI* functions in the help file; every function has at least one example. Below is a bare-bones GUI to get you started. Start with adding buttons and other controls to get it how you like it, then you can worry about the underlying code.

#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>

Local $hGUI = GuiCreate("Test", 300, 400)
GUISetState(@SW_SHOW)

    While 1
        Switch GUIGetMsg()
            Case $GUI_EVENT_CLOSE
                ExitLoop
        EndSwitch
    WEnd

 

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
Share on other sites

5 minutes ago, JLogan3o13 said:

Start by looking at the GUI* functions in the help file; every function has at least one example. Below is a bare-bones GUI to get you started. Start with adding buttons and other controls to get it how you like it, then you can worry about the underlying code.

#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>

Local $hGUI = GuiCreate("Test", 300, 400)
GUISetState(@SW_SHOW)

    While 1
        Switch GUIGetMsg()
            Case $GUI_EVENT_CLOSE
                ExitLoop
        EndSwitch
    WEnd

 

okay do you mean i need first configure the GUI and when i am finished , i need to start coding?

Link to comment
Share on other sites

  • Moderators

It is a personal preference, but usually I find getting the GUI to where you want it makes it easier. Once you know what kind of controls you want, and where (listviews, buttons, input and edit fields, etc.) it is much easier to envision the code behind it. Also, as building the GUI is generally the easier task, it is a good way to introduce yourself to AutoIt and how the language works.

Others may prefer the opposite; get the code and then build the GUI around it. But trying to build the GUI as you build the code can definitely lead to frustration. You'll have to choose the method that best suits you.

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
Share on other sites

2 minutes ago, JLogan3o13 said:

It is a personal preference, but usually I find getting the GUI to where you want it makes it easier. Once you know what kind of controls you want, and where (listviews, buttons, input and edit fields, etc.) it is much easier to envision the code behind it. Also, as building the GUI is generally the easier task, it is a good way to introduce yourself to AutoIt and how the language works.

Others may prefer the opposite; get the code and then build the GUI around it. But trying to build the GUI as you build the code can definitely lead to frustration. You'll have to choose the method that best suits you.

okay thank you for your explanation. But do you know how i can get the grid as on the picture. In the combobject i have found one see picture.

Com.jpg

Link to comment
Share on other sites

1 hour ago, JLogan3o13 said:

It is a personal preference, but usually I find getting the GUI to where you want it makes it easier. Once you know what kind of controls you want, and where (listviews, buttons, input and edit fields, etc.) it is much easier to envision the code behind it. Also, as building the GUI is generally the easier task, it is a good way to introduce yourself to AutoIt and how the language works.

Others may prefer the opposite; get the code and then build the GUI around it. But trying to build the GUI as you build the code can definitely lead to frustration. You'll have to choose the method that best suits you.

Yes i am designing the gui right now, i use checkboxes to choose which time is allowed or not . See picture.

pclimit.jpg

Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...