Quantcast
Channel: Recent Threads — Xamarin Community Forums
Viewing all articles
Browse latest Browse all 204402

await not working for parse

$
0
0

Im trying to use parse for an android app. In my oncreate bundle method, I have copied and pasted this code from xamarin to create a test parse object.

                var obj = new ParseObject("Note");
                obj ["text"] = "Hello, world!  This is a Xamarin app using Parse!";
                obj ["tags"] = new List<string> {"welcome", "xamarin", "parse"};
                await obj.SaveAsync ();

but xamarin says that: Error CS4034: The 'await' operator can only be used within an async lambda expression. Consider marking this lambda expression with the 'async' modifier. (CS4034)

I dont understand why await doesn't work? I am creating a basic application just to get more familiar with parse and xamarin.


Viewing all articles
Browse latest Browse all 204402


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>