NetTalk Central
NetTalk Web Server => Web Server - Ask For Help => Topic started by: jking on May 31, 2018, 06:56:44 PM
-
I would like to conditionally set cell colors in the exported xml when using the Export to Excel button on a NT 10.19 browse. I have set my own style in the After Set Styles embed as follows:
!!Create my own cell style
ExcelExport.SetStyle('s999','MyCell')
ExcelExport.SetStyleInterior('s999','#F6EFCE','Solid')
Then, in the Export To Excel Set Queue Record embed I tried the following:
!!conditionally set exported cell with my style
If loc:Status = 'Complete'
ExcelExport.SetCell(rowNumber,ColumnNumber,loc:Status,'s999')
END
This has not worked for me and I have tried a number of the other Export To Excel embeds. Can anyone suggest a solution?
P.S.
Ideally, I'd like an integration of SendTo in Nettalk, to export a browse to HTLM, XLS, PDF, etc., but I don't think this has been done yet.
-
Hi Jeff,
you're on the right track. The only thing missing for you was a good embed point.
The problem with the embed point you used was that the RowNumber and ColumnNumber fields are not set correctly (for the loc:status field) at that point.
I have added a new embed point in 10.22 which allows you to better so what you need, just after the generated call to .SetCell.
You can then do;
If loc:Status = 'Complete'
ExcelExport.SetCell(rowNumber,ColumnNumber, ,'s999')
END
(you can put loc:status in the 3rd parameter, or leave it off, either way is fine.)
so grab 10.22 when it's up and try with that.
cheers
Bruce
-
Bruce,
Thanks! I'll get 10.22 as soon as you post it.
Jeff
-
Bruce,
I have done some testing and the new embed you added works well. See the attached image.
Thanks!
Jeff
-
cool.