I went to compile my program for windows and mac, and when I do just mac, everything builds fine.
When it gets to the windows part, I get this error:
winMain.pushGenerateCode.Action, line 8
Type mismatch error. Expected Int64, but got enum CheckBox.VisualStates
select case int64(checkLowerCase.VisualState)
What is the difference? And how do I fix it?
I have tried with targetOS.Windows, but it is a no go.
Try doing the select case over the enum returned in CheckBox.visualState, or cast to integer which is auto converted to 32 or 64 based on architecture.
select case checkLowerCase.VisualState
case CheckBox.VisualStates.Checked
case CheckBox.VisualStates.UnChecked
case CheckBox.VisualStates.Indeterminate
end select
Where you building 32bit windows version, or 64bit version? macOS is 64bit only, so all enums would be int64. Using integer is safest way as it is int32 on 32bit builds and int64 on 64bit builds.
If you can just use the enum value itself, easier to read and follow your code later.
I looked at the Build Settings for Windows, which had somehow “flipped” to 32 bit. I normally always have it as 64 bit, because as was quoted, my Mac is 64 bit. Will watch and advise.