You don't need to.
In this code you posted:
bStateuserID.Click += async delegate
{
details.Text=" ";
Guid x = new Guid("33F8A8D5-0DF2-47A0-9C79-002351A95F88");
state OStateUserID =(state) await obj.GetStateByUserId(x.ToString());
details.Text = OStateUserID.name + "\n" + OStateUserID.population);
};
The line
details.Text = OStateUserID.name + "\n" + OStateUserID.population);
is already running on the UI thread.
I have an async
intro on my blog that explains this behavior.