We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Adding default selections

Thread ID:





148667 Oct 29,2019 08:12 PM UTC Dec 2,2020 02:17 PM UTC React - EJ 2 1
Tags: MultiSelectDropdown
Nurudeen Amedu
Asked On October 29, 2019 08:12 PM UTC

is it possible for me to put in some already selected items when the page loads instead of always loading empty

Sureshkumar P [Syncfusion]
Replied On October 30, 2019 06:42 AM UTC

Hi Nurudeen, 
Greetings from Syncfusion support. 
We can set the pre-selected value to multiselect component using our inbuild value property. Kindly refer the below code block  
<MultiSelectComponent id="customelement" dataSource={this.gameList} fields={this.fields} mode="Box" 
               value={this.preselectValues} placeholder="Favorite sports" /> 
We created a sample based on your requirement. please refer the sample here: https://stackblitz.com/edit/react-pohmde?file=index.js  
To know more about the value property please refer the below API documentation link: https://ej2.syncfusion.com/react/documentation/api/multi-select#value  
Sureshkumar P 


This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

Live Chat Icon For mobile
Live Chat Icon