Jump to content

Input field


Gerben150
 Share

Recommended Posts

Hello,

My english is verry bad... but i gif it a try.

(I`m dutch)

I have a input field but you can type all the caracters in in... is it poseble to have

a input field were you only can type numbers?

ANd how you do that? (if its poseble)

Greets,

Gerben

Use $ES_NUMBER for the style when you use GUICtrlCreateInput()

Edit: The above example is for a GUI input box - as for standard InputBox() creation, I'd do an IsNumber() check on it.

Edited by Monamo

- MoChr(77)& Chr(97)& Chr(100)& Chr(101)& Chr(32)& Chr(121)& Chr(97)& Chr(32)& Chr(108)& Chr(111)& Chr(111)& Chr(107)-------I've told you 100,000 times not to exaggerate!-------Don't make me hit you with my cigarette hand...-------My scripts:Random Episode Selector, Keyboard MouseMover, CopyPath v2.1, SmartRename for XP,Window Tracer[sup]New![/sup]

Link to comment
Share on other sites

Heey,

Thank for your reply.

I use GUICtrlCreateInput() i think :)

Maby should this help... my code...

#include <GUIConstants.au3>

GUICreate("G-SOFT                                  -ALR-                                   V1.0")
GUISetState (@SW_SHOW)

GUICtrlCreateLabel ("Hartelijk dank voor het gebruiken van de G-SOFT Activation Line Remover.", 10, 10)
GUICtrlCreateLabel ("Dit programma helpt u met het verwijderen van het grijze activatie", 10, 25)
GUICtrlCreateLabel ("randje. U hoeft alleen hieronder de naam, hoogte en breedte in te vullen", 10, 40)
GUICtrlCreateLabel ("en de rest wordt voor u gedaan.", 10, 55)

GUICtrlCreateLabel ("http://www.g-soft.nl", 10, 80)

Opt("GUICoordMode",2)
GUICtrlCreateGroup ("Gegevens van swf", -90, 17, 355, 220)

GUICtrlCreateLabel ("Naam van uw flash:",  -345, -180, 95, 20)
$swf_naam = GUICtrlCreateInput ( "", 2,  -23, 190, 20)
GUICtrlCreateLabel (".swf", 3, -15, 50)
GUICtrlCreateLabel ("Dus zonder de extentie. (swf)", -240, -4, 150)
GUICtrlCreateLabel ("Hoogte van de swf:",  -250, 25, 97)
$swf_hoogte = GUICtrlCreateInput ( "", 0,  -23, 50, 20)
GUICtrlCreateLabel ("Pixels", 3, -17, 50)
GUICtrlCreateLabel ("Breedte van de swf:",  -200, 45, 97)
$swf_breedte = GUICtrlCreateInput ( "", 0,  -23, 50, 20)
GUICtrlCreateLabel ("Pixels", 3, -17, 50)

$Button_1 = GUICtrlCreateButton ("Exit",  -225, 65, 100)
$Button_2 = GUICtrlCreateButton ("Voltooien", 180, -20, 100)

While 1
    $msg = GUIGetMsg()
    Select
        Case $msg = $GUI_EVENT_CLOSE
            ExitLoop
        Case $msg = $Button_1
            Exit
        Case $msg = $button_2
               Run('Notepad.exe')
               WinWaitActive("Naamloos - Kladblok")
               Send("")
    EndSelect
Wend
Link to comment
Share on other sites

#include <GUIConstants.au3>

GUICreate("G-SOFT                                   -ALR-                                   V1.0")
GUISetState (@SW_SHOW)

GUICtrlCreateLabel ("Hartelijk dank voor het gebruiken van de G-SOFT Activation Line Remover.", 10, 10)
GUICtrlCreateLabel ("Dit programma helpt u met het verwijderen van het grijze activatie", 10, 25)
GUICtrlCreateLabel ("randje. U hoeft alleen hieronder de naam, hoogte en breedte in te vullen", 10, 40)
GUICtrlCreateLabel ("en de rest wordt voor u gedaan.", 10, 55)

GUICtrlCreateLabel ("http://www.g-soft.nl", 10, 80)

Opt("GUICoordMode",2)
GUICtrlCreateGroup ("Gegevens van swf", -90, 17, 355, 220)

GUICtrlCreateLabel ("Naam van uw flash:",  -345, -180, 95, 20)
$swf_naam = GUICtrlCreateInput ( "", 2,  -23, 190, 20, $ES_NUMBER)
GUICtrlCreateLabel (".swf", 3, -15, 50)
GUICtrlCreateLabel ("Dus zonder de extentie. (swf)", -240, -4, 150)
GUICtrlCreateLabel ("Hoogte van de swf:",  -250, 25, 97)
$swf_hoogte = GUICtrlCreateInput ( "", 0,  -23, 50, 20,  $ES_NUMBER)
GUICtrlCreateLabel ("Pixels", 3, -17, 50)
GUICtrlCreateLabel ("Breedte van de swf:",  -200, 45, 97)
$swf_breedte = GUICtrlCreateInput ( "", 0,  -23, 50, 20,  $ES_NUMBER)
GUICtrlCreateLabel ("Pixels", 3, -17, 50)

$Button_1 = GUICtrlCreateButton ("Exit",  -225, 65, 100)
$Button_2 = GUICtrlCreateButton ("Voltooien", 180, -20, 100)

While 1
    $msg = GUIGetMsg()
    Select
        Case $msg = $GUI_EVENT_CLOSE
            ExitLoop
        Case $msg = $Button_1
            Exit
        Case $msg = $button_2
               Run('Notepad.exe')
               WinWaitActive("Naamloos - Kladblok")
               Send("")
    EndSelect
Wend

8)

NEWHeader1.png

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...