Hi all,
using B4A 12.8 I have a simple Preferences Dialog:
To get more space for the german 'Abbrechen' (what means Cancel) I set a listener:
At the event I fetch a reference for the buttons and set the distance:
When the dialog opens everthing works fine (see scrennshot).
Clicking on the date (23.09.202) should open a date selection dialog.
But the app crashes, it runs again into PrefDialog_BeforeDialogDisplayed and there is no btnOk found.
Any suggestions do avoid this?
Second question, how to get a reference to the date label, to display the whole date? (Not 23.09.202)
Thanks in advance,
Bernhard
using B4A 12.8 I have a simple Preferences Dialog:
To get more space for the german 'Abbrechen' (what means Cancel) I set a listener:
B4X:
PrefDialog.SetEventsListener(Me,"PrefDialog")
At the event I fetch a reference for the buttons and set the distance:
B4X:
Private Sub PrefDialog_BeforeDialogDisplayed (Template As Object)
Dim btnCancel As B4XView = PrefDialog.Dialog.GetButton(xui.DialogResponse_Cancel)
btnCancel.Width = btnCancel.Width + 20dip
btnCancel.Left = btnCancel.Left - 20dip
Dim btnOk As B4XView = PrefDialog.Dialog.GetButton(xui.DialogResponse_Positive)
btnOk.Left = btnOk.Left - 20dip
When the dialog opens everthing works fine (see scrennshot).
Clicking on the date (23.09.202) should open a date selection dialog.
But the app crashes, it runs again into PrefDialog_BeforeDialogDisplayed and there is no btnOk found.
Any suggestions do avoid this?
Second question, how to get a reference to the date label, to display the whole date? (Not 23.09.202)
Thanks in advance,
Bernhard