[B4X] [XUI] [Old] AS CalendarAdvanced 📅 - OneRow/FiveRow Calendar - Expand and Collapse [Payware]

Alexander Stolte

Expert
Licensed User
Longtime User
Update
  • 2.12
    • Add set HeaderColor
    • Add set BodyColor - the complete calendar is rebuilt at the action
    • Add set BottomColor
    • Add set OtherMonthBackgroundColor - the complete calendar is rebuilt at the action
Example:
B4X:
ASCalendarAdvanced1.HeaderColor = xui.Color_Blue
ASCalendarAdvanced1.BodyColor = xui.Color_Blue
ASCalendarAdvanced1.BottomColor = xui.Color_Blue
ASCalendarAdvanced1.OtherMonthBackgroundColor = xui.Color_Red
 

imbault

Well-Known Member
Licensed User
Longtime User
In the next few weeks the following things will be done:
  • Performance improvements
    • a slimmed down variant of lazy loading, since many pages lead to considerable performance losses
  • BugFixing if any are available ;)
  • ✅ You can set a range of months (start and end)
  • All important functions are moved to a separate module
  • The normal ASCalendar View is published, which works without ViewPager
    • Here's what it makes possible:
    • View attachment 117182
    • You can place the normal ASCalendar view in a list as many times as you want
    • All features and functions from the advanced version are available in the normal version thanks to its own module and I only need to extend a codebase
Dear Alexander,

How to have Month name and year on the top of the calendar, is this a property?

Thanks

Patrick
 

Alexander Stolte

Expert
Licensed User
Longtime User
How to have Month name and year on the top of the calendar, is this a property?
no, it's just a label above the view.
"xbblbl_current_month" is this label.
In this case it is a BBCodeLabel.
B4X:
Private Sub ASCalendarAdvanced1_VisibleRangeChange(StartDate As Long,EndDate As Long)

    Dim p As Period
    p.Days = 8
   
    xbblbl_current_month.Text = $"[b]${DateUtils.GetMonthName(DateUtils.AddPeriod(StartDate,p))} [color=#2D8879]${DateTime.GetYear(DateUtils.AddPeriod(StartDate,p))}[/color][/b]"$
End Sub
 

imbault

Well-Known Member
Licensed User
Longtime User
no, it's just a label above the view.
"xbblbl_current_month" is this label.
In this case it is a BBCodeLabel.
B4X:
Private Sub ASCalendarAdvanced1_VisibleRangeChange(StartDate As Long,EndDate As Long)

    Dim p As Period
    p.Days = 8
 
    xbblbl_current_month.Text = $"[b]${DateUtils.GetMonthName(DateUtils.AddPeriod(StartDate,p))} [color=#2D8879]${DateTime.GetYear(DateUtils.AddPeriod(StartDate,p))}[/color][/b]"$
End Sub
Dear Alexander,

Can you please send me code project of :

1627593561064.png


Thanks

Patrick
 

Alexander Stolte

Expert
Licensed User
Longtime User
Can you please send me code project of
No, because this is a image from the internet as inspiration.
no, it's just a label above the view.
"xbblbl_current_month" is this label.
In this case it is a BBCodeLabel.
B4X:
Private Sub ASCalendarAdvanced1_VisibleRangeChange(StartDate As Long,EndDate As Long)

Dim p As Period
p.Days = 8

xbblbl_current_month.Text = $"[b]${DateUtils.GetMonthName(DateUtils.AddPeriod(StartDate,p))} [color=#2D8879]${DateTime.GetYear(DateUtils.AddPeriod(StartDate,p))}[/color][/b]"$
End Sub
The code here is from a project of mine.
 

imbault

Well-Known Member
Licensed User
Longtime User
No, because this is a image from the internet as inspiration.

The code here is from a project of mine.
Dear Alexander,

Using B4A V11, jdk1.8.0_291, your ASCalendarAdvanced V2.12

With this code :
B4X:
    ASCalendarAdvanced1.ExtraInfosTextProperties.TextFont = xui.CreateDefaultFont(8)
  
    ASCalendarAdvanced1.WeekNameShort = ASCalendarAdvanced1.CreateASCalendarAdvanced_WeekNameShort("Lun","Mar","Mer","Jeu","Ven","Sam","Dim")
    ASCalendarAdvanced1.MonthNameShort = ASCalendarAdvanced1.CreateASCalendarAdvanced_MonthNameShort("Jan","Fév","Mar","Avr","Mai","Juin","Juil","Août","Sept","Oct","Nov","Déc")


    ASCalendarAdvanced1.ShowOtherMonths =False
    ASCalendarAdvanced1.UpdateBody
    ASCalendarAdvanced1.UpdateHeader

    ASCalendarAdvanced1.ShowFirstWeekOfMonthInFirstRow = True

  
    Dim p_1 As Period : p_1.Months = -1
    Dim p_2 As Period : p_2.Months = 1
    ASCalendarAdvanced1.SetLimitRange(DateUtils.AddPeriod(DateTime.Now,p_1),DateUtils.AddPeriod(DateTime.Now,p_2))
  
  
    ASCalendarAdvanced1.CreateCalendar

This Event VisibleRangeChange is never fired, I've debugged it then I've put logs in it.... nothing...
B4X:
Private Sub ASCalendarAdvanced1_VisibleRangeChange(StartDate As Long,EndDate As Long)

    Log(" ASCalendarAdvanced1_VisibleRangeChange Event")
    Dim p As Period
    p.Days = 8
 
    xbblbl_current_month.Text = $"[b]${DateUtils.GetMonthName(DateUtils.AddPeriod(StartDate,p))} [color=#2D8879]${DateTime.GetYear(DateUtils.AddPeriod(StartDate,p))}[/color][/b]"$
End Sub

Help would be appreciated cause the month name in the calendar is very small
 

Wien.Mart

Member
Licensed User
Longtime User
Hello, may I know if the calendar can handle scheduling for two or more people and have a recurring task on the schedule? Thanks in advance.
 

focus330

Member
Licensed User
Longtime User
Very usefull. I like.

Only a question: Is it possible to have the text of the 'Appointmentype2' under the day and not over ? I trued something with AppointmentType2_Itemproprieties without success.
Thanks
 

Alexander Stolte

Expert
Licensed User
Longtime User
Update
  • 2.14
    • Add AppointmentType1BottomAppointmentTyp2Top - If false then AppointmentType1 is on Top and Type2 is on the bottom
Only a question: Is it possible to have the text of the 'Appointmentype2' under the day and not over ? I trued something with AppointmentType2_Itemproprieties without success.
set AppointmentType1BottomAppointmentTyp2Top to false
 
Top