Select to view content in your preferred language

await operator Error!

1433
0
10-24-2014 04:01 PM
BehzadRouhieh
New Contributor

I am trying to open a geodatabase. I use this systax, as provided in the developer's website:

 

Geodatabase gdb = await Esri.ArcGISRuntime.Data.Geodatabase.OpenAsync(@"C:\WildlifeLocal.geodatabase");

 

I have the geodatabase file at this location and have imported Esri.ArcGISRuntime.Data library at the beginning.

However, the compiler returns this error:

 

 

Error1The 'await' operator can only be used within an async method. Consider marking this method with the 'async' modifier and changing its return type to 'Task'.

 

Any idea why I receive this error!?

0 Kudos
0 Replies