Jump to content

Need some help


Recommended Posts

$destination = "C:\Program Files\Scorpion2.jpg"

Splashimageon("",$destination,450,338)
Sleep(3500)
SplashOff()

#include <ButtonConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>

$Form1 = GUICreate("test")
GUISetIcon("C:\Users\poop\Desktop\newicon.ico")
GUISetCursor (3)
GUISetBkColor(0x000000)
$Button1 = GUICtrlCreateButton("EXIT", 12, 70, 105, 33, $WS_GROUP)
GUICtrlSetFont(-1, 12, 800, 4, "Franklin Gothic Medium")
GUICtrlSetBkColor(-1, 0x00FF00)
GUICtrlSetCursor (-1, 0)
$Button2 = GUICtrlCreateButton("START", 12, 105, 105, 33, $WS_GROUP)
GUICtrlSetFont(-1, 12, 800, 4, "Franklin Gothic Medium")
GUICtrlSetBkColor(-1, 0x00FF00)
GUICtrlSetCursor (-1, 0)
GUISetState(@SW_SHOW)
$Input1 = GUICtrlCreateInput("Email", 8, 24, 105, 21)
$Input2 = GUICtrlCreateInput("Pass", 8, 48, 73, 21)

While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
        Case $GUI_EVENT_CLOSE
            Exit
        Case $Button2
            Guictrlread ($input1)
            MouseClick("left",588,8,1,0)
            MouseClick("left",599,231,1,0)
            send($Input1)
            MouseClick("left",769,230,1,0)
            GUICtrlRead ($input2)
            send($Input2)
            mouseclick("left",917,233,1,0)
    EndSwitch
WEnd

i had originally wanted to start with an input form for password and email, but i realized i wanted to go from that to having the program read from .ini or .txt for email and password because that way you could have more accounts and not have to make a huge gui or have to type your email and password over and over again when you restart the program because it would be stored in the .ini or .txt.

Edited by Jos
put script ion code box
Link to comment
Share on other sites

  • Developers

You will have to save the result of Guictrlread($input1) into a variable and use that variable in the Send() command.

- or use Send(Guictrlread($input1)).

Jos

Edited by Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

  • Developers

that works for the input form but how for .ini or .txt

IniRead() for Ini files.

FileRead() for txt files.

- or I missing something here?

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

  • Developers

could i do it like this

send(iniread "inifilename.ini"))

or

send(fileread "txtfilename.txt"))

Yes, given the syntax is code correctly.

Now tell me: Why are you asking and not trying?

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

  • Developers

lol i am trying as i ask, but with the last thing i did i got this error:

send(FileRead (email1.txt))

send(FileRead (email1^ERROR

Error: missing separator character after keyword.

how do i fix?

As I said: Given the syntax is correct. :D

The filename is a string thus needs to be enclosed in ""

Jos

Edited by Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

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