-
Recently Browsing 0 members
No registered users viewing this page.
-
Similar Content
-
By phoenixhuynh09
Hi everybody
Currently I need to tick a checkbox that runs on IE. But I can't click on it. Although the correct object has been specified. Here is my code:
#include <IE.au3> $oIE = _IEAttach("WEB") $oLinks = _IETagNameGetCollection($oIE, 'span') For $oLink In $oLinks $a = String($oLink.classname) == 'x-column-header-text' $b = StringLeft(String($oLink.id), 10) == 'gridcolumn' If $a And $b Then _IEAction($oLink, "click") ConsoleWrite("Founded" & @CRLF) ExitLoop Else ConsoleWrite("Not Found" & @CRLF) EndIf Next After inspecting the element it shows only 1 line of code:
<div class="x-column-header x-column-header-checkbox x-column-header-align-left x-box-item x-column-header-default x-unselectable x-column-header-first x-grid-hd-checker-on" id="gridcolumn-1588" style="margin: 0px; left: 0px; top: 0px; width: 24px; right: auto; border-top-width: 1px; border-bottom-width: 1px; border-left-width: 1px;"> <div class="x-column-header-inner" id="gridcolumn-1588-titleEl"> <span class="x-column-header-text" id="gridcolumn-1588-textEl"></span> </div> </div> Here is an image of the checkbox:
I used more ways to check:
- _IEGetObjById => IEAction($oLink, "click") not working
- _IETableGetCollection => _IETableWriteToArray gives an error
- _IEImageClick
All are not working.
Hope to get a response from everyone.
Thank you very much.
-
By VinMe
Dear all,
I am working on automation of ms word, on which my scripts runs with multiple word document at a time. But I wanted all the word to be running in the background.
do we have any UDF available? Please help.
BR,
VinMe
-
By jmp
Hello.
I have IETable,
Get by this code
$oTable = _IETableGetCollection ($oIE, 1) $aTableData = _IETableWriteToArray ($oTable) Local Const $iArrayNumberOfCols = UBound($aTableData, $UBOUND_COLUMNS) Local Const $iArrayNumberOfRows = UBound($aTableData, $UBOUND_ROWS) Local $aArraySubstringsRow[$iArrayNumberOfCols] ;~ Local $aExtract = _ArrayExtract ($aTableData, 1, 1, 1, -1) ;~ MsgBox(0, "", $iArrayNumberOfCols) ;~ _ArrayDisplay($aExtract) Local Const $iArrayRowIndex = 1 Local $sSubstring For $i = 0 To $iArrayNumberOfCols - 1 $sSubstring = StringLeft($aTableData[$iArrayRowIndex][$i], 2) $aArraySubstringsRow[$i] = $sSubstring Next _ArrayDisplay($aArraySubstringsRow, "This is a row") and i want to use cell (52, 82, 18, 9,...10) one by one for selecting dropdown box in internet explorer.
So, How to show/get/extract cell one by one (in msgbox)?
-
By diff
Hello,
so I have started to learn to use the Word UDF and got issue to add my pictures after exact paragraphs. I was searching in the forum for the solution, checked with examples and still I don't understand how to add pictures after paragraph in new line.
My word document has like 8 pages and for example on page I have paragraph named "My examples:" and here starts my problem.
I have tried to do this:
#include <Word.au3> Local $oWord = _Word_Create() Local $oDoc = _Word_DocOpen($Word, @ScriptDir & "\examples.docx", Default, Default, True) $oSearchRange = _Word_DocRangeSet($oDoc, -1, $wdParagraph, 0) $oRangeFound = _Word_DocFind($oDoc, "My examples:", $oSearchRange) _Word_DocPictureAdd($oDoc, @ScriptDir & "\pic1.jpg", Default, Default, $oRangeFound) And here the picture adds before the paragraph My examples: on same line and looks like
{pic1}My Examples:
What I want to see is:
My examples:
{PICTURE IN NEW LINE} which is pic1.jpg from my code.
How I can do that? I want to add 3 pictures in a row in new line each like:
My examples:
{pic1.jpg}
{pic2.jpg}
{pic3.jpg}
Hope I explained this well, but you can ask me if you need any additional information to clarify.
-
By ahha
I'm trying to get the number of columns in a specific row in a Word table and am stuck. I need a push. Program below and Word file attached.
Thanks.
#AutoIt3Wrapper_run_debug_mode=Y ;use this to debug in console window #include <Word.au3> $oWord = _Word_Create(True, True) ;Create Word application object, make it visible, and force a new instance of Word $oDoc = _Word_DocOpen($oWord, @ScriptDir&"\ColumnTest.docx", Default, Default, True) ;Open the Word document $iTablesCount = $oDoc.Tables.Count ;get Tables count in $oDoc Pause("$iTablesCount = '" & $iTablesCount & "'") $iRowCount = $oDoc.Tables.Item(1).Rows.Count ;Table hard coded $iColCount = $oDoc.Tables.Item(1).Columns.Count Pause("Table#1 $iRowCount = '" & $iRowCount & " $iColCount = '" & $iColCount & "'") ;trying to get the number of columns in each row ;$ColCountInRow = $oDoc.Tables.Item(1).Rows(1).Columns.Count ;this fails and read somewhere to use Cells.Count $ColCountInRow = $oDoc.Tables.Item(1).Rows(1).Cells.Count ;hard code Row 1 <<<<< ERROR here ;this is the error I get ;: ==> The requested action with this object has failed.: ;$ColCountInRow = $oDoc.Tables.Item(1).Rows(1).Cells.Count ;$ColCountInRow = $oDoc.Tables.Item(1)^ ERROR Pause("Row 1 has " & $ColCountInRow & " Columns") Exit Func Pause($text="") MsgBox(262144, "DEBUG", "Paused: " & $text) EndFunc
ColumnTest.docx
-
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now