Toggle Side Panel

  • Home
  • Articles
    • All Articles
    • Blogs
    • Videos
    • Infographics
  • Consultants
    • Salesforce Product Expertise
      • Top Salesforce ConsultantsTop Salesforce Consultants
      • Marketing Cloud ConsultantsMarketing Cloud Consultants
      • Service Cloud ConsultantsService Cloud Consultants
      • Experience Cloud ConsultantsExperience Cloud Consultants
      • Analytics Cloud ConsultantsAnalytics Cloud Consultants
    • Salesforce Industry Expertise
      • Non-Profit Cloud ConsultantsNon-Profit Cloud Consultants
      • Financial Service Cloud ConsultantsFinancial Service Cloud Consultants
      • Health Cloud ConsultantsHealth Cloud Consultants
      • Commerce Cloud ConsultantsCommerce Cloud Consultants
      • Manufacturing Cloud ConsultantsManufacturing Cloud Consultants
    • Salesforce Experts by Location
      • USATop Salesforce Consultants in USA
      • IndiaTop Salesforce Consultants in India
      • AustraliaTop Salesforce Consultants in Australia
      • United KingdomTop Salesforce Consultants in UK
      • CanadaTop Salesforce Consultants in Canada
  • Webinars
  • Marketplace
  • Advertise With Us
  • Contact Us
  • Discussions
More options
    Sign in Sign up
    • Home
    • Articles
      • All Articles
      • Blogs
      • Videos
      • Infographics
    • Consultants
      • Salesforce Product Expertise
        • Top Salesforce ConsultantsTop Salesforce Consultants
        • Marketing Cloud ConsultantsMarketing Cloud Consultants
        • Service Cloud ConsultantsService Cloud Consultants
        • Experience Cloud ConsultantsExperience Cloud Consultants
        • Analytics Cloud ConsultantsAnalytics Cloud Consultants
      • Salesforce Industry Expertise
        • Non-Profit Cloud ConsultantsNon-Profit Cloud Consultants
        • Financial Service Cloud ConsultantsFinancial Service Cloud Consultants
        • Health Cloud ConsultantsHealth Cloud Consultants
        • Commerce Cloud ConsultantsCommerce Cloud Consultants
        • Manufacturing Cloud ConsultantsManufacturing Cloud Consultants
      • Salesforce Experts by Location
        • USATop Salesforce Consultants in USA
        • IndiaTop Salesforce Consultants in India
        • AustraliaTop Salesforce Consultants in Australia
        • United KingdomTop Salesforce Consultants in UK
        • CanadaTop Salesforce Consultants in Canada
    • Webinars
    • Marketplace
    • Advertise With Us
    • Contact Us
    • Discussions
    Close search

    Activity › Forums › Salesforce® Discussions › How to set default value in <lightning:select> in Salesforce?

    Tagged: Account ID, Aura Attribute, Controller, Lightning Account Controller, Salesforce Lightning

    • Salesforce® Discussions

      How to set default value in <lightning:select> in Salesforce?

      Posted by Yogesh on December 10, 2019 at 7:20 AM

      I have to set default value in <lightning:select>.

      Deepak replied 6 years ago 2 Members · 1 Reply
      • Account ID
      • Aura Attribute
      • Controller
      • Lightning Account Controller
      • Salesforce Lightning
    • 1 Reply
    • Deepak

      Member
      December 10, 2019 at 2:07 PM

      <aura:application extends="force:slds" controller="LightningAccountController">
      <aura:attribute name="accounts" type="Account[]" />
      <aura:handler name="init" value="{!this}" action="{!c.doInit}" />

      <lightning:select label="Choose 1" name="a_opt" aura:id="a_opt" onchange="{!c.change}">
      <aura:iteration items="{!v.accounts}" var="account">
      <option value="{!account.Id}">{!account.Name}</option>
      </aura:iteration>
      </lightning:select>
      </aura:application>

    Log In to reply.

    • Public
    • All Members
    • My Connections
    • Only Me
    • Public
    • All Members
    • My Connections
    • Only Me
    • Public
    • All Members
    • My Connections
    • Only Me

    application solution

    Popular Salesforce Blogs

    FlexDeploy Loves Salesforce: Unit Test and Test Automation for Salesforce

    Blog in Salesforce integration

    FlexDeploy is an Enterprise DevOps platform with fully integrated support for Salesforce apps, metadata customizations, integrations, and more. This is the last article in a blog…

    Apex Testing Framework, Automate Deployment Promotions, Automated Actions, Business Users, CI/CD
    Flexagon Mar 25, 2022
    3,097  Views

    Unlock Revenue Growth with Expert Salesforce CPQ Services

    Blog in Salesforce

    In a world where product catalogues are expanding, pricing is becoming more dynamic, and sales processes need to move with agility, businesses are turning to…

    Salesforce CPQ Consulting Services, Salesforce CPQ Services
    Dean Nov 26, 2025
    106  Views
    Deduping Salesforce

    A Machine Learning Approach to Deduping Salesforce

    Blog in AI and ML, Salesforce

    When we look at all of the Salesforce deduplication apps on the AppExchange, they all have one thing in common: they are all rule-based. Basically,…

    AppExchange, Catch Duplicates, Deduping Salesforce, Field-by-field Approach, Hamming Distance
    ildudkin Dec 7, 2020
    3,393  Views

    Popular Salesforce Videos

    Skills for Salesforce Field Service | Optimize Customer Service for Businesses | Salesforce Webinar

    Skills for Salesforce Field Service | Optimize Customer Service for Businesses | Salesforce Webinar

    Video in Salesforce Field Service Platform

    One way to optimize customer service operations is by having the right technician for the right job. How? Skills for Salesforce Field Service is the…

    Salesforce Tutorial, salesforce, Salesforce Webinar, Salesforce Field Service Platform, Salesforce Field Service
    AblyPro Jul 4, 2024
    631  Views
    Get Started With Empowering Your Sales Users in Salesforce Pardot

    Get Started With Empowering Your Sales Users in Salesforce Pardot

    Video in Salesforce Products

    This Get Started With Empowering Your Sales Users in Pardot series will help your sales reps sell more and save time with Pardot features. The…

    Salesforce Training, Salesforce Tutorial, salesforce, sales team, Salesforce Learning
    Abhishek Jun 6, 2022
    2,094  Views
    Salesforce on Salesforce: How Salesforce Uses Trailhead to Drive Enablement

    Salesforce on Salesforce: How Salesforce Uses Trailhead to Drive Enablement

    Video in Trailhead

    With Trailhead, Salesforce is transforming the learning experience for our employees at every step of their career journey. Join us to learn tips, tricks and…

    Salesforce Online Training, Trailhead, Learn Salesforce, Salesforce Trailhead, Salesforce Trailblazers
    Ashley Apr 18, 2018
    2,070  Views
    Footer Forcetalks logo

    support@forcetalks.com

    • twitterx

    Quick Links

    Advertise with Us

    Salesforce® Articles

    Dreamforce 2023

    Top Salesforce® Bloggers 2023

    Top Salesforce Consultants

    Get Listed

    Company

    Contact Us

    About Us

    Privacy Policy

    Terms & Conditions

    InsightHub

    Salesforce Blogs

    Salesforce Videos

    Salesforce Groups

    Salesforce Jobs

    © 2025 - Forcetalks ● All Rights Reserved

    Salesforce® is a trademark of Salesforce® Inc. No claim is made to the exclusive right to use “Salesforce”. Any services offered within the Forcetalks website/app are not sponsored or endorsed by Salesforce®.

    Try AuditMyCRM - It is a Salesforce CRM Audit tool which comprehensively scans your Salesforce org and gives you the list of errors or warnings you need to take care of.
    We use cookies to enhance your browsing experience. Please see our privacy policy if you'd like more information on our use of cookies.