If I just want to call a web service function and have it return a class for me, why does visual studio force me to use the await/async features? I hate them personally. They are not easier to use as microsoft claims (at least not for someone who has never used them). I just simply want to say MyCustomResponse x = this.gl_client.GetCustomResponse(new Request() { }); I don't want to have to write a Task<MyCustomResponse> x = this.GetCustomResponse(...); and have to write an async method for it. That is the worst design I've ever heard of. What am I missing here? Like I want to simulate creating a user on the server side by calling a function.
That is easier then CreateNewUserResponse res = this.gl_client.CreateNewUser();? I'm sorry it's not. In .NET 4.0/regular WPF I can just call the functions synchronously and be happy. Or create a thread if it's super hungry for resources/time.
If you go to the game developer website you can see that indeed Cyril Paciullo is the game director and developer https://www.pluralys.ca/about-us/ and when clicking on his name it lists Messenger Plus! as part of his CV. In case you wondered what happened to Patchou
A difficult position to be in. Either they cater to us users or they cater to news curators to potentially increase traffic. Personally, I wasn't being sarcastic. Hosting a website isn't free, so without traffic this site stops existing, and if you want traffic you have to play the game.
I legitimately thought the title was good. Not because I like it, but because it's the kind of title people will click on. This site needs that.
Question
sathenzar
If I just want to call a web service function and have it return a class for me, why does visual studio force me to use the await/async features? I hate them personally. They are not easier to use as microsoft claims (at least not for someone who has never used them). I just simply want to say MyCustomResponse x = this.gl_client.GetCustomResponse(new Request() { }); I don't want to have to write a Task<MyCustomResponse> x = this.GetCustomResponse(...); and have to write an async method for it. That is the worst design I've ever heard of. What am I missing here? Like I want to simulate creating a user on the server side by calling a function.
Here is what I have to do so far:
private void xCreateNewAccBtn_Click(object sender, RoutedEventArgs e) { Task<CreateNewUserResponse> res = this.GetCreateNewUserResponse(); } async Task<CreateNewUserResponse> GetCreateNewUserResponse() { Task<CreateNewUserResponse> getRes = this.gl_client.CreateNewUserAsync(new CreateNewUserRequest()); CreateNewUserResponse res = await getRes; return res; }That is easier then CreateNewUserResponse res = this.gl_client.CreateNewUser();? I'm sorry it's not. In .NET 4.0/regular WPF I can just call the functions synchronously and be happy. Or create a thread if it's super hungry for resources/time.
Link to comment
https://www.neowin.net/forum/topic/1115287-is-it-just-me-or-do-you-hate-the-new-await-system/Share on other sites
6 answers to this question
Recommended Posts