tableHeaderCheckbox Events

UI Components for Angular
Post Reply
eskutti
Posts: 1
Joined: 01 Nov 2019, 09:11

01 Nov 2019, 09:16

Hello Sir,
I have created p-table which is selectable using checkbox.
In the header row i have 'tableHeaderCheckbox' tag. Is there any events like onchange /onselected/onUnselected ?
I need a trigger to check some validations on the table. Kindly help me.

Thanks,
Chempukutti E

yigitfindikli
Posts: 352
Joined: 08 Aug 2018, 14:09

04 Nov 2019, 10:54

eskutti wrote:
01 Nov 2019, 09:16
Hello Sir,
I have created p-table which is selectable using checkbox.
In the header row i have 'tableHeaderCheckbox' tag. Is there any events like onchange /onselected/onUnselected ?
I need a trigger to check some validations on the table. Kindly help me.

Thanks,
Chempukutti E
Hi,
You can use 'onHeaderCheckboxToggle' like this;

Code: Select all

<p-table (onHeaderCheckboxToggle)="yourFunction($event)" ... >
onHeaderCheckboxToggle event gives you ;
+ event.originalEvent: Browser event
+ event.checked: State of the header checkbox

Post Reply

Return to “PrimeNG”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 3 guests