B4A Library Dialogs library

Status
Not open for further replies.
This library contains several modal, that is blocking, dialogs by which the user can enter data. Presently they are an InputDialog for numbers and text, a TimeDialog for times and and a DateDialog for dates.

Note that modal dialogs can close unexpectedly and not return to your code if the Activity needs to close, most likely because the user rotated the device. There is a brief discussion of this in the overall library help in the xml. This can also occur with the Basic4android modal dialogs InputList, InputMultiList, Msgbox and Msgbox2 whose modal mechanism is used by the dialogs in this library.

Edit : - Version 1.1 posted with minor bug fix. See post #6 for details.

Edit : - Version 1.2 posted with Color dialogs. See post #16 for details.

Edit : - Version 1.3 posted with bug fix. See post #19 for details.

Edit : - Version 1.4 posted with a Number dialog. See post #20 for details.

Edit : - Version 1.5 posted with some enhancements. See post #28 for details.

Edit : - Version 1.6 posted with a File Dialog. See post #30 for details.

Edit : - Version 1.7 posted with a minor UI change. See post #33 for details.

Edit : - Version 1.8 posted with a Custom dialog. See post #37 for details.

Edit : - Version 1.9 posted with a bug fix. See post #42 for details.

Edit : - Version 2.0 posted with a bug fix. See post #48 for details.

Edit : - Version 2.1 posted with a second Custom dialog. See post #68 for details.

Edit : - Version 2.2 posted. See post #75 for details.

Edit : - Version 2.3 posted. See post #90 for details.

Edit : - Version 2.4 posted. See post #135 for details.

Edit : - Version 2.5 posted. See post #148 for details.

Edit : - Version 2.6 posted. See post #155 for details.

Edit : - Version 2.7 posted. See post #168 for details.

Edit : - Version 2.8 posted. See post #206 for details.

Edit :- Version 2.91 posted by Mildev. See post #317 for details. His version 2.91 is based on my unpublished v2.9 which set the text box in FileDialog to SingleLine mode.

Edit : - Version 2.92 posted. See post #341 for details.

Edit (Erel): Version 3.00 posted. Developers using B4A v6.80+ should use this version.

V4.01 is released with several improvements: https://www.b4x.com/android/forum/t...-dialogs-and-async-methods.80204/#post-507930

B4A version | Dialogs library version
------------------------------------
7.0+ 4+
6.8 3.00
<6.8 2.92
 

Attachments

  • Dialogs2.92.zip
    59.4 KB · Views: 12,994
  • Dialogs3.00.zip
    48.9 KB · Views: 2,947
  • Dialogs4.01.zip
    72.2 KB · Views: 9,560
Last edited by a moderator:

Amalkotey

Active Member
Licensed User
Longtime User
ProgressDialog already exists in the Core Basic4android keywords.

thank you, that I have read about. Please excuse the excess release
 

vangogh

Active Member
Licensed User
Longtime User
numeric keypad?

I have dialog lib v2.2 so sorry if I miss the new feature

I miss a "numeric keypad", like the one used to compose a telephone number...
numbers 0-9, dot, delete, cancel and OK...
the numeric view I know (I have in my 2.2 lib) uses the "+" and "-" to compose a number...

Am I missing something, or a "numeric pad" is not already present?

thank you
 

agraham

Expert
Licensed User
Longtime User
In version 2.5 now posted FileDialog has grown a ScrollingBackgroundColor property like a ListView.

Also included is a third colour dialog I was playing with that lets you specify a colour by its Hue, Saturation and Value which might sometimes make selecting the right colour easier. I hadn't really intended to publish this but as it was in the library source I let it go through rather than deliberately removing it.
 

agraham

Expert
Licensed User
Longtime User
If you do not set the FileFilter property before you invoke .Show, the dialog crashes the app.
Oops! It's a bug introduced in version 2.4 when I allowed multiple filters to be defined in a comma separated string. For now just initialise FileFilter with an empty string if you don't want filtering.
Is it possible to add an icon for the Folders
I'm not really a UI person so to save thinking about it I used SingleLineLayout from the Basic4android ListView for the file and folder entries so the answer is no for now.
 

thedesolatesoul

Expert
Licensed User
Longtime User
Oops! It's a bug introduced in version 2.4 when I allowed multiple filters to be defined in a comma separated string. For now just initialise FileFilter with an empty string if you don't want filtering.
I'm not really a UI person so to save thinking about it I used SingleLineLayout from the Basic4android ListView for the file and folder entries so the answer is no for now.
Not a problem. :)
 

thedesolatesoul

Expert
Licensed User
Longtime User
Can the Filedialog act as a FolderDialog i.e. just to select a folder rather than a file?
I need the user to select a location, but not a file.

EDIT: Okay, I got around this by using a custom dialog and it was very easy :)
but i have a question...when the dialog opens up, the user doesnt really know which directory he is starting from, should we add the current path to the title or something like that?
 
Last edited:

agraham

Expert
Licensed User
Longtime User
Version 2.6 now posted fixes the bug in introduced 2.5 that crashed FileDialog if a FileFilter was not explicitly specified.

FileDialog now has a ShowOnlyFolders property that if set True will only display the existing folder names and will allow the user to enter a new name for a new folder if required.
 

Inman

Well-Known Member
Licensed User
Longtime User
I have a listview added to a panel inside the customdialog2. I tried to get the Listview_ItemClick to find out the user selected item but it didn't work. Is it not possible to trap events of a view inside customdialog?
 

JesseW

Active Member
Licensed User
Longtime User
I have a listview added to a panel inside the customdialog2. I tried to get the Listview_ItemClick to find out the user selected item but it didn't work. Is it not possible to trap events of a view inside customdialog?

Make sure your not using a msgbox inside the listview event. They don't show until the custom dialog has completed.
 
Status
Not open for further replies.
Top