I am using ventuz remoting 4 in my remoting app. I am in a scenario where I am clicking next and previous on a counter but each time I change the counter through my app I would like to get the index back to my app but if I do not use a sleep after the first async method the index that I get back is incorrect. Would I like to get the current index (after execution) without sleeping? Are these method fully async? I also try setting the async state to true but the index is still incorrect.
private async void MainIndexPrevPopup(object sender, RoutedEventArgs e)
{
try
{
// This invoke the prev on the counter node
await this._LocalCluster.DataItem(this._LocalSceneIID.IID.Value, ".MainIndex.MainPopupPrevious", null, null, null);
System.Threading.Thread.Sleep(500);
// Gets the index of the counter from the ventuz into my app
object o = await this._LocalCluster.DataItem(this._LocalSceneIID.IID.Value, ".MainIndex.MainIndexPopupCurrentIndex", null);
}
catch (Exception ex)
{
LogFileController.WriteCurrentErrorOrWarningToXmlFile(ex.Message, "MainIndexPrevPopup");
}
}
Hello Ventuzians!
THE FORUMS ARE CLOSED!
Please join our discord server HERE!! << click me
We are shutting our Ventuz Forum, but don't worry, it will all be archived for you to search in if you have a query. From now on, please add all your comments, questions or observations into our Discord Server
Thanks for the great time - see you on discord!!
Dee, Karol, Daniel and the whoooole Product and Support team!
THE FORUMS ARE CLOSED!
Please join our discord server HERE!! << click me
We are shutting our Ventuz Forum, but don't worry, it will all be archived for you to search in if you have a query. From now on, please add all your comments, questions or observations into our Discord Server
Thanks for the great time - see you on discord!!
Dee, Karol, Daniel and the whoooole Product and Support team!
How to turn on async on the dataItem function in remoting 4
Moderator: Support
-
- Posts: 35
- Joined: 30 Oct 2015, 19:19