Skip to content

Chart Placement #213

Discussion options

You must be logged in to vote
# Define data
$DataTable = @(
    [PSCustomObject] @{
        Name  = 'My Object 1'
        Time  = 1
        Money = 5
        Taxes = 20
    }
    [PSCustomObject] @{
        Name  = 'My Object 2'
        Time  = 3
        Money = 1
        Taxes = 5
    }
    [PSCustomObject] @{
        Name  = 'My Object 3'
        Time  = 12
        Money = 5
        Taxes = 1
    }
)

# Define HTML
New-HTML {
    New-HTMLSection {
        for ($i = 0; $i -le 5; $i++) {
            New-HTMLChart {
                New-ChartToolbar -Download
                foreach ($Object in $DataTable) {
                    New-ChartPie -Name $Object.Name -Value $Object.Time
                }
            }
        }…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by PrzemyslawKlys
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants