Fairs points, but would you expect a Bstring using a Check box to crash the app and disappear without any warning?
I know the help docs say
BSTRINGs were designed for use in API functions; they are not suitable for usage as USE variables.
but even so, I wouldnt have expected a crash and app disappearance like that.
Anyway, more digging,
Loc:TestBstring BSTRING
Window Window
CHECK(‘Loc : Test Bstring:’),AT(31,426),USE(Loc:TestBstring),VALUE(‘1’,‘0’)
End
No code to reference the control.
Tried every control going:
Check
Entry
Image
Spin
String
Text
No crash and app disappearance.
Added the 1 to True and 0 to False in the validity checks.
No crash and app disappearance.
Added the variable to group. Repeat above
No crash and app disappearance.
So far, only changing this byte variable in a group causes the crash and app to disappear.
This is what causes a crash and disappear.
Loc:SidNameUse GROUP,PRE(SNU) !
SidTypeUser BSTRING !
SidTypeGroup BYTE !
SidTypeDomain BYTE !
SidTypeAlias BYTE !
SidTypeWellKnownGroup BYTE !
SidTypeDeletedAccount BYTE !
SidTypeInvalid BYTE !
SidTypeUnknown BYTE !
SidTypeComputer BYTE !
SidTypeLabel BYTE !
SidTypeLogonSession BYTE !
END
GROUP('Sid Type (Use)'),AT(357,234,318,83),USE(?grpSidTypeUse),BOXED
CHECK('Sid Type User (1):'),AT(373,246),USE(SNU:SidTypeUser),VALUE('1','0')
CHECK('Sid Type Group (2):'),AT(373,257),USE(SNU:SidTypeGroup),VALUE('1','0')
CHECK('Sid Type Domain (3):'),AT(373,268),USE(SNU:SidTypeDomain),VALUE('1','0')
CHECK('Sid Type Alias (4):'),AT(373,279),USE(SNU:SidTypeAlias),VALUE('1','0')
CHECK('Sid Type Well Known Group (5):'),AT(373,291),USE(SNU:SidTypeWellKnownGroup,,?SNU:SidTypeWellKnownGroup:2), |
VALUE('1','0')
CHECK('Sid Type Deleted Account (6):'),AT(521,246),USE(SNU:SidTypeDeletedAccount),VALUE('1', |
'0')
CHECK('Sid Type Invalid (7):'),AT(521,257),USE(SNU:SidTypeInvalid),VALUE('1','0')
CHECK('Sid Type Unknown (8):'),AT(521,268),USE(SNU:SidTypeUnknown),VALUE('1','0')
CHECK('Sid Type Computer (9):'),AT(521,279),USE(SNU:SidTypeComputer),VALUE('1','0')
CHECK('Sid Type Label (10):'),AT(521,291),USE(SNU:SidTypeLabel),VALUE('1','0')
CHECK('Sid Type Logon Session (11):'),AT(521,302),USE(SNU:SidTypeLogonSession),VALUE('1','0')
END
The only code that refers to the variable and thus control.
IF Loc:UseSidType = 1; SNU:SidTypeUser = 1 Else SNU:SidTypeUser = 0; End
A few minutes ago whilst writing this out, the bstring check box would not even go into the window groupbox, it would go before or after the group box but not in it. But after a procedure exit, CTRL+R and then back into the procedure for a second attempt, it will go into the window group box as a bstring checkbox.
This is the only instance where I can reproduce this local group bstring in window group box as a checkbox crashing the app and it disappearing!
Is that esoteric?
Edit. There just under a 1000 lines of declarations in this one procedure, vars, equates, and the window with a control for nearly every variable. It is a little more complicated than a simple proc, not that it should matter, but you can see what I’ve already tried above to isolate this weirdo of a bug!