Unable to initialize ArcObjects environment

995
1
07-12-2013 05:51 AM
IshanKaushik
New Contributor
Hi,

I build a application in ArcGis engine environment which has bootstrap methord to initialise jar file , and following is code to initialise engine license --

                                      
                                  EngineInitializer.initializeEngine();
   //Initialize ArcGIS license
   AoInitialize aoInit = new AoInitialize();
   initializeArcGISLicenses(aoInit);


But when i try to run this destop application in arcGis destop environment its generating error --



Unable to initialize ArcObjects environment.
AutomationException: 0x800401f5 - The specified product or version does not exis
t on this machine. in 'ArcGISVersion.Version'
 

I have changed variable to "AGSDESKTOPJAVA" and created the ARCGIS-LICENSE-FILE variable too.
Is there anything else to be changed , if not what is the error . The bold part above is where it generates error.
0 Kudos
1 Reply
SachinKanaujia
Occasional Contributor III
If you are using a ArcGIS Desktop packages Engine then only you should use AGSDESKTOPJAVA. It you have ArcGIS Engine setup, you should ideally be setting the AGSENGINEJAVA.

This error typically occurs when you have different versions of ESRI products installed and you are using an Arcobjects which is not compatible. Make sure you check for all the path variables and remove any unnecessary path.

Whats the bootstrap method you are using?
0 Kudos