1

can anyone help me to customize the default error message in p-dropdown

Here is the code:

<p-dropdown [options]="vehicleList" [(ngModel)]="selectedVehicle" [ngModelOptions]="{standalone: true}" placeholder="Select" optionLabel="label" [showClear]="false" dropdownIcon="pi pi-caret-down" required requiredMessage="Please select the vehicle">

Please find the image for reference

need to change the "Please select item in list" error message to "Select a vehicle".

R. Richards
  • 24,603
  • 10
  • 64
  • 64
  • Please refer to [this](https://stackoverflow.com/questions/5272433/html5-form-required-attribute-set-custom-validation-message). It might help you to achieve what you want. – Zain_Ul_Abiddin Feb 22 '21 at 09:48

0 Answers0