B4A Library Dialogs library

Status
Not open for further replies.

moster67

Expert
Licensed User
Longtime User
compatibility issue with Honeycomb??

I have a user who is using my app running Honeycomb. There was a spinner-issue but this has been resolved with the latest version of B4A (1.6). Now he reports force-close upon selecting an item in a dialog.

My app running on the user's other device running Android 2.2 does not present this problem.

I am still awaiting some more information from this user so I may understand the nature of the problem but I thought I would just ask in the meantime if anyone is aware about compatibiliy-issues with Dialogs running Honeycomb (Samsung Tablet 10.1 - the new one)?
 

boten

Active Member
Licensed User
Longtime User
I just tried the DialogsDemo that comes with the Dialog library. On the emulator the DateDialog displayed Jul 18 2011 and the TimeDialog displayed 10 29 AM (hours value 1-12)
When I run it on the real device (Samsung Galaxy S) it showed the date as 18 Jul 2011 (as per the dateformat on the device's settings) but the time was still showing AM(PM) although my device is set to show 24 hours format.
I realise there is a "Is24Hours" attribute and when set to True shows the TimeDialog in 24 hrs format.
My question is how do I determine, programatically, which time format the phone is set to?

tia,
nbp
 

moster67

Expert
Licensed User
Longtime User
@Erel: thanks but it would be difficult for you to run it (especially the suspected routine) since the app requires a particular satellite-decoder in your network.

@agraham: your information is good to know since you tried it on a Honeycomb-device

I believe the problem is due to a network-routine (and thus a problem in the user's LAN) which is triggered upon selecting an item in the Dialog rather than a Dialog-problem. That's why I hope to get a more detailed report from the user but I thought I would ask anyway if any problems were known (like the spinner-view).

In addition, I have not received any other bug-reports for this issue despite my app has more than 12000 active installs of which 361 installed on honeycomb-devices. Therefore, I hope the issue is depending on something else.
 

moster67

Expert
Licensed User
Longtime User
Good idea! Could also be useful in case of future problems. Thanks.

You could ask your user to install CatLog from the market and to send you a saved system log when the error occurs. That way you might get a stack trace of what's happening.
 

agraham

Expert
Licensed User
Longtime User
My question is how do I determine, programatically, which time format the phone is set to?
With my Reflection library.

B4X:
   Dim Obj1 As Reflector
   Dim args(1) As Object
   Dim types(1) As String   
   args(0) = Obj1.GetContext
   types(0) = "android.content.Context"
   Obj1.Target = Obj1.RunStaticMethod("android.text.format.DateFormat", "is24HourFormat", args, types)
   Msgbox(Obj1.Target,"is24HourFormat")
 

boten

Active Member
Licensed User
Longtime User
thx. worked like charm. Might be useful to incorporate into b4a?
 

Omar

Member
Licensed User
Longtime User
Hello Andrew,

Thank you for this fantastic library, appreciate your efforts to help us.

Just noticed an issue with the DateDialog which I wanted to confirm:

When I enter the date manually with the keyboard the Month and Day value are returned correctly but the Year value returns only the initialized value or the last value selected using the "+" "-" buttons.

I know you have mentioned earlier in the thread regarding the Time Dialog that this is OS related, just curious why the other field are updating and only the Year does not.
 

Widget

Well-Known Member
Licensed User
Longtime User
Agraham,
Very nice dialog library. Congrats.:sign0060:

1) Is there a way for FileDialog's FileFilter to show only files ending in .BMP or .JPG or .PNG? I can only get it to recognize one file extension. I thought I should be able to use ".BMP;.JPG;.PNG" with a ";" delimiting the extensions, but no such luck.

2) It would be nice if the FileDialog had another property FileMustExist that would be set to True to prevent the user from entering a file name that doesn't exist. I have written a sub to do this, but I thought it would be neat if it was self contained in the dialog.

Widget
 

agraham

Expert
Licensed User
Longtime User
Is there a way for FileDialog's FileFilter to show only files ending in .BMP or .JPG or .PNG?
Not at the moment, as the help says "If a filename contains the text of the filter the file will be displayed". I might revisit this sometime soon as it would be a nice addition.

prevent the user from entering a file name that doesn't exist.
I'll think about if I do any changes in future.
 

kkolle

Member
Licensed User
Longtime User
Hi Agraham!

Is it possible to set the title in a TimeDialog when the user changes the time?

When you set a new alarm in the alarm clock you know what I mean (alarm_clock.png)

One more wish:
Is it possible to remove the unnecessary space in the dialogs when no message ist set (timedialog.png)?

B4X:
ret = Td.Show("", "Zeit", "", "Zurück", "Fertig", Bmp)

Thanks!!
 

Attachments

  • alarm_clock.jpg
    12.9 KB · Views: 247
  • timedialog.jpg
    11.1 KB · Views: 228

brainfart

Member
Licensed User
Longtime User
A way to add HTML link into CustomDialog2

Hello.
Can someone advise if there is a simple way to add a HTML link to a dialog box.
The only way I know is adding a label with the right color and underline to make it look like link and then in its click event use intent.

Is there a simpler way to add a link.

Thanks
 

moster67

Expert
Licensed User
Longtime User
I am not sure if it works in the dialog-library but you can try the "linkify"-object using Agraham's reflection-library. I believe Agraham was so kind to even include a demo how to use "linkify".





Inviato dal mio Nexus One usando Tapatalk
 
Last edited:

thedesolatesoul

Expert
Licensed User
Longtime User
Are customdialogs based on the dialogs from the Android SDK here:Creating Dialogs | Android Developers

I ask, because I want to port some dialogs (for eg progress dialog) but I remember reading somewhere that modality is not supported in Java, and B4A implements its own kind of modality for msgbox etc.
 
Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…