QueuedTask in Visual Basic

679
2
Jump to solution
03-14-2019 08:23 AM
OscarDiago_Alonso
New Contributor III

Hi!

I want to add a File Gedatabase to a project. Most of the documentation is only explained for C# and sometimes I have no idea how to tranlate it to Visual Basic.

I need to translate this code into Visual Basic:

string gdbPath = "@C:\\myDataFolder\\myData.gdb";
var newlyAddedGDB = await QueuedTask.Run(() => {
  //Create the File GDB project item
  var item = ItemFactory.Instance.Create(gdbPath) as IProjectItem;
  //If it is succesfully added to the project, return it otherwise null
  return Project.Current.AddItem(item) ? item as GDBProjectItem : null;
});

How can I create the QueuedTas in Visual Basic?

Tags (1)
0 Kudos
1 Solution

Accepted Solutions
UmaHarano
Esri Regular Contributor

Hi Oscar

Try the Telerik Code converter.  I use that to convert code and it works well.

Thanks

Uma

View solution in original post

2 Replies
UmaHarano
Esri Regular Contributor

Hi Oscar

Try the Telerik Code converter.  I use that to convert code and it works well.

Thanks

Uma

OscarDiago_Alonso
New Contributor III

Thanks! That page is going to help me a lot. This is my first time with vb.net and ArcGIS Pro SDK.

0 Kudos