title: How to make a html element show a value after a grpc call(or other async method) with blazor?
body: <p>I'm testing with blazor and grpc, and I'm trying to follow this tutorial(<a href="https://www.youtube.com/watch?v=ynZlJ3pACpI" rel="nofollow noreferrer">https://www.youtube.com/watch?v=ynZlJ3pACpI</a>) which seems to be outdated. Either way, with some adaptations it should work, even because there aren't out there many examples or tutorials.
  The problem is that the value on the html element is not updated with the grpc response.</p>
  <p>I'm supposed to have this:</p>
  <pre><code>@page &quot;/greeter&quot;
  @inject GrpcService1.GreeterService GreeterService1
  
  @using BlazorApp1.Data
  
  &lt;h1&gt;Grpc Connection&lt;/h1&gt;
  
  &lt;input type=&quot;text&quot; @bind=&quot;@Name&quot; /&gt;
  &lt;button onclick=&quot;@SayHello&quot;&gt;Button&lt;/button&gt;
  
  &lt;p&gt;@Greetmsg&lt;/p&gt;
  
  @code {
      string Name;
      private string Greetmsg;
  
      async void SayHello()
      {
          this.Greetmsg = await this.GreeterService1.SayHello(this.Name);
      }
  
  }
  </code></pre>
  <p>But something may had been updated because I cannot call the SayHello method that way. I must put the @ before the Onclick, otherwise I get the error &quot;Cannot convert method group to no delegate type&quot;.
  So I put it like this:</p>
  <pre><code>&lt;button @onclick=&quot;SayHello&quot;&gt;Button&lt;/button&gt;
  </code></pre>
  <p>This way it works but the result I get from the grpc server only shows up when pressing the button for the next request. I followed the code execution and the request is made, the response comes, but the value on the page isn't updated. Then the code execution ends and still no update. When I press the button for a new request the value somehow is updated.</p>
  <p>I also added another button</p>
  <pre><code>&lt;button @onclick=&quot;SayHello&quot;&gt;SayHello&lt;/button&gt;
  &lt;button @onclick=&quot;updateGreetmsg&quot;&gt;updateGreetmsg&lt;/button&gt;
  </code></pre>
  <p>With an empty function below the other one</p>
  <pre><code>    public void updateGreetmsg()
      {
  
      }
  </code></pre>
  <p>And it is enough to call that function to the earlier received value get shown.
  So the await thing is not working in the first function, where it is supposed to.</p>
  <p>Anyone knows how to solve this?</p>