Page 1 of 1

lookup field in Form field

Posted: 11 May 2015
by RMIC
When use a lookup field in "Form field" in Data Source Editor, no data is displayed. Is there already a solution?

Thanks :)

Re: lookup field in Form field

Posted: 11 May 2015
by Dmitry Kozlov
Thank you for the good question. Actually, you can configure filtering by a lookup field of the form but you need to do extra work here. First, configure filtering in the Data source dialog of the Related items control. Next, drop HTML-control onto your form and turn its CDATA property into False. Then insert the following code into its Content property:

Code: Select all

<xsl:variable name="LookupValue" select="substring-before(substring-after(@LookupColumn,'&gt;'),'&lt;')"/>
<xsl:comment>
    <xsl:value-of select="ddwrt:GenFireConnection(concat('*', '@LookupColumn=', ddwrt:ConnEncode(string($LookupValue))), '')" />
</xsl:comment>
Please, replace the highlighted text (LookupColumn) with the internal name of the lookup field from the form.

Re: lookup field in Form field

Posted: 29 May 2015
by RMIC
This worked, thanks a lot!