AnsweredAssumed Answered

How to know ArcGis version in C#

Question asked by momobjk on Oct 30, 2012
Latest reply on Oct 30, 2012 by momobjk

I have a problem since the last version of ArcGis, the 10.1, was released.

My problem is the following :

When using the DataManagement Clip tool, there's a parameter named nodata_value which was a Double in ArcGis 10 and now it's a string. So when someone uses my program with ArcGis 10.1, he gets this error : System.MissingMethodException: Method not found: 'Void ESRI.ArcGIS.DataManagementTools.Clip.set_nodata_value(Double)'.
ArcGis 10.1 :
ArcGis 10.0 :

So a solution may be to check the current version of ArcGis and give the good parameter :
   nodata_value = myDoubleValue.ToString();
   nodata_value = myDoubleValue;

But I don't know how to recognize in which version I am.

Thank you for your help.

M. Ciftci