Hi I am currently evaluating Imageman.Net, in fact building a scanning interface to drive a Inotec document scanner for my company, but I'm having a little trouble with using the SupportedCaps as I would like to save the current scanner configuration to a XML file.
I'm not sure on how to use DTI.ImageMan.Twain.Array type from when I return this from the DTI.Imageman.Twain.Capabilities object, I just can't get my head around how to get the values out, I understand how setting and getting capabilities work.
Are you using C# or VB.Net ?
Let me know and I'll get you some sample code.
Using C#, I was reading you can use this like an enum but I'm still lost I thought about trying to convert it to a system array, and even trying through reflection I could get the count of the items just not at the items.
Here's some sample code that will unpack the returned array items:
bool retval = twainControl1.GetCapability(Capabilities.SupportedCaps, out obj, out type);
DTI.ImageMan.Twain.Array ary = (DTI.ImageMan.Twain.Array)obj;
for (int i = 0; i < ary.Count; i++)
foreach (Object o in ary.Items)
Console.WriteLine("Got an Array");
Console.WriteLine("Got a " + type.ToString());
Note that the DTI.ImageMan.Twain.Array itself contains a System.Array (.Items) which contains the actual data items. Hopefully this makes sense, let me know if you have any other questions.
Thanks for your interest in our products and please let us know if you have any questions.
Data Techniques Support
That worked a treat I can see the capabilties :), thankyou for your help.
You're welcome, pls let us know if you have any other questions.
Data Techniques, Inc.
This question is closed to new answers.