I've already figured how to understand EDSDK error, but now I want to show an error message instead of manually looking it up in the documentation. Is there a function that would give me a meaningful error message from an error code?
Asked
Active
Viewed 93 times
0
-
Do you mean you want to print out the defined symbol from the EDSDKErrors.h file for a particular error code ? If you can convert the defines to an enum then you can cast the enum value to its underlying type like in this link https://learn.microsoft.com/en-us/dotnet/csharp/language-reference/builtin-types/enum#conversions – aviimaging Jan 28 '20 at 09:26
-
If you don't want to do the conversion to Enum, another not so elegant way may be to parse the .h file and return the error symbol for the corresponding error code. – aviimaging Jan 28 '20 at 09:34
-
Oh, I see. No, I didn't want to do any dancing around it, I just assumed there must be a function that gives you the error message, especially since there is a huge table of errors and messages in the documentation. Conversion from Enum would have also worked for me, especially if error codes were stored in the Enum in the `EDSDK.cs` from the example... Oh well. – elena Jan 28 '20 at 10:18
-
I was looking for a clean solution that doesn't exist. Unless I write it myself, of course. – elena Jan 28 '20 at 10:19