Hello,
I'm trying to convert Β4Α dialog to B4i. But i have some trouble to make them identical.
Below on the left you can see iPhone dialog and right the Android one.
There are 3 float Text Fields in my code and the code is the same
The worst thing is when i click ok button B4i program crash with this message.
So:
1. How can i make to dialogs identical?
2. How to resolve this message?
Thank you very much for your support
I'm trying to convert Β4Α dialog to B4i. But i have some trouble to make them identical.
Below on the left you can see iPhone dialog and right the Android one.
There are 3 float Text Fields in my code and the code is the same
B4A and B4i sub:
Private Sub showDialog
dlgInsSchool.Initialize(Root)
dlgInsSchool.Title = textDlgTitle
dlgInsSchool.TitleBarColor = xui.Color_RGB(83,88,143)
dlgInsSchool.TitleBarHeight = 50dip
dlgInsSchool.BorderColor = xui.Color_RGB(83,88,143)
dlgInsSchool.BorderCornersRadius = 10
Dim p As B4XView = xui.CreatePanel("")
' p = xui.CreatePanel("")
p.SetLayoutAnimated(0, 0, 0, 350dip, 260dip)
p.LoadLayout("dlgSchool")
dlgInsSchool.PutAtTop = True 'put the dialog at the top of the screen
fltSchName.HintText = "School"
fltSchName.HintColor = xui.Color_RGB(83,88,143)
fltSchName.Update
fltSchAddress.HintText = "Address"
fltSchAddress.HintColor = xui.Color_RGB(83,88,143)
fltSchAddress.Update
fltPostOffice.HintText = "POB"
fltPostOffice.HintColor = xui.Color_RGB(83,88,143)
fltPostOffice.Update
Dim rs As ResumableSub = dlgInsSchool.ShowCustom(p, textBtnOK, textBtnNo, textBtnCancel)
fltSchName.RequestFocusAndShowKeyboard
' Dim b As B4XView = dlgInsSchool.GetButton(xui.DialogResponse_Positive)
' b.Height = 30dip
' ValidateFields(fltSchName.Text, fltSchAddress.Text, fltSchKey.Text)
Wait For (rs) Complete (result As Int)
If result = xui.DialogResponse_Positive Then
mSchool.Initialize
mSchool.Put("schname", fltSchName.Text)
mSchool.Put("url", fltSchAddress.Text)
mSchool.Put("hash", fltPostOffice.Text)
End If
End Sub
The worst thing is when i click ok button B4i program crash with this message.
Application_Start
Call B4XPages.GetManager.LogEvents = True to enable logging B4XPages events.
Application_Active
Unexpected event (missing RaisesSynchronousEvents): b4ipage_keyboardstatechanged:
Error occurred on line: 275 (B4XFloatTextField)
Method not found: resumeAsUserSub, target: [_xui=<B4IXUI: 0x600001f64c80>, _buttonsheight=40, _titlebarheight=50
, _buttonwidth=80, _base=<B4XViewWrapper: <B4IPanelView: 0x7fb732740610; frame = (18 20; 354 356); clipsToBounds = YES; alpha = 0; hidden = YES; animations = { opacity=<CABasicAnimation: 0x600001d03620>; }; layer = <CALayer: 0x600001d52660>>>, _backgroundcolor=-11184811
, _overlaycolor=-1442840576, _bordercolor=-11315057, _bordercornersradius=10
, _borderwidth=2, _buttonscolor=-11184811, _buttonstextcolor=-7744001
, _background=<B4XViewWrapper: <B4IPanelView: 0x7fb73273fd80; frame = (0 0; 390 753); clipsToBounds = YES; gestureRecognizers = <NSArray: 0x6000013417a0>; layer = <CALayer: 0x600001d5ffc0>>>, _blurimageview=<B4XViewWrapper: (null)>, _blurbackground=0
, _blurreducescale=3, _mparent=<B4XViewWrapper: <B4IPanelView: 0x7fb734013850; frame = (0 0; 390 753); layer = <CALayer: 0x600001d43940>>>, _title=Insert School
, _titlebarcolor=-11315057, _titlebartextcolor=-1, _bodytextcolor=-1
, _titlebar=<B4XViewWrapper: <B4IPanelView: 0x7fb732741090; frame = (2 2; 350 50); clipsToBounds = YES; layer = <CALayer: 0x600001d2c200>>>, _putattop=1, _titlebarfont=<B4XFont: <UICTFont: 0x7fb7327182e0> font-family: ".SFUI-Semibold"; font-weight: bold; font-style: normal; font-size: 16.00pt>
, _buttonsfont=<B4XFont: <UICTFont: 0x7fb73400ed60> font-family: ".SFUI-Semibold"; font-weight: bold; font-style: normal; font-size: 15.00pt>, _buttonstextcolordisabled=-8355712, _visibleanimationduration=100
, _buttonsorder=<B4IArray: 0x600001348000>, _buttonsstate=NSMapTable {
}
, _dateutils=<b4i_dateutils: (null)>
, _main=<b4i_main: (null)>, _b4xpages=<b4i_b4xpages: (null)>, _b4xcollections=<b4i_b4xcollections: (null)>
, _xuiviewsutils=<b4i_xuiviewsutils: (null)>]
Stack Trace: (
CoreFoundation __exceptionPreprocess + 242
libobjc.A.dylib objc_exception_throw + 48
CoreFoundation -[NSException initWithCoder:] + 0
myDialogs +[B4I runDynamicMethod:method:throwErrorIfMissing:args:] + 342
myDialogs -[B4IShell runGoodChain::] + 330
myDialogs -[B4IShell raiseEventImpl:method:args::] + 2509
myDialogs -[B4IShellBI raiseEvent:eventarams:] + 1358
myDialogs -[B4IDelegatableResumableSub resume::] + 375
myDialogs __21-[B4ICommon Sleep:::]_block_invoke + 45
libdispatch.dylib _dispatch_client_callout + 8
libdispatch.dylib _dispatch_continuation_pop + 482
libdispatch.dylib _dispatch_source_invoke + 2079
libdispatch.dylib _dispatch_main_queue_callback_4CF + 848
CoreFoundation __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 9
CoreFoundation __CFRunLoopRun + 2772
CoreFoundation CFRunLoopRunSpecific + 567
GraphicsServices GSEventRunModal + 139
UIKitCore -[UIApplication _run] + 928
UIKitCore UIApplicationMain + 101
myDialogs main + 104
dyld start_sim + 10
??? 0x0 + 4649776414
)
So:
1. How can i make to dialogs identical?
2. How to resolve this message?
Thank you very much for your support
Last edited: