Quantcast
Channel: Forums - ArcObjects SDKs
Viewing all articles
Browse latest Browse all 1374

Invalid ArcGIS runtime binding. Application will shut down.

$
0
0
Hello,

I have created a ArcGIS console stand alone application using the new project wizard in Visual Studio 2010.

The default code created in the stub was around grabbing a desktop license:

Code:

class Program
    {
        private static LicenseInitializer m_AOLicenseInitializer = new SetCustomMapExtent.LicenseInitializer();
   
        [STAThread()]
        static void Main(string[] args)
        {
            //ESRI License Initializer generated code.
            //m_AOLicenseInitializer.InitializeApplication(new esriLicenseProductCode[] { esriLicenseProductCode.esriLicenseProductCodeBasic, esriLicenseProductCode.esriLicenseProductCodeStandard, esriLicenseProductCode.esriLicenseProductCodeAdvanced },
            //new esriLicenseExtensionCode[] { });

            m_AOLicenseInitializer.InitializeApplication(new esriLicenseProductCode[] { esriLicenseProductCode.esriLicenseProductCodeAdvanced },
            new esriLicenseExtensionCode[] { });
.
.
.
            //Do not make any call to ArcObjects after ShutDownApplication()
            m_AOLicenseInitializer.ShutdownApplication();
        }
    }
}

The problem is that when I compile this stub and run it, I get the error in the subject of this post.

I am running this application on a machine with ArcGIS Desktop 10.1 SP1 with an Advanced license (borrowed) installed on it.

Any help would be appreciated.

Regards,

Mark

Viewing all articles
Browse latest Browse all 1374

Trending Articles