I'm compiling some of my FEMAP APIs using the Visual Basic. I realized that the FEMAP constants in Visual Basic can't be inserted alone; It's necessary to insert before them the constant's type. For instance, in the command feAppMessage, instead of using simply FCM_NORMAL to indicate the font's color, you must insert zMessageColor.FCM_NORMAL.
In the most constants, a suggestion box brings the constant'S type, but I can't find out what I must use with global constants, like FE_OK, FE_ERROR, FE_CANCEL, and so on. Could anybody help me with this issue?
Note: I read in FEMAP API Documentation that a file, named api.bas located in FEMAP installation directory should be inserted into the code for making the FEMAP constants available in Visual Basic. I searched for, but can't find this file. If somebody has this file it would helpful attach it here.
Solved! Go to Solution.
see my attached small macro (it delete curves with associated points), I use constants like FCM_COMMAND, FCM_NORMAL, FT_CURVE, FT_POINT, FE_OK without problem.
When I want to write this macro in Visual Basic, I can add the following lines to the beginning of code, and I can use for example the constant name FE_OK instead of femap.zReturnCode.FE_OK:
When you use other constants too, you can find its member with Object Browser in Visual Basic.
I've the same issue as Fabiano, a missing API.bas file. Names of constants are listed in the manual, but not the values. I'm programming in Excel VBA, utilizing the suggested Imports does not seem to work. I'd be most appreciative is someone would post the API.bas file.