API Reference
New-HTMLCalendar
Creates a new HTML calendar using FullCalendar library.
Remarks
This function creates a new HTML calendar using the FullCalendar library. It allows customization of various calendar settings such as header elements, initial view, default date, event handling, and more.
Examples
EXAMPLE 1
New-HTMLCalendar -CalendarSettings {
# Define calendar settings here
}
Creates a new HTML calendar with default settings.
EXAMPLE 2
New-HTMLCalendar -CalendarSettings {
# Define calendar settings here
} -HeaderLeft 'prev', 'next' -HeaderCenter 'title' -HeaderRight 'dayGridMonth', 'timeGridWeek' -DefaultDate (Get-Date) -NavigationLinks $true -NowIndicator $true -EventLimit $true -WeekNumbers $true -Selectable $true -SelectMirror $true -BusinessHours -Editable -InitialView 'dayGridMonth' -UrlTarget 'https://example.com' -EventTimeFormat @{
hour = '2-digit'
minute = '2-digit'
omitZeroMinute = $false
meridiem = $false
hour12 = $false
} -SlotLabelFormat @{
hour = '2-digit'
minute = '2-digit'
omitZeroMinute = $false
meridiem = $false
hour12 = $false
}
Creates a new HTML calendar with custom settings.
Common Parameters
This command supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.
For more information, see about_CommonParameters.
Syntax
New-HTMLCalendar [-BusinessHours] [-CalendarSettings <ScriptBlock>] [-DefaultDate <DateTime>] [-Editable] [-EventLimit <Boolean>] [-EventTimeFormat <IDictionary>] [-HeaderCenter <prev>] [-HeaderLeft <prev>] [-HeaderRight <prev>] [-InitialView <dayGridDay>] [-NavigationLinks <Boolean>] [-NowIndicator <Boolean>] [-Selectable <Boolean>] [-SelectMirror <Boolean>] [-SlotLabelFormat <IDictionary>] [-UrlTarget <String>] [-WeekNumbers <Boolean>] [<CommonParameters>]
#
All Parameter SetsParameters
- BusinessHours SwitchParameter
- Indicates whether business hours are displayed on the calendar.
- CalendarSettings ScriptBlock
- Specifies the script block containing settings for the calendar.
- DefaultDate DateTime
- Specifies the default date to display on the calendar.
- Editable SwitchParameter
- Indicates whether events are editable on the calendar.
- EventLimit Boolean
- Indicates whether to limit the number of events displayed on a day.
- EventTimeFormat IDictionary
- Specifies the format for displaying event times.
- HeaderCenter String[]
- Specifies the element to display in the center of the calendar header.
- Possible values:
prev,next,today,prevYear,nextYear,dayGridDay,dayGridWeek,dayGridMonth,timeGridWeek,timeGridDay,listDay,listWeek,listMonth,title,listYear - HeaderLeft String[]
- Specifies the elements to display on the left side of the calendar header.
- Possible values:
prev,next,today,prevYear,nextYear,dayGridDay,dayGridWeek,dayGridMonth,timeGridWeek,timeGridDay,listDay,listWeek,listMonth,title,listYear - HeaderRight String[]
- Specifies the elements to display on the right side of the calendar header.
- Possible values:
prev,next,today,prevYear,nextYear,dayGridDay,dayGridWeek,dayGridMonth,timeGridWeek,timeGridDay,listDay,listWeek,listMonth,title,listYear - InitialView String
- Specifies the initial view of the calendar.
- Possible values:
dayGridDay,dayGridWeek,dayGridMonth,timeGridDay,timeGridWeek,listDay,listWeek,listMonth,listYear - NavigationLinks Boolean
- Indicates whether navigation links are enabled on the calendar.
- NowIndicator Boolean
- Indicates whether the current time indicator is displayed on the calendar.
- Selectable Boolean
- Indicates whether events can be selected on the calendar.
- SelectMirror Boolean
- Indicates whether a mirror effect is applied when selecting events.
- SlotLabelFormat IDictionary
- Specifies the format for displaying slot labels.
- UrlTarget String
- Specifies the target URL for calendar events.
- WeekNumbers Boolean
- Indicates whether week numbers are displayed on the calendar.