Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » RCP Testing Tool » [SOLVED] Visit a table line by line (#tables #dynamic variable # visit a table)
icon7.gif  [SOLVED] Visit a table line by line [message #1710674] Thu, 08 October 2015 10:23 Go to next message
Angelo Luciani is currently offline Angelo LucianiFriend
Messages: 129
Registered: September 2015
Location: Milan
Senior Member

Hi folks,
it is not clear to me how to visit a table in automatic way.

I can access a single element using the following portion of code

let [val item [get-property "getParent().getChildren().Control[0].getChildren().Control[3].getItems().TableItem[0].getText()" -raw ]] {
show-alert $item
}

How to use get-table command in this case ?
I wonder If it is not possible to use it.
If not, is it possible to use a loop and insert the index as variable ?

I think to use concat method to update the string but doesn't work for syntax reason.

Example:
loop [val count 0] {
if [$count | lt 18] {

let [val item [get-property [[concat [concat "getParent().getChildren().Control[0].getChildren().Control[3].getItems().TableItem[" [str[$count]] ] "].getText()"] -raw ]]
{
show-alert $item
}

} -else {
recur [$count | plus 1]
}
}



"Ce sont les petits désirs qui rendent un jeune homme hardi."
Giovanni Giacomo Casanova

[Updated on: Thu, 08 October 2015 11:19]

Report message to a moderator

Re: Visit a table line by line [message #1710679 is a reply to message #1710674] Thu, 08 October 2015 11:12 Go to previous message
Angelo Luciani is currently offline Angelo LucianiFriend
Messages: 129
Registered: September 2015
Location: Milan
Senior Member

SOLVED
Hi folks solved the problem the path "getParent().getChildren().Control[0].getChildren().Control[3].getItems().TableItem[" [str[$count]] ] "].getText()" reasults as 'TableItem {07/07/2015 11:53}' name so the right path was under getData().

with [get-view TaskList | get-section "" | get-table] {
get-items | foreach {get-property "getParent().getItems().TableItem[0].getData().getName()" -raw | let [val msg -input]{ Show-alert $msg}}
}
index.php/fa/23480/0/


"Ce sont les petits désirs qui rendent un jeune homme hardi."
Giovanni Giacomo Casanova

[Updated on: Thu, 08 October 2015 11:13]

Report message to a moderator

Previous Topic:How to re-use ECL scripts across multiple projects?
Next Topic:[SOLVED] How get value of first item from table?
Goto Forum:
  


Current Time: Thu Apr 25 04:30:52 GMT 2024

Powered by FUDForum. Page generated in 0.03450 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top