Prevalue Source Types Overview
There are some default prevalue source types that can be used. In this article, we will give a quick overview of them:
Get values from textfile
Upload a textfile that contains the prevalues. Each prevalue should have its own line in the file. Once the file has been uploaded, you can find it in ~/wwwroot/App_Data/UmbracoForms/Data/PreValueTextFiles/{GUID}
where the {GUID}
is replaced with the pre-value ID.
![](https://docs.umbraco.com/~gitbook/image?url=https%3A%2F%2F239938597-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FHbkj8mAE5C7ODrOVDnjJ%252Fuploads%252Fgit-blob-94d165ae93bfd7c5cef0c241606f226edf775a02%252Fpreview-v14.png%3Falt%3Dmedia&width=768&dpr=4&quality=100&sign=990ec465&sv=1)
Umbraco Documents
Allows to use content nodes from a specific source as prevalues. You can apply the following settings in the Details section:
Select which Value field should be used for the value of the prevalue.
You can define the root node by either
Choosing a node directly from the Content tree or
Using XPath
Enable Use current page as root instead of choosing a specific root node. The preview is not available when this setting is enabled.
Select a specific Document type, if the selected root node contains a different Document Type.
Enable List all Descendants of the selected root node to list all levels of descendants.
Select Order by from the drop-down list to display how the prevalue list should be ordered.
Select your preferred Cache option for caching the list of prevalues when rendering in a form.
![](https://docs.umbraco.com/~gitbook/image?url=https%3A%2F%2F239938597-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FHbkj8mAE5C7ODrOVDnjJ%252Fuploads%252Fgit-blob-940c3a9ecaf56d189cc981d81360d8a213859ecb%252Fumbraco-documents-v14.png%3Falt%3Dmedia&width=768&dpr=4&quality=100&sign=e989a0b2&sv=1)
SQL Database
You can provide the following details in the Details section:
Connect to a OleDB compatible database table and construct a prevalue source from it. Once selected, it will be editable from the Forms interface.
The following configurations need to be set in the Details section:
Connection string (either choose one from your web.config or add another from a textfield).
Connection String from configuration
Table Name
Key Column
Value Column
Caption Column
Select your preferred Cache option for caching the list of prevalues when rendering in a form.
![](https://docs.umbraco.com/~gitbook/image?url=https%3A%2F%2F239938597-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FHbkj8mAE5C7ODrOVDnjJ%252Fuploads%252Fgit-blob-e5793f6bfe670a3c99446e30bfccd9ed76ffc178%252FSQLdatabase-v14.png%3Falt%3Dmedia&width=768&dpr=4&quality=100&sign=f7aa934d&sv=1)
Umbraco Data Type Prevalues
Choose an Umbraco Data Type to use its configured prevalue collection.
In the example below, the prevalue collection from a Data Type called Home - Font - Radio button
is used:
![](https://docs.umbraco.com/~gitbook/image?url=https%3A%2F%2F239938597-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FHbkj8mAE5C7ODrOVDnjJ%252Fuploads%252Fgit-blob-9f350a72448fea3e70583dc16b917cce69ea1007%252Fdatatype-prevalues-v14.png%3Falt%3Dmedia&width=768&dpr=4&quality=100&sign=142eea5&sv=1)
Last updated