Add values to Output Data of queue items




I am trying to add values to queue items thorughout the process. I see from this post:

that you can add in the set transaction status activity. However, i am wondering if i can do this programmatically?
I have tried to add data from a dictionary like this, but its not adding the data to the queue item

progressDictionary As Dictionary(String,Object) = in_TransactionItem.Output

I have also tried the Add Method but something is wrong with the syntax. Can anyone help me on this?