Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Marco 3 posts 73 karma points
    1 week ago
    Marco
    0

    Populate Programmatically Dropdown umbraco forms

    Hi guys, there is a way to populate Prorammatically a Dropdown List inside Umbraco Forms?

    Thanks

  • Alex Brown 105 posts 457 karma points
    1 week ago
    Alex Brown
    1

    I tend to create a custom FieldType for Umbraco forms when doing things like this.

    https://our.umbraco.org/documentation/Add-ons/UmbracoForms/Developer/Extending/Adding-a-Fieldtype

    You can populate the dropdown in the partial view file with Razor.

  • Marco 3 posts 73 karma points
    1 week ago
    Marco
    0

    the dropdown is inside an umbraco form, how can I access it? Is there a way to communicate with the umbraco forms fields?

  • Alex Brown 105 posts 457 karma points
    1 week ago
    Alex Brown
    0

    You should be able to edit the drop down values manually, is that what you mean? In the forms section in the CMS

  • Marco 3 posts 73 karma points
    1 week ago
    Marco
    0

    I need to populate the list because I have a lot of fields to insert and I can not use the form elements via code. Is there a way to populate the list from code? Do you have any practical examples available?

    example: populate the list with all the cities in the world. There is too much data to insert/edit manually.

Please Sign in or register to post replies

Write your reply to:

Draft