Jump to content
Zacchhh

New to AutoIt and Can't Figure Out Where Code is Going Wrong

Recommended Posts

Zacchhh

I recently got autoit to help automate my shopping but for some reason after a certain line things are no longer working. I added the _IELoadWait command but it didn't change anything so I figured it was something about the code afterwards, but no changes are changing the results. Help, Thanks.

 

#include <IE.au3>
#include <MsgBoxConstants.au3>
#include <GUIConstantsEx.au3>

Global $oIE = _IECreate ("Link")

_IELinkClickByText($oIE, "Item", 1)

_IELoadWait($oIE)

$oSize = _IEGetObjById($oIE, "cctrl")
$oSizeSelect = _IETagNameGetCollection($oSize, "select", 0)
_IEFormElementOptionSelect($oSizeSelect, "Medium", 1, "byText")

$oButtons = _IETagNameGetCollection ($oIE, "button")
For $oButton In $oButtons
    If $oButton.type = "add to cart" Then _IEAction($oIE, "click")
Next

Share this post


Link to post
Share on other sites
Jos
3 hours ago, Zacchhh said:

Help, Thanks.

Welcome,

I am wondering why you think we would be able to help when you're just it isn't working anymore and post code we can't test with ourselves?

Jos


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

Share this post


Link to post
Share on other sites
Zacchhh
14 hours ago, Jos said:

Welcome,

I am wondering why you think we would be able to help when you're just it isn't working anymore and post code we can't test with ourselves?

Jos

Sorry about that, I figured there would be something in the code that you guys could recognize that I can't because I am new. What would you like me to include to better your understanding?

Share this post


Link to post
Share on other sites
careca

Why remove the link?


Spoiler

Paster - Main function is to paste text, but has more functions.

OpenW - Open With... alternative, Open any file with any application, set it's icon, set application as default.

Renamer - Rename files and folders, remove portions of text from the filename etc.

BeatsPlayer - Music player.

Params Tool - Right click an exe to see it's parameters or execute them.

Regedit Control - Registry browsing history, quickly jump into any saved key.

Time4Shutdown - Write the time for shutdown in minutes.

Power Profiles Tool - Set a profile as active, delete, duplicate, export and import.

Firefox Profile Backup - Backup/restore previously saved profile.

Finished Task Shutdown - Shuts down pc when specified window/Wndl/process closes.

NetworkSpeedShutdown - Shuts down pc if download speed goes under "X" Kb/s.

IUIAutomation - Topic with framework and examples

Au3Record.exe

Share this post


Link to post
Share on other sites
Zacchhh
3 hours ago, careca said:

Why remove the link?

Because the item and link varied due to different sections and items on the website and I didn't think it would have a major effect on the code. I can include it if it is needed.

Share this post


Link to post
Share on other sites
Jos
9 hours ago, Zacchhh said:

What would you like me to include to better your understanding?

maybe: Something that actually does run and we can test with to see what is going wrong?

Jos


Visit the SciTE4AutoIt3 Download page for the latest versions  - Beta files                                How to post scriptsource        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

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.