2

I found this code to take input through IGxDialog box from a guidebook:

IGxDialog gxd = new GxDialogClass();
gxd.AllowMultiSelect = false;
gxd.ButtonCaption = "Add FileGDB";
gxd.Title = "Add All FeatureClasses inside FileGDB";
gxd.RememberLocation = true;
IGxObjectFilter gxObjFilter = new GxFilterFileGeodatabasesClass();
gxd.ObjectFilter = gxObjFilter;
IEnumGxObject gxEnumObj;
gxd.DoModalOpen(ArcMap.Application.hWnd, out gxEnumObj);
IGxObject gxObj = gxEnumObj.Next();
//getting the address of fileGDB
string fileGDBAddress = gxObj.FullName;

I could not figure how save a feature class through IGxDialog Box, there are no examples on internet with arcobject 10.0

  • An IGXDialog interface has the method DoModalSave have a look at the API help for that. – Hornbydd Jun 22 '17 at 9:00
  • is there any illustrative example available for how to use DoModalSave – Akhil Kumar Jun 22 '17 at 11:30
  • Anything code related and you should be looking at GeoNet, here is a thread from 4 years ago! – Hornbydd Jun 22 '17 at 13:36
  • i read the link and found the code in vb.net tried to covert it to c# but stuck on .DoModalSave(Me.Handle.ToInt32) , coz c# does have handles. – Akhil Kumar Jun 23 '17 at 6:59
  • Just use a zero? – Hornbydd Jun 23 '17 at 7:56

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.