0
I have following code:
List<UserItem> items = null;
Task taskCreateItems = new Task(() => items = DeliverItems(Session, Item.GetBaseItem(i), (priceAmount * ((Item.Items.Count > 1) ? Item.Items[i] : Item.Amount)), ExtraData, (Page.MinRank > 1), Item.songID));
taskCreateItems.Start();
This is the old code:
var items = DeliverItems(Session, Item.GetBaseItem(i), (priceAmount * ((Item.Items.Count > 1) ? Item.Items[i] : Item.Amount)), ExtraData, (Page.MinRank > 1), Item.songID));
With old code I could get what was returned, eg items.Count, items[0], but in new code using Task I don’t know how to do this.
You look like this doesn’t solve what you expect it to solve, but you tried
taskCreateItems.Result
?– Maniero