Hi,
I’m new to the Form Designer and I’m having trouble trying to display a URL link in the grid.
Background:
I’m stripping a data grid from a web site and storing it in a DataTable. I’m trying to display some of the columns from the data table in the Data Grid and allow the user to click on a link in a row to visit the web site. The user can then decide if they want to delete the row. When they’re done, they click Submit and I’ll write the results to an Excel file.
I’ve configured the Create Form activity to pass in the DataTable in the FormFieldsCollection and unchecked the GenerateInputFields. My understanding is that this binds the DataTable to the grid.
I’ve added columns to the Data Grid:
Issues:
The first issue I have is that some of the DataTable column names have spaces, etc. (eg. “Date / Time”). When I try to add the value to the Field Key, I get the “only alphanumerics” error so, for the time being, I’m only displaying columns from the data table that work. Is there a work-around or do I have to rename all my dataTable columns?
The second issue I have is trying to populate a column with an HTML link. One dataTable column is a string containing the URL (eg: http://www.google.com). I’m using an HTML Element Component and trying to configure it to display the link. I’ve set the Field Key to be the dataTable column name (“Title2”) and configured the Content to use “{{row.Title2}}” in the HRFEF. That works but opens in the form instead of in a browser. That wouldn’t be too bad, but I don’t seem to be able to get back to the grid. In that case, I think I may need to go with using a button and opening the link in the “Do” part.
If I have to use a button, how do I pass the URL through to the Do block. I think all that comes through is the text for the button that was clicked.
I hope this makes sense to someone.
Thanks,
Carlo.