Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6630689
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T22:26:28+00:00 2026-05-25T22:26:28+00:00

I want to allow the user to select one or many contacts from the

  • 0

I want to allow the user to select one or many contacts from the contact entity, and then launch a dialog that accepts the record IDs. The idea is to add some custom configuration to the contacts.

I’ve currently got a custom action on a ribbon button that launches a dialog, but it only accepts one record Id. I can get access to the list of selected record Ids, thatisn’t the problem, it is passing a list to the dialog using JavaScript.

I can’t seem to find anything in the SDK or code snippets.
The nearest thing I found was this:

http://crmmongrel.blogspot.com/2011/06/launch-dialog-from-ribbon-button-in-crm.html

Anyone know if this is possible? I know the out of the box Send Direct E-Mail allows an email to be sent to the selected items, so I need something similar.

Should I be using dialogs or something else?

Here is a code snippet of the javascript that is called on the click of the ribbon button:

function LaunchModalDialog(SelectedControlSelectedItemReferences,dialogID, typeName)
{

// Get selected objects
var allItems = new Array
var allItems = SelectedControlSelectedItemReferences

// Just get first item for now as dialog only seems to accept one ID
var personId = allItems[0].Id;
personId = personId.replace(/\{/g, "");
personId = personId.replace(/\}/g, "");

// Load modal
var serverUri = Mscrm.CrmUri.create('/cs/dialog/rundialog.aspx');
var mypath = serverUri + '?DialogID={' + dialogID + '}&EntityName=' + typeName + '&ObjectId={' +personId + '}';
mypath = encodeURI(mypath);

// First item from selected contacts only
window.showModalDialog(mypath);

// Reload form.
window.location.reload(true);
}
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T22:26:29+00:00Added an answer on May 25, 2026 at 10:26 pm

    You’ll need to specify the SelectedControlAllItemIds parameter in your Ribbon for that button. Here is a link that describes it:

    http://social.microsoft.com/Forums/en/crm/thread/79f959ac-0846-472f-bff1-4f5afe692a56

    –Edit–

    I’m sorry, I misunderstood – you meant launch an actual CRM Dialog, not just a normal HTML pop-up dialog window.

    CRM Dialogs can’t be used on multiple records by design, so you aren’t going to be able to use them for this.

    However, you should be able to create an HTML web resource file that you can launch from the Ribbon, passing in the SelectedControlAllItemIds parameter. That HTML web resource would then have some javascript that would update the selected contacts using the REST endpoints (see the SDK for more information).

    Hope that helps!

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I want to show a dialog that will allow the user to select a
I want to allow a user to select an image from their local filesystem
I want to allow the user to click a start point and then click
I've got a content type called contact. One user can create hundreds of contacts.
I want to do a search across 2 tables that have a many-to-one relationship,
So how can I only allow a user to select only one checkbox? I
I know that I can easily allow a user to select multiple Features/Geometries in
I want to allow user to upload a file of txt ,doc or pdf
I want to allow user to enter only english alphabets and characters. How can
customers does not want to allow user to use back or forward button. Just

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.