Telerik Forums
Community Forums Forum
0 answers
8 views
To add a ChoiceField dropdown in the Form Properties → Connectors section using FormsConnectorDefinitionsExtender, you need to extend the connector definitions and define your field properly. Here's a step-by-step guide with an example:


---

1. Implement FormsConnectorDefinitionsExtender

You need to create a class that implements IFormsConnectorDefinitionsExtender (or the relevant extender interface depending on your framework/version).

using Telerik.Sitefinity.Forms.Connector;
using Telerik.Sitefinity.Forms.Model;
using System.Collections.Generic;

public class CustomConnectorExtender : IFormsConnectorDefinitionsExtender
{
    public void Extend(IEnumerable<FormConnectorDefinition> connectorDefinitions)
    {
        foreach (var connectorDef in connectorDefinitions)
        {
            // Example: Add a ChoiceField dropdown to a specific connector
            if (connectorDef.Name == "MyCustomConnector")
            {
                connectorDef.Properties.Add(new ChoiceFieldDefinition
                {
                    Name = "Category",
                    DisplayName = "Select Category",
                    Description = "Choose a category for the submission",
                    Choices = new List<ChoiceItem>
                    {
                        new ChoiceItem { Text = "Option 1", Value = "1" },
                        new ChoiceItem { Text = "Option 2", Value = "2" },
                        new ChoiceItem { Text = "Option 3", Value = "3" }
                    },
                    Required = true,
                    DefaultValue = "1"
                });
            }
        }
    }
}


---

2. Register the Extender

You need to register the extender so the platform picks it up. This usually goes into a Module class or Global.asax depending on your CMS/framework:

protected void Application_Start(object sender, EventArgs e)
{
    FormsConnectorDefinitionsExtender.RegisterExtender(new CustomConnectorExtender());
}


---

3. Key Points

ChoiceFieldDefinition is used to render a dropdown in the Connectors properties.

Choices is a list of ChoiceItem objects where you define the Text and Value.

DefaultValue can be set to preselect an option.

Required makes the dropdown mandatory.

Make sure the connector name (connectorDef.Name) matches the connector you are extending.



---

This approach ensures that when a user opens your custom connector in the Form Properties → Connectors section, they will see a dropdown field with the specified choices.


---

If you want, I can also provide a version that supports dynamic values, so the dropdown populates from a database or API instead of being static. Do you want me to do that?
0 answers
31 views

Hi,

I'm trying to add a dropdown to the connectorsSettings section in the form builder using FormsConnectorDefinitionsExtender.
My field gets added but only the first choice is rendered and is rendered as a check box. I can see it in the backend and see the choices.
If i modify another built in field like restrictions, by changing it from a radiobutton to a dropdown, that renders correctly but my field does not.
.net framework 4.8 - sf v15.3

The full code is below and I'm running it in a brand new project setup, no other modifications or customizations exist apart from a dynamic module. Note that the screenshot provided is missing choices as i have been trying different things...

Thanks,
public class Global : System.Web.HttpApplication
{


    protected void Application_Start(object sender, EventArgs e)
    {
        Bootstrapper.Bootstrapped += Bootstrapper_Bootstrapped;
    }

    private void Bootstrapper_Bootstrapped(object sender, EventArgs e)
    {
        ObjectFactory.Container.RegisterType<FormsConnectorDefinitionsExtender, CrmWorkflowConnectorExtender>("CrmWorkflowConnectorExtender");
        ObjectFactory.Container.RegisterType<IModuleConnectionStatus, CrmWorkflowConnectorExtenderConnectionStatus>(typeof(CrmWorkflowConnectorExtenderConnectionStatus).FullName, new ContainerControlledLifetimeManager());
    }

}

public class CrmWorkflowConnectorExtender : FormsConnectorDefinitionsExtender
{
    public override int Ordinal
    {
        get { return 1; }
    }


    public override string ConnectorName => "CrmConnectorModule";

    public override string ConnectorTitle => "CRM Connector";

    public override string SectionTitle => "Send data to dynamics CRM";

    public override void AddConnectorSettings(ConfigElementDictionary<string, FieldDefinitionElement> sectionFields)
    {
        var CRMWorkflowField = new ChoiceFieldElement(sectionFields)
        {
            Title = "Select CRM Workflow",
            FieldName = "CRMWorkflowSelection",
            DataFieldName = "CRMWorkflowSelection",
            DisplayMode = FieldDisplayMode.Write,
            FieldType = typeof(Telerik.Sitefinity.Web.UI.Fields.ChoiceField),
            RenderChoiceAs = RenderChoicesAs.DropDown,
            ID = "CRMWorkflowSelectionID"
        };

        //foreach (var workflow in GetWorkflowDefinitions())
        //{
        //    var choice = new ChoiceElement(CRMWorkflowField.ChoicesConfig)
        //    {
        //        Text = workflow.WorkflowName,
        //        Value = workflow.WorkflowName
        //    };
        //    CRMWorkflowField.ChoicesConfig.Add(choice);
        //}

        var mychoices = new List<ChoiceDefinition>();
        mychoices.Add(new ChoiceDefinition()
        {
            Text = "MVCOnly",
            ResourceClassId = typeof(FormsResources).Name,
            Value = "0"
        });

        mychoices.Add(new ChoiceDefinition()
        {
            Text = "WebFormsOnly",
            ResourceClassId = typeof(FormsResources).Name,
            Value = "1"
        });

        CRMWorkflowField.Choices.AddRange(mychoices);
        sectionFields.Add(CRMWorkflowField.ID, CRMWorkflowField);
    }

    private IEnumerable<WorkflowDefinitionDto> GetWorkflowDefinitions()
    {
        var manager = DynamicModuleManager.GetManager();
        var type = TypeResolutionService.ResolveType("Telerik.Sitefinity.DynamicTypes.Model.CrmWorkflows.WorkflowDefinition");

        IEnumerable<WorkflowDefinitionDto> workflows = manager.GetDataItems(type)
            .Where(w => w.Status == ContentLifecycleStatus.Live && w.Visible)
            .Select(w => new WorkflowDefinitionDto
            {
                WorkflowName = w.GetValue<string>("WorkflowName")
            });

        return workflows;
    }

    private class WorkflowDefinitionDto
    {
        public string WorkflowName { get; set; }
    }
}

public class CrmWorkflowConnectorExtenderConnectionStatus : IModuleConnectionStatus
{
    public string ModuleName => "CrmConnector.CrmConnectorModule";

    public void ExecuteIfConfigured(Action action)
    {
        // Add code to check that the connector is connected
        // ex. if (this.connector.IsConnected())
        if (action != null)
            action();
    }

    // IMPORTANT: This callback is not invoked as part of Forms connectors. You still need to implement it, as it is used elsewhere.
    public void ExecuteIfNotConfigured(Action action)
    {
        // Add code to check that the connector is not configured
        // ex. if (!this.connector.IsConnected())
        if (action != null)
            action();
    }
}

Type : System.ArgumentException, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
Message : ‹‹‹An item with the same key has already been added.›››
Source : mscorlib
Help link : 
ParamName : 
Data : ‹‹‹System.Collections.ListDictionaryInternal›››
TargetSite : ‹‹‹Void ThrowArgumentException(System.ExceptionResource)›››
HResult : ‹‹‹-2147024809›››
Stack Trace :    at System.ThrowHelper.ThrowArgumentException(ExceptionResource resource)
   at System.Collections.Generic.Dictionary`2.Insert(TKey key, TValue value, Boolean add)
   at Telerik.Sitefinity.Web.Api.Strategies.Forms.Connectors.FormConnectorService.ResolveUIField(List`1 fields, FieldDefinitionElement fieldDefinitionElement, ConnectorDataMappingExtender mappingExtender, SectionFieldWrapper predecessorField)
   at Telerik.Sitefinity.Web.Api.Strategies.Forms.Connectors.FormConnectorService.AdjustFields(List`1 fields, SectionFieldWrapper predecessorField)


Muhammad
Top achievements
Rank 1
 asked on 21 Oct 2025
1 answer
26 views

Hi,

I was going to create a ticket but there's no option for website related issues so I am just posting it here for anyone that has spotted this before. 

The pages for the Blazor UI have invalid re-directs when clicking on the documentation button. 

Almost all documentation buttons on https://www.telerik.com/blazor-ui/ direct you to the invalid url

It adds "-ui" to /documentation/ so it's then /blazor-ui/documentation-ui/ which is invalid and should be /blazor-ui/documentation/


Example:

https://www.telerik.com/blazor-ui/datetimepicker

 

It directs you to:

https://www.telerik.com/blazor-ui/documentation-ui/components/datetimepicker/overview

 

It should direct you to:
https://www.telerik.com/blazor-ui/documentation/components/datetimepicker/overview

Grid view:

https://www.telerik.com/blazor-ui/filter

Documentation redirects to:

https://www.telerik.com/blazor-ui/documentation-ui/components/filter/overview

 

 

Thanks,

Luke

Dimo
Telerik team
 answered on 26 Sep 2025
0 answers
28 views

Hello, I'm Ajay Hinduja. I'm originally from Punjab, India, and have made my home in Geneva, Switzerland. I'm thinking about integrating Telerik components into our existing project to improve our UI and accelerate development. Has anyone had experience with this before? I'd appreciate any insights on the integration process, whether you used the Visual Studio wizards or performed the steps manually. Any tips on potential challenges or best practices would be a huge help!

 

Regards

Ajay Hinduja Geneva, Switzerland (Swiss)

Ajay Hinduja
Top achievements
Rank 1
 asked on 03 Sep 2025
1 answer
100 views

I'm trying to install Kendo UI using the following command:

 
npm install --save @progress/kendo-ui

But I'm running into this error:

 
npm ERR! path C:\devAngular\EMS.Orion.UI\node_modules\@progress\kendo-licensing npm ERR! command failed npm ERR! command C:\WINDOWS\system32\cmd.exe /d /s /c node ./bin/kendo-ui-license.js activate --ignore-no-license npm ERR! [WARN][Telerik and Kendo UI Licensing] No Telerik or Kendo UI product references detected in project. npm ERR! Consult the product documentation or contact support at https://prgress.co/3Pzpwvf npm ERR! [ERROR][Telerik and Kendo UI Licensing] Corrupted Telerik and Kendo UI License Key content in KENDO_UI_LICENSE npm ERR! Download a new copy of the license key from https://prgress.co/3PxpDaP

 

Has anyone run into this before? Any guidance on how to properly set or regenerate the license key and fix this error?

Thanks in advance! 🙏

Neli
Telerik team
 answered on 07 Aug 2025
1 answer
43 views

getting following error in Azure devops pipeline

ServiceUnavailable https://nuget.telerik.com/nuget/FindPackagesById()

Unable to connect to https://nuget.telerik.com/v3/index.json

Dimo
Telerik team
 answered on 17 Jun 2025
1 answer
38 views

Can telerik be used on all users from the same PC?

I have my telerik license installed on my home development PC.
But my wife has her own separate user account on it.
I noticed that on her user VS does not list any of the Telerik solution options. Yet when I try to install it says its already installed.

We both use VS and I like to keep the solutions sepated. 

Lance | Senior Manager Technical Support
Telerik team
 answered on 27 May 2025
1 answer
54 views

Hi all

 

I'm getting a timeout when i try to connect to the v3 nuget server?

 

Not sure if its down or if i can check the status somewhere?

 

Thanks

Ivo
Telerik team
 answered on 21 May 2025
1 answer
103 views

Hi Team,

I just got a email from g2.com, it said Telerik asked them to gather reviews.

email subject: "Review Progress Telerik, get a $25 Amazon gift card!"

how the g2 know who I am,  my email, also know I bought Telerik Products.

didn't click any hyperlink within, but I really concern about the privacy.
I didn't remember any agreements with g2.

It's an officical activity, security incident or phishing ? 
I'm looking forward to a official explaination.


Plamen Mitrev
Telerik team
 answered on 30 Apr 2025
1 answer
93 views
What is the code signing certificate that needs to be installed?  Getting the following message:
Package 'Telerik.Reporting.OpenXmlRendering 19.0.25.313' from source 'https://nuget.telerik.com/v3/index.json': This package is signed but not by a trusted signer.

Lance | Senior Manager Technical Support
Telerik team
 answered on 21 Mar 2025
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Bronze
Iron
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Bronze
Iron
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?