I'm new to autoit, so this could be a simple question. I'm trying to read the value from the currently selected cell in Excel. I read on the forum and tired to find videos, but I couldn't quite get to it.
This is what I have got so far:
Local $oExcel_1 = _Excel_Open()
Local $var = "C:\Users\Acer\xy"
Local $oWorkbook = _Excel_BookOpen($oExcel_1,$var)
Local $_read1 = _Excel_RangeRead($oWorkbook, Default.Application.ActiveCell.Address)
Whatever I try, I either get an error or it only reads "0".
Thank you very much for any helpful thoughts!
hello sirs, please i created a tool witch get the focused control in a window and play a audio file linked with this controls
e.g buttons, checkBoxes, radios, comboboxes, and others
i know that their is a function that give us the control focus but it return the classNN
i want to get the class name to use it with a switch and
because their are more than class e.g button tbutton timagebutton tnewButton...
please can any one help me to get the class name not the classnn
thanks in advance
I have a program that I'm working on, and I have a button that's supposed to stop a running function, when it's pressed.
However, I cannot get that to work.
I put together a sample script that is set up in the same way:
#include <ButtonConstants.au3> #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> #Region ### START Koda GUI section ### Form= Opt("GUIOnEventMode", 1) Global $Form1 = GUICreate("Form1", 290, 106, 192, 124) GUISetOnEvent($GUI_EVENT_CLOSE, "_Exit") Global $btnStart = GUICtrlCreateButton("Start", 24, 24, 99, 49) GUICtrlSetOnEvent($btnStart, "_Start") Global $btnStop = GUICtrlCreateButton("Stop", 152, 24, 99, 49) GUICtrlSetOnEvent($btnStop, "_Stop") GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### While 1 ;~ $nMsg = GUIGetMsg() ;~ Switch $nMsg ;~ Case $GUI_EVENT_CLOSE ;~ Exit ;~ EndSwitch WEnd Func _Start() Global $bStartFlag = True $num = 1 While $bStartFlag ConsoleWrite($num & @CRLF) Sleep(1000) $num += 1 WEnd ConsoleWrite("Exited loop.." & @CRLF) EndFunc Func _Stop() Global $bStartFlag = False EndFunc Func _Exit() Exit EndFunc
With the code above, while the _Start() func is running, the Stop button doesn't do anything.
I even threw a MsgBox into the _Stop() func, to see if the script was at least accessing the _Stop() func. But that showed that the _Stop() func is not being accessed at all while the _Start() func is running.
I'm sure this is a simple solution that I'm just over looking. But I can't figure out what that solution is lol.
Any help here would be greatly appreciated!
Thank you in advance!
I'm trying to write a script that connects with a VBA/COM API to get the status of a connected phone. I've been looking up and down this forum for tips or other user's experiences, but I can't seem to find anything (even remotely) similar. It shouldn't be so hard to do, however.
Software I'm trying to connect to
I'm trying to integrate CallCenter by using their API, which is documented over here : JustRemotePhone API Reference
Things I've tried
I've tried using ObjCreate but I don't get any result, it always returns the same (negative) error.
#Version 1 tried ObjCreate("JustRemotePhone.RemotePhoneService") #Version 2 tried ObjCreate("JustRemotePhoneCOM.RemotePhoneService") #Version 3 tried ObjCreate("JustRemotePhoneCOM.RemotePhoneService.Application") None of the three versions I tried seem to deliver any result other than a negative error value which basically says that the given class is not valid.
I am starting to get the hang of AutoIt by now, but unmanaged programming languages and object-oriented stuff is still quite a grey zone for me. If anyone could help me 'talk' to this application, I'd be immensely grateful!
Thanks in advance and kind regards from Belgium!
Hello everyone, I am wondering if and how it is possible to connect my AutoIt script to a different email in my outlook. I have two different accounts when I open outlook. The first which my script always connects to is my own email while the second is a group email account. How or can I make the script connect to the second one and access its inbox instead of mine? This is all work related so no funny business here.
Global $oOutlook = _OL_Open() ; Store all the Unread emails into an array Global $aItems = _OL_ItemFind($oOutlook, "*\Outlook-UDF-Test", $olMail, _ "[UnRead]=True", "Subject", "Maintenance Request from Eagle's Nest", "EntryID,Subject", "", 1) ; Display the array of unRead emails If IsArray($aItems) Then ;_ArrayDisplay($aItems, "OutlookEX UDF: _OL_ItemFind - Unread mails") Else MsgBox(48, "OutlookEX UDF: _OL_ItemFind Example Script", _ "Could not find an unread mail. @error = " & @error & ", @extended: " & @extended) EndIf ; Get the number of unread emails Global $numberOfUnRead = UBound($aItems, $UBOUND_ROWS) - 1 ;MsgBox("", "Number of Unread emails", $numberOfUnRead) ConsoleWrite("Number of unread emails: " & $numberOfUnRead & @CRLF) I might be missing some code in the post but my code works It's just so long I don't want to post all 2300+ lines.
Thank you for the help I greatly appreciate this community.