Modify Grid formatting in Workflow
Created: 28 Oct 2009 | 2 comments
I have a software request workflow were I am using a grid to display (Software Name, Cost, Selectable) and right now I have the grid being populated from SQL and the 'Cost' is coming in as a number and I would like to add a $ to the start of all of the fields under 'Cost'. Is there a way that I am missing to format a grid or am I better off figuring it out in SQL?
discussion Filed Under:
Comments
Have you solved this?
Hi!
I'm doing something similar. Have you figured out the solution?
Thanks!
Robert Lundsten
Consultant / Founder : Asterio
Homepage | http://www.asterio.se
Blog | http://www.asterio.se/blogg
Twitter | http://twitter.com/asterioan
Turned to SQL
I found that the grid formatting at least with version 6 is pretty limited so I turned to SQL to put the $ in the results of my query. Here is the query:
All you will need is the second line of the query but I thought I would include the whole thing is case it provided any insight.
SELECT ws._ResourceGuid AS 'LicenseGuid',
'$' + convert(varchar(10), convert(money, ws.SoftwareCost)) as 'Total Cost',
ws.SoftwareCost as 'NumericCost',
ws.SoftwareCategory as 'Software Category',
ws.SoftwareFriendlyName as 'Friendly Name',
ws.SoftwareIsSelectable as 'Selectable',
ws.SoftwareAppEmail as 'EMail',
ws.SoftwareCitrixGrp as 'Citrix Group',
ac.Collection as 'Authorized Collections'
FROM Inv_Workflow_SoftwareDataClass ws
LEFT JOIN Inv_Authorized_Collections ac on ws._ResourceGuid = ac._ResourceGuid
WHERE (ws.SoftwareIsSelectable = 'True'
AND ws.SoftwareFriendlyName LIKE @SoftwareSearch
AND (@SelectMachineType = 'Install to PC (above)'
OR @SelectMachineType = Null))
OR (ws.SoftwareIsSelectable = 'True'
AND ws.SoftwareFriendlyName LIKE @SoftwareSearch
AND (@SelectMachineType = 'Install to Thin Device'
OR @SelectMachineType = Null)
AND ws.SoftwareAvailForCitrix = 'True')
ORDER BY ws.SoftwareFriendlyName
Would you like to reply?
Login or Register to post your comment.