Sign in to follow this  
Followers 0
TheWebz

<b>Help with code!</b>

8 posts in this topic

#1 ·  Posted (edited)

I want to make a program that register the user in a site, however i've looked into IE functions and i couldn't understand how to do it.
Does somebody know's how to do it?
Thanks a lot,
TheWebz

Edited by TheWebz

Share this post


Link to post
Share on other sites



i come  up with this: 

#include <ButtonConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
#include <IE.au3>
#Region ### START Koda GUI section ### Form=
$Form1 = GUICreate("Beticious Hack By Kiko", 615, 438, 192, 124)
$Button1 = GUICtrlCreateButton("Criar Conta", 167, 304, 281, 81)
$Edit1 = GUICtrlCreateEdit("", 121, 16, 393, 233)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###

While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
        Case $GUI_EVENT_CLOSE
            Exit

        Case $Button1
            _criarfoda()
    EndSwitch
WEnd

func _criarfoda()
    $pagina = _IECreate( "http://www.beticious.com/pt/register?ref=jorgejesus97", 0, 1 )
    $nome = _IEGetObjById( $pagina, "name" )
    $ola = _IEPropertyGet( $pagina, "name" )
    MsgBox( 64, "", $ola )
EndFunc

 but what i really wanted to do was to input text in the gaps!


Share this post


Link to post
Share on other sites

I've made this:

#include <ButtonConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
#include <IE.au3>
#Region ### START Koda GUI section ### Form=
$Form1_1 = GUICreate("Beticious Hack By Kiko", 645, 691, 192, 0)
$Button1 = GUICtrlCreateButton("Criar Conta", 167, 592, 281, 81)
Global $IE_youtube = _IECreateEmbedded()
$broweryoutube = GUICtrlCreateObj($IE_youtube, 8, 8, 620, 569)
_IENavigate ($IE_youtube, "http://www.beticious.com/pt/register?ref=jorgejesus97")
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###

While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
        Case $GUI_EVENT_CLOSE
            Exit

        Case $Button1
            _criar()
    EndSwitch
WEnd

func _criar()
    $nome = _IEGetObjById( $IE_youtube, "name" )
    _IEAction( $nome, "invisible" )
EndFunc

I can't understand why the name field isn't invisible!

Can someone help me?

TheWebz


Share this post


Link to post
Share on other sites

No one knows?


Share this post


Link to post
Share on other sites

to understand, try this:

#include <ButtonConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
#include <IE.au3>
#region ### START Koda GUI section ### Form=
$Form1_1 = GUICreate("Beticious Hack By Kiko", 645, 691, 192, 0)
$Button1 = GUICtrlCreateButton("Criar Conta", 167, 592, 281, 81)
Global $IE_youtube = _IECreateEmbedded()
$broweryoutube = GUICtrlCreateObj($IE_youtube, 8, 8, 620, 569)
GUISetState()
#endregion ### END Koda GUI section ###

ConsoleWrite('test 0' & @CRLF)
_IENavigate($IE_youtube, "http://www.beticious.com/pt/register?ref=jorgejesus97")
ConsoleWrite('test 1' & @CRLF)

While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
        Case $GUI_EVENT_CLOSE
            Exit

        Case $Button1
            _criar()
    EndSwitch
WEnd

Func _criar()
    $nome = _IEGetObjById($IE_youtube, "name")
    ConsoleWrite('IsObj($nome)' & IsObj($nome) & @CRLF)
    _IEAction($nome, "invisible")
EndFunc   ;==>_criar

Signature beginning:   Wondering who uses AutoIT and what it can be used for ?
* GHAPI UDF - modest begining - comunication with GitHub REST API *
ADO.au3 UDF     POP3.au3 UDF     XML.au3 UDF    How to use IE.au3  UDF with  AutoIt v3.3.14.x  for other useful stuff click the following button

Spoiler

Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind. 

My contribution (my own projects): * Debenu Quick PDF Library - UDF * Debenu PDF Viewer SDK - UDF * Acrobat Reader - ActiveX Viewer * UDF for PDFCreator v1.x.x * XZip - UDF * AppCompatFlags UDF * CrowdinAPI UDF * _WinMergeCompare2Files() * _JavaExceptionAdd() * _IsBeta() * Writing DPI Awareness App - workaround * _AutoIt_RequiredVersion() * Chilkatsoft.au3 UDF * TeamViewer.au3 UDF * JavaManagement UDF * VIES over SOAP * WinSCP UDF * GHAPI UDF - modest begining - comunication with GitHub REST API *

My contribution to others projects or UDF based on  others projects: * _sql.au3 UDF  * POP3.au3 UDF *  RTF Printer - UDF * XML.au3 - BETA * ADO.au3 UDF SMTP Mailer UDF *

Useful links: * Forum Rules * Forum etiquette *  Forum Information and FAQs * How to post code on the forum * AutoIt Online Documentation * AutoIt Online Beta Documentation * SciTE4AutoIt3 getting started * Convert text blocks to AutoIt code * Games made in Autoit * Programming related sites * Polish AutoIt Tutorial * DllCall Code Generator * 

Wiki: Expand your knowledge - AutoIt Wiki * Collection of User Defined Functions * How to use HelpFile * Best coding practices * 

IE Related:  * How to use IE.au3  UDF with  AutoIt v3.3.14.x * Why isn't Autoit able to click a Javascript Dialog? * Clicking javascript button with no ID * IE document >> save as MHT file * IETab Switcher (by LarsJ ) * HTML Entities * _IEquerySelectorAll() (by uncommon) * 

I encourage you to read: * Global Vars * Best Coding Practices * Please explain code used in Help file for several File functions * OOP-like approach in AutoIt * UDF-Spec Questions *  EXAMPLE: How To Catch ConsoleWrite() output to a file or to CMD *

"Homo sum; humani nil a me alienum puto" - Publius Terentius Afer
"Program are meant to be read by humans and only incidentally for computers and execute" - Donald Knuth, "The Art of Computer Programming"
:naughty:  :ranting:, be  :) and       \\//_.

Anticipating Errors :  "Any program that accepts data from a user must include code to validate that data before sending it to the data store. You cannot rely on the data store, ...., or even your programming language to notify you of problems. You must check every byte entered by your users, making sure that data is the correct type for its field and that required fields are not empty."

Signature last update: 2017-06-04

Share this post


Link to post
Share on other sites

the program isn't retrieving the correct name of obj right?

But then i cant see where is the error


Share this post


Link to post
Share on other sites

#8 ·  Posted (edited)

No one knows?

you are pretty impatient by opening a second topic and bumping this fast.

Topics merged so stick to this one.

Jos

Edited by Jos

Visit the SciTE4AutoIt3 Download page for the latest versions        Beta files                                                          Forum Rules
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

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