This site uses different types of cookies, including analytics and functional cookies (its own and from other sites). To change your cookie settings or find out more, click here. If you continue browsing our website, you accept these cookies.
Customize & extend the power of Alteryx. SDKs, APIs, custom tools, and more!
Alteryx Gallery is experiencing a problem in which system emails are not being sent out. As a result, if you are attempting to sign up for a new account, you may be unable to verify your email address. We are working to solve this as soon as possible and will remove this notice once resolved.
My GUI has a ListBox widget to select columns, and my engine is a macro with a ListBox interface tool, with the Action tool set to "Update Select with multi-select ListBox". I included a data-item-props, and the fields from my data are populating in the interface, but when I run the workflow I get the error "The configuration is not valid: missing ControlParams field mapping." (see attached file. I couldn't get the yxi to attach so it's a zip that can be changed to yxi)
Any thoughts on what I'm doing wrong/how I should be thinking about this?
From personal experience, it is important to ensure that your macro works without the HTML GUI first.
The message about "ControlParams field mapping" means that you are trying to use a batch macro that does not contain a Control Parameter. Changing your macro to "Standard Macro" will remove this error.
Back to HTML SDK, at the moment your ListBox widget is not attached to a List Box tool in the macro. Attribute dataName ("Selected" in your example) should match the List Box name ("List Box (8)" in the macro).
Thanks for the quick response, I appreciate the pointers.
So I've updated my macro to be a standard macro rather than batch, and the List Box name is now named "Selected" to match the name of my data. My data now passes through the tool without an error, but the columns output are not affected by the selections in my List Box widget (ie the Select Tool in my macro is not updating). When I test the macro with an Alteryx ListBox Interface tool instead of the HTML widget it works fine.
So for the next step, you need to compare the behaviour of the ListBox widget in HTML and the List Box tool. To do so, first enable "Display XML in Properties Window" from menu Options, User Settings, Edit User Settings, tab Advanced.
Let's give a look at how both store their configuration.
Macro with HTML GUI (ListBox widget):
Original Macro (List Box tool):
As you can see:
- ListBox widget stores a list of selected items
- By default, List Box tool stores a list of pairs (item=selection status)
We need to update the macro so both configurations are identical.
Note that, if you were to run your macro now, you would notice that it doesn't work anymore. This is because we need to update the action attached to the List Box tool accordingly. As format is now different, we are going to select Update Raw XML with Formula to change parameter SelectFields of the Select tool.
We will use following piece of code to build dynamically the code of the select tool: