B4J Question [B4X] DateListview

aeric

Expert
Licensed User
Longtime User
This library is still working in progress. I am learning to create a B4X library for date picker with CustomListview. The result is still not I expected.
The code to draw the calendar is based on B4XDateTemplate of XUI View.
Can anyone help to fix the panel resize and selected date?
How can I color the date without being cleared when I move my mouse pointer?
How can I set/color more than 1 date?

1626363176943.png
 

Attachments

  • B4XDateListview.bas
    8.2 KB · Views: 276
  • jxDateListview.b4xlib
    12.4 KB · Views: 303
  • Example.zip
    2.3 KB · Views: 300

Andrew (Digitwell)

Well-Known Member
Licensed User
Longtime User
Solution to first problem.

I needed to create a canvas to draw the highlighted date on.

This then needs to be cleared etc as appropriate.

Multiple dates is a bit trickier...

You will need to start by keeping a list of selected dates and perhaps a list of canvas for these dates.

Edit: for spelling
 

Attachments

  • B4XDateListview.bas
    9.2 KB · Views: 1,625
Last edited:
Upvote 0

Andrew (Digitwell)

Well-Known Member
Licensed User
Longtime User
Now supports lists.

Bugs:
  • Doesn't show initially selected date
  • does not discard canvas once created. I can forsee a problem with this.
You'll need to update getDate etc to support lists of dates also.
 

Attachments

  • B4XDateListview.bas
    10.5 KB · Views: 303
Upvote 0
Top