I need to get data from orchestrator queue transaction item (only today data)
You can use get queue items activity…it has filters into you can add date as Cdate(Now.ToString("MM/dd/yyyy") + " 00:00:00")
This will get only today added items
cheers
How to write in output in excel
the output of get queue items is an ienumerable or queue items
Use Build datatable and create a datatable with required number of columns
you can use a for loop and provide the output of get queue items as the in argument and in the for loop properties select the type argument as queueitem
then inside the loop
currentitem.SepcificContent("Keyname").ToString
will give you each value present in queueitem
which can be added to a datatable using add data row
{currentitem.SepcificContent("Keyname1").ToString,currentitem.SepcificContent("Keyname2").ToString}
after the loop use write range and write the datatable to excel
cheers
Can you explain it in code
Where i have to filter in get queue
You can add the from field if you want all the items added only to day
Filter value: Cdate(Now.ToString(“MM/dd/yyyy”) + " 00:00:00")
cheers
Getting option strict on disallows late binding in add data row in array row
Did you add .ToString
If yes then try like this
New Object() {currentItem.SpecificContent("Key1").ToString,currentItem.SpecificContent("Key2").ToString}
And I hope in build datatable you have configured all columns as string datatype
cheers
What is the arqument type for for each
It should be QueueItem
cheers
Getting error as qiven key is not found in the dictionary
Key is the specific content data you added to queeu…it should exactly match with the key given in the queue…please check the key you have given properly…it is case sensitive
cheers
Can you show sample queue and how data like status starttime end type exception type (business/application) is taken using add row
Start time - currentItem.StartTransactionTime
Exception or Success - Currentitem.Status
- Thsi will give failed or success
if failed then you can get the exception type using - Currentitem.ProcessingException.Type
(Not for success you will have thsi as NOthing only for failed this can be used)
So You can use like this for status (When succesfful you will get successful else will get the exception type) If(Currenitem.Status.Equals("Successful"),Currenitem.Status,Currentitem.ProcessingException.Type)
Please try these
If there are any output values that youa re configuring in queue then youc an use Currentitem.Output("Keyname").ToString
(Again these are available only for success items for failed you wont have output values)
Currentitem.LastProcessingOn
- Thsi will give the last time when the queue item is accessed
If you press currentitem.
you will get all the options that are available as well
cheers
For exception reason
currentItem.ProcessingException.Reason
- This will give the reason
Options under processException
cheers
In queue there are around 900 item,but only 100 is getting picked
There is a limit for number of queue items…
What you can do it you can run this in a loop…
And have a counter initialized with 0…
And you have a filter option in get queue items to skip x number of items….so add the counter variable there…
And inside the loop use counter = counter + qulsitems.Count
So the loop runs till the counter reaches maximum and continuously skips the the items that are picked already and gets new 100 items…
So the flow looks like this
- Build datatable
- Initialize a counter = 0
- Do while loop with condition as
qulsiitems.count > 0
…so this makes sure the while loop runs till the retrieved queue items count is >0 - Inside loop use get queue items and add the skip as counter and filter on the from as usual
- Now for loop for on the queue items retrieved
- Inside that add data row
- After the for loop use assign to increment counter
counter = counter + qulsitems.count
Cheers