Skip to main content
Nintex Community Menu Bar
Question

Custom Control and For loop in Rule

  • Mar 29, 2023 11:46 AM UTC
  • 4 replies
  • 151 views
  • Translate All

Forum|alt.badge.img+2

Hi,

 

i created a custom control with Smart Object.

i deployed and its working fine.

 

now issue is. i want to iterate that smartobject in for loop in rule as in below image. but its not showing any message on button click. (i verified the smart object attached. it has rows inside.)

 

i am using below in definition

<Category>Listing</Category>
    <Group>Documents</Group>
    <Name>MultiFile</Name>
    <DisplayName>Multi File</DisplayName>

    

    <ExecuteMethod></ExecuteMethod>
    <GetValueMethod></GetValueMethod>
    <SetValueMethod></SetValueMethod>
    <SetRulesMethod></SetRulesMethod>
    <SetItemsMethod></SetItemsMethod>
    <GetPropertyMethod></GetPropertyMethod>
    <SetPropertyMethod></SetPropertyMethod>

 

<Prop ID="DataSourceType" friendlyname="Type" type="complex" serverControlType="property" category="Data Source" InitializeServerControl="initializeAssociationPropertyConfig" ClearServerControl="clearComplexPropertyConfig" ServerControl="SourceCode.Forms.Controls.Web.PropertyConfiguration.AssociationPropertyConfig, SourceCode.Forms.Controls.Web" />
        <Prop ID="FixedListItems" friendlyname="Items" type="string" serverControlType="property" category="Data Source" ReadOnly="true" />
        <Prop ID="AssociationSO" friendlyname="SmartObject" type="string" serverControlType="smartobject" category="Data Source" ReadOnly="true" />
        <Prop ID="AssociationMethod" friendlyname="Method" type="string" serverControlType="listmethod" category="Data Source" ReadOnly="true" />
        <Prop ID="ValueProperty" friendlyname="Value" type="string" serverControlType="property" category="Data Source" ReadOnly="true" />
        <Prop ID="DisplayTemplate" friendlyname="Display" type="string" serverControlType="property" category="Data Source" ReadOnly="true" />

 

 

Please suggest if i am missing any configuration.

 

Regards,

4 replies

Forum|alt.badge.img+3
  • Nintex Partner
  • Apr 3, 2023 6:54 AM UTC

Have you configured the value for the control to be a unique value per row?

K2 gets confused in list controls if the value field assigned is not unique across all returned rows (note, all returned rows includes those rows excluded via the filter panel).

 

Hope this helps

Translate

Forum|alt.badge.img+2
  • Author
  • Rookie
  • Apr 3, 2023 7:17 AM UTC

Hi,

 

yes for now there are just 5 rows in the smartobject. which are unique one.

once i am calling my custom control in loop and showing message. nothing going inside the loop. thats the issue.

 

Regards,

Translate

Forum|alt.badge.img+11
  • Nintex Employee
  • Jun 2, 2023 10:21 PM UTC

@fharoon 

Are you using the data source’s property in your mapping instead of the control’s property?

Translate

@fharoon

Are you using the data source’s property in your mapping instead of the control’s property?

Yes i am suing data source property.

Translate