Jump to content

Convertor


Infinitex0
 Share

Recommended Posts

#include <GUIConstants.au3>
GUICreate("Convertor", 330, 125)
GUICtrlCreateLabel("Simply input a temperature in Celsius/Fahrenheit and hit the",0, 0)  
GUICtrlCreateLabel("Convert button and you will see the temperature in Celsius/Fahrenheit", 0, 15)
$Cel = GUICtrlCreateInput("Celsius", 30, 30, 57, 20, $ES_NUMBER)
GUICtrlCreateLabel("Celsius>>>>><<<<<Fahrenheit", 100, 35)
$Con1 = GUICtrlCreateButton("Convert", 30, 51.5, 57)
$Far = GUICtrlCreateInput("Fahrenheit", 30, 77, 57, 20, $ES_NUMBER)
GUICtrlCreateLabel("Fahrenheit>>>>><<<<<Celsius", 100, 82)
$Con2 = GUICtrlCreateButton("Convert", 30, 98, 57)
GUISetState(@SW_SHOW)

While 1
    $msg = GUIGetMsg()
    Select
        Case $msg = $GUI_EVENT_CLOSE
            Exit
        Case $msg = $Con1
            MsgBox(4096, "", "In Fahrenheit Equals: " & (GUICtrlRead($Cel) * 1.8) + 32)
        Case $msg = $Con2
            MsgBox(4096, "", "In Celsius Equals: " & Round((GUICtrlRead($Far)-32) / 1.80, 2));RIGHT HERE
    EndSelect

This is used to convert celsius to fahrenheit and vice versa

P.S All feedBack is wanted

P.S.S Thank you SmOke_N

Edited by Infinitex0

The below statement is False.The above statement is True.a lesson I learned from Greenmachine; give a man a code and he'll solve one problem. Teach a man to code and he'll solve all his problems.P.S please don't use autoIt as a virus creator/spyware maker(keyLogger especially)Cick this and help me[center]My Scripts:[/center][center]Port Scanner[/center]

Link to comment
Share on other sites

No feedback :o

The below statement is False.The above statement is True.a lesson I learned from Greenmachine; give a man a code and he'll solve one problem. Teach a man to code and he'll solve all his problems.P.S please don't use autoIt as a virus creator/spyware maker(keyLogger especially)Cick this and help me[center]My Scripts:[/center][center]Port Scanner[/center]

Link to comment
Share on other sites

No feedback :o

It's alright I just don't think this is something people really need you know? The only thing I can say to help is you don't need to use two labels on lines 3 - 4. You can just use one like:

GUICtrlCreateLabel("Simply input a temperature in Celsius/Fahrenheit and hit the" & @CRLF & "Convert button and you will see the temperature in Celsius/Fahrenheit",0, 0,-1,30)

Hallman :geek:

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