Compilation error while displaying Get transaction item output

(6.6 KB)
Hi Team,

I am trying to display the output from get transaction item and got the below compilation error.


Performer.xaml
Dispatcher.xaml (3.9 KB)

Dispatch Excel.xlsx (10.3 KB)

@Parameswari Hi
Please show me what are you trying to write in message box?

Hello,

DownloadedData.SpecificContent(“Deposit”)

@Parameswari show me DownloadedData variable type.

@raja.arslankhan

Hello @Parameswari
you have to try this way
used get queue item activity
take assign activity
create one variable (straccountnumbe)

ex.: straccountnumber = out_TransactionItem.SpecificContent(“AccountNumber”).ToString

then you can able to see it in your message box.

Thanks
Andy

@Parameswari
Try this

DownloadedData.SpecificContent(“Deposit”).ToString

@Andy5

Same error again

strDeposit = DownloadedData.SpecificContent(“Deposit”).ToString

No luck @raja.arslankhan

You don’t have to assign it to a variable. Just put

out_TransactionItem.SpecificContent(“AccountNumber”).ToString

…into the Message Box. Creating extra variables to assign the data to is unnecessary.

Is your Performer.xaml called by Main.xaml and you pass DownloadedData into the Performer from Main? If so, you can’t just run Performer. Downloaded Data will have no value.

That being said, this is not the typical way of doing a dispatcher vs performer. They are usually completely separate automations, separate projects. Not individual XAMLs within one process.

@Parameswari Show us Get Queue Item Properties:

Hi @postwick

I have two different sequences in same project. One is dispatcher and another one is Performer.
For testing purpose, can’t we test like this?

@raja.arslankhan ,

@Parameswari It is supporting Windows Legacy only i think so

Hi @Parameswari
It is working


Remove quotes in Queue Name and try it works

Regards,

1 Like

Checks to do:

  • do you even have a queue item. If your queue is empty at the time you get your transactionitem, the result is an empty object. Validate this by checking your queue, when you run the code a queue item shoud change status from new to in progress.
  • Is the queue item populated with the correct key/value. Calling upon TransactionItem.SpecificContent(“myKey”) gives an error if the key does not exist. This key is very case sensitive. Check your queue item in the orchestrator for it’s values and/or use TransactionItem.SpecificContent.ContainsKey(“myKey”) to check if at runtime you get a value. (dictionary.containsKey retuns a bool)

It’s better to have them as separate processes. This doesn’t impact testing. Want some items in the queue? Run the dispatcher.

1 Like

@Jeroen_van_Loon
Yes, I ran the dispatcher and queue has items.

@raja.arslankhan

Thanks for all your responses.