Blog

Error: arcgis product not specified. you must first bind to an arcgis version prior

Posted by Yogesh Sharma Blogs | ArcObject Oct 22, 2012
This blog shows how to resolve error "arcgis product not specified. you must first bind to an arcgis version prior".
Solution- 

When we migrate our code from ArcGis 9.3 to ArcGis 10 then this type of error occurs. 
  1. First we add Reference ESRI.ArcGis.ADF.Local
  2. Add Reference ESRI.ArcGis.Version
  3. Add Line  

    ESRI.ArcGIS.RuntimeManager.Bind(ESRI.ArcGIS.ProductCode.Desktop); 

    prior to call any arcgis object. 

  4. In all ArcGis Reference property "Specific Version" set to false.
  5. Now Go to Project menu of visual studio and there are one option "Add ArcGis License Checking" and Add this file to your project. 
Now your error has been removed.
post comment
     
COMMENT USING
PREMIUM SPONSORS
DynamicPDF™ product line allows you to dynamically generate PDF documents, merge PDF documents and add new content to existing PDF documents from within your applications.
Get Career Advice from Experts
SPONSORED BY
  • PDF reports have never been easier to create. With our included WYSIWYG Designer, you can layout your reports, set up your data source and let DynamicPDF ReportWriter do the rest.
Join a Chapter