Video Screencast Help
Symantec to Separate Into Two Focused, Industry-Leading Technology Companies. Learn more.
Endpoint Management Community Blog

Practical Uses - Display Current Users Helpdesk Incidents

Created: 19 Nov 2008 • Updated: 19 Nov 2008 • 2 comments
Bob Wooding's picture
+2 2 Votes
Login to vote

This example shows you how to retrieve data from the Helpdesk database using a parameter in a SQL Query. Using the query/script generator you will build an integration component and use the listitemscomponent to display the current users incidents.

Create Query Script Generator

  1. Create New Integration Project
  2. Name the component ViewContactIncidents
  3. Click OK
  4. Select Query/Script Generator
  5. Click OK
  6. Click the drop down and select SQL Server Provider
  7. Select the appropriated Connection String for your environment
  8. Enter the SQL Query to return the desired results
    Note:In this example, I choose to only return specific values from workitem_current_view.
    I also use the a parameter for the contact ID which will be used in our project.

    Note:I use a parameter in my where clause for the contact ID

  9. Select Find Input Parameters
  10. Click Next
  11. Select Use and populate Project property
  12. Rename the Project Property Name to ViewIncidents_ConnectionString
    Note: This Project Property Name cannot have a period in the name
  13. Click Next
  14. Click Next
  15. Click to enable Returns Data
  16. Click Fill Schema
  17. Click Next
  18. Name the Component Display_Current_User_Incidents
  19. Click Finish
  20. Select Compile and close

How to Use the Custom View Incidents Component in Your Project

  1. Create a New Workflow Project
  2. Name the Project SupportPortal
  3. Click Next
  4. Select Import Components from the components toolbox
  5. Select Custom Libraries
  6. Select ViewContactIncidents.dll
  7. Select OK
  8. Add the following Components:
    • Get Current User
    • Find Service Desk Contact
    • Dialog Workflow
    • Create Ticket
    • Display_Current_User_Incidents
      Note: If you named your custom component something different than Display_Current_User_Incidents, add that component.
  9. Connect all components
  10. Set the following properties on Get Current User
    • Output Variable Name: v_CurrentUser
    • User Name Type: HttpContext
  11. Set the following properties on Find Service Desk Contact
    • Search Value: v_CurrentUser
    • Select Contact By: From Picker
    • Contact Type: NTId
  12. Right Click on Display_Current_User_Incidents Component
  13. Select Edit Component
  14. Click ellipses for Contact ID
  15. Select Process Variable
  16. Click Add
  17. Select foundContacts[last].ContactID
  18. Click OK
  19. Click OK
  20. Right click on the Dialog Workflow Component
  21. Select Edit Component
  22. Click the Interaction Setup Tab
  23. Click the ellipses for Dialog Model
  24. Add a form builder component
  25. Rename the Form Builder component to Support Portal
  26. Right Click the form builder component
  27. Select Web Form Editor
  28. Add labels and text boxes for Incident Title and Incident Comment

    Use the following variables:

    • Incident Title Textbox - v_IncidentTitle
    • Incident Comments Textbox - v_IncidentComments
  29. Find the ListItemsComponent and add it to the form
    Note: I have applied the Symantec Theme to the WebForm
  30. Double Click the ListItemComponent in the form to edit properties
  31. Click the ellipses for Data Type:
  32. Select Custom Result as the Data Type under ViewContactIncidents
  33. Click OK
  34. Select ellipses for Items:
  35. Click the Checkbox for Process Variables
  36. Click Add Array
  37. Choose the variable Display_Current_User_IncidentsResult
  38. Click OK
  39. Click the ellipses for Item Format:
  40. Add a table to the Advanced Text Editor
  41. Add the variables from the _list_item that you want to display in the table
    Note: You can change the cell padding for the table by going into the source. Also you will need to change the Style of the table to make it fit into your form correctly.
  42. Click Ok to Exit Advance Text Editor
  43. Click Ok to Exit the Component Editor
  44. Click Ok to Exit the Web Form Editor
  45. Click Ok to exit the Embedded Web form editor
  46. Connect all components in the Embedded Decision Model
  47. Click OK
  48. Click Ok to exit the Dialog Workflow Editor
  49. Right click the Create Ticket Component
  50. Select Edit Component
  51. Click the ellipses for Title:
  52. Select Process Variable
  53. Select Add
  54. Select the variable v_IncidentTitle
  55. Select the ellipses for Comment:
  56. Select Process Variable
  57. Select Add
  58. Select the variable v_IncidentComments
  59. Choose the variable you created for the Incident Comments Textbox variable


  60. Click the Associations Tab
  61. Click the ellipses for Contact ID
  62. Select Process Variable
  63. Select [FountContacts[last].ContactID]
  64. Select OK to close


  65. Click OK to Close Create Ticket Editor
  66. Run Project to test functionality

Comments 2 CommentsJump to latest comment

ktran's picture

In "Create Query Script Article", step 15, when click on return data, it pops up a dialog (edit object) asking for Contact ID field (as it is blank).  Are we leaving it blank?

Login to vote
PeeGee's picture

You can leave the ID blank... it will successfully return the needed data, also without any ID specified

Login to vote