I haven't tried it yet but seems like instead of using this-:private Queue<IGPProcess> _myGPToolsToExecute = new Queue<IGPProcess>(); ... _myGPToolsToExecute.Enqueue(bufferTool); _myGPToolsToExecute.Enqueue(clipTool); _gp.ExecuteAsync(_myGPToolsToExecute.Dequeue()); why not this -private Queue<string> _myGPToolsToExecute = new Queue<string>(); private Queue<IVariantArray> _myGPToolsParams = new Queue<IVariantArray>(); ... _myGPToolsToExecute.Enqueue(bufferTool); _myGPToolsParams .Enqueue(bufferParams); _myGPToolsToExecute.Enqueue(clipTool); _myGPToolsParams .Enqueue(clipParams); _gp.ExecuteAsync(_myGPToolsToExecute.Dequeue(),myGPToolsParams.Dequeue());
private Queue<IGPProcess> _myGPToolsToExecute = new Queue<IGPProcess>(); ... _myGPToolsToExecute.Enqueue(bufferTool); _myGPToolsToExecute.Enqueue(clipTool); _gp.ExecuteAsync(_myGPToolsToExecute.Dequeue());
private Queue<string> _myGPToolsToExecute = new Queue<string>(); private Queue<IVariantArray> _myGPToolsParams = new Queue<IVariantArray>(); ... _myGPToolsToExecute.Enqueue(bufferTool); _myGPToolsParams .Enqueue(bufferParams); _myGPToolsToExecute.Enqueue(clipTool); _myGPToolsParams .Enqueue(clipParams); _gp.ExecuteAsync(_myGPToolsToExecute.Dequeue(),myGPToolsParams.Dequeue());
I'm still curious about my 2 questions re: converting the .tbx to a DLL though if anyone has thoughts on that.
Is there a way to control the .Net version the DLL is compiled against?
Why not write a small class MyTool with 2 public properties string Name and IVariantArray Parameters, and then define the queue as Queue<MyTool>?
I also observe that the tool DLL uses the .NET runtime 4.0, but what's worse in my case is that the assembly builder seems to hardcode the toolbox location into the DLL. Therefore, if you move the toolbox somewhere else, the DLL won't help you any more.
Los miembros registrados pueden publicar, seguir actualizaciones y más. ¿Nuevo aquí? Regístrate gratis.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.