Symantec Connect
  • Login
  • Register
  • Endpoint Management & Virtualization
    • All of Connect
    • Backup and Archiving
    • Endpoint Management & Virtualization
    • Storage and Clustering
    • Security
    • Inside Symantec
    • Vision User Conference
    • Partners
    • Developers
    •  
  • Overview
  • Forums
  • Articles
  • Blogs
  • Downloads
  • Events
  • Videos
  • Groups
  • Ideas
Login to participate
Endpoint Management & Virtualization Community BlogRSS

Dynamic Colors in the WorkitemView Console

PeeGee's picture
PeeGee
August 12th, 2008
Filed under: Helpdesk Solution, Basics, Configuring, Performance, Endpoint Management & Virtualization Community Blog, Endpoint Management and Virtualization

Out of the box, Helpdesk Solution does not provide any possibility to highlight incidents which have a high priority or a specific status.

In the KB you can find the following article: https://kb.altiris.com/article.asp?article=34253&p=1 Which deals with color coding the Incident Grid, which is already a big help. But on the day to day basis it also handy to find the same highlight colors, when looking at a single incident.

The code of this article shows, how the background color of the "Priority" field can be changed, depending on the priority. Of course this can be used for any other field as well.

Compared to the JavaScript approach of the above KB article, I simply use duplicate priority fields (one per priority) but only show the priority field which reflects the priority of the current incident I am looking at.

As the other priority fields are automatically hidden, there is no shifting of the label orders.

For the next part I assume, that a custom worker console has been created and that a re-direction of the workitemview.aspx file to a custom location has already been configured.

How to do it

  1. In the custom worker console edit the file workitemview.ascx
  2. Find the line which starts with <aw:Label id="lblPriority" runat="server" ...
  3. Replace the entire code in the line with the following code:
    <aw:Label id="lblPriorityasap" runat="server" style="background-color:red" ItemDataField="workitem_priority_lookup_value" label="sidLblPriority" Visible='<%# DataStore("WorkItem").current.workitem_priority_lookup_id = "100" %>'></aw:Label>
    <aw:Label id="lblPriorityhigh" runat="server" style="background-color:red" ItemDataField="workitem_priority_lookup_value" label="sidLblPriority" Visible='<%# DataStore("WorkItem").current.workitem_priority_lookup_id = "200" %>'></aw:Label>
    <aw:Label id="lblPrioritymedium" runat="server" style="background-color:#addfff" ItemDataField="workitem_priority_lookup_value" label="sidLblPriority" Visible='<%# DataStore("WorkItem").current.workitem_priority_lookup_id = "300" %>'></aw:Label>
    <aw:Label id="lblPrioritylow" runat="server" style="background-color:#cfecec" ItemDataField="workitem_priority_lookup_value" label="sidLblPriority" Visible='<%# DataStore("WorkItem").current.workitem_priority_lookup_id = "400" %>'></aw:Label>
    <aw:Label id="lblPriorityplanned" runat="server" style="background-color:#cfecec" ItemDataField="workitem_priority_lookup_value" label="sidLblPriority" Visible='<%# DataStore("WorkItem").current.workitem_priority_lookup_id = "500" %>'></aw:Label>
    
    
  4. Save the changes to the file and re-load the WorkitemView Page.

Now the priority field should have a background color, depending on the status of the priority. Feel free to adjust the colors via the background-color: tag.

The below screenshot also shows the similar trick for the status field.

Click to view.

0 votes
  • PeeGee's blog
  • Login or register to post comments
  • Comments RSS Feed
johnquinn's picture
johnquinn
1 year 31 weeks ago

Nice and a question

I like this a lot. I use the color in the grid currently and I like the idea of bringing the same scheme over while looking at an individual incident.

One quick question though for I'm new to scripting. With some of the darker colors, when you apply this the text is not very visible.

What would you add to this line to make the text itself stand out? I've tried entering in the style section things like text:white and color:white but they have no effect.

0 votes
  • Login or register to post comments
PeeGee's picture
PeeGee
1 year 31 weeks ago

check your syntax

Hi johnquinn,

you actually got the answer already. You need to set the "color" tag, just make sure that you get the syntax right. Inside the style tag, you need to separate different style settings with a ";".

So it should look like this:
"...style="background-color:black; color:red"

0 votes
  • Login or register to post comments
johnquinn's picture
johnquinn
1 year 31 weeks ago

That did it

PeeGee, that was it. When I was first trying it, I was simply using a space in the style. By putting the semi-colom in between, using color:white set the text to white so it stands out.

Thanks for the help.

0 votes
  • Login or register to post comments
syarlett's picture
syarlett
1 year 28 weeks ago

Any idea how to make the

Any idea how to make the words 'category' , 'status' , 'Assigned' etc.... stand out in bold.

I know i need to start with [B] and end with [/B] but cant seem to get it in the right place....

0 votes
  • Login or register to post comments
PeeGee's picture
PeeGee
1 year 27 weeks ago

Edit the CSS file

The label tags configuration is defined in the styles.css file which can be found in \AEXHD\css
Find the section .clslabel and modify FONT-WEIGHT:
to read
FONT-WEIGHT: bold;

Save your .css file and you are done.

Of course you should not edit it directly in the css folder, as you'll lose this change on upgrade or repair, so make sure that you add the styles.css file into your custom.config file and direct it to a custom location of the modified version.

0 votes
  • Login or register to post comments
syarlett's picture
syarlett
1 year 13 weeks ago

Only when Active

Hi,

Is there a way to show the colours only when the call is Active? So when i call is resolved or closed, it would just normal text?

Regards Steve

0 votes
  • Login or register to post comments
syarlett's picture
syarlett
1 year 26 weeks ago

Thanks Peegee,If i make

Thanks Peegee,

If i make the change directly to the styles.css file, the results are perfect.
Could you please advise where i'm going wrong in naming the custom file?

I already have a custom.config file.
In here i've added a line which says

file id="Styles" file="CustomStyles.css"

And then i've copied the original styles.css file to my Custom folder and made the change to the .clslabel section.

I've restarted IIS, but the changes dont reflect. I'm assuming the error lies in my Customstyles.css file?

0 votes
  • Login or register to post comments
PeeGee's picture
PeeGee
1 year 26 weeks ago

The file id should be

The file id should be "stylescss"

0 votes
  • Login or register to post comments
jrivard's picture
jrivard
1 year 25 weeks ago

Nice Job - Quick Question

In reference to the article of adding colors to the workitemgrid view Color coding the Helpdesk incident grids Does any one know how to grab the information in the cell and pass it to a variable? I am trying to grab the Modified Date and then compare it to the date now using the "DiffDate" function for VBscript. "nCol+2" is over two positions from the present column which would be the Modified Date column.

I tried the following:

Dim dt as Integer
Dim CurrentDate as Date = Now

ModifyDate = "" & grid & ".Cell(0, nRow, nCol+2)"
dt = DateDiff("n" , ModifyDate, CurrentDate)

but I recieve the following as the error:

Exception - System.InvalidCastException: Cast from string "_ctl0__ctl39__ctl0__ctl1_wgWorkI" to type 'Date' is not valid.
at Microsoft.VisualBasic.CompilerServices.DateType.FromString(String Value, CultureInfo culture)
at Microsoft.VisualBasic.CompilerServices.DateType.FromString(String Value)
at ASP.subWorkItemTable_ascx.FinalizeTemplate()
at Altiris.AppWeaver.TemplateControl.OnPreRender(EventArgs e)

0 votes
  • Login or register to post comments

Would you like to reply?

Login or Register to post your comment.

About Endpoint Management and Virtualization Community Blog

The Endpoint Management & Virtualization Community Blog is the perfect place to share short, timely insights including product tips, news and other information relevant to the Endpoint Management & Virtualization community. Any authenticated Connect member can contribute to this blog.
Filter by:

Recent Blog Posts

  • How to Install and Uninstall IBM Installation Manager using XML files
    WiseUser - March 18, 2010
  • Future Tech - Silverlight and phones (Altiris future mobiltity)
    Palvaran - March 16, 2010
  • Webcast - Redefining Endpoint Management with Altiris IT Management Suite 7.0 from Symantec
    ohzone - March 15, 2010
  • USB Swiss Army Knife: 7 Quick Fix
    riva11 - March 12, 2010
  • Cebit is over. What will be our next big show?
    erikw - March 12, 2010

Blog Tags

7.1 Agents Altiris Client Management Suite Altiris Deployment Solution Altiris IT Asset Management Altiris Notification Server Altiris Recovery Solution Altiris Server Management Suite Asset Management Suite Backup Exec Backup Exec System Recovery Basics Best Practice Beta CIO Digest Case Study Compatibility Configuring Customer Preview Customer Reference Database Dell Dell Management Products Demonstration Documentation Downloads Drivers Emerging Threats Endpoint Management and Virtualization Endpoint Protection (AntiVirus) Enterprise Vault Error messages Evaluating Features General Symantec Ghost Solution Suite HP Management Products Helpdesk Solution How to ITMS Industry Event Inside Symantec Installing Licensing Linux Local DS GURU Email group Mac OS ManageFusion Mobile & Wireless NetBackup New Release News News Performance Platforms & Hardware Problem Management Recovering Reporting Restore SP2 SecurityExpressions Service Pack 2 ServiceDesk Storage Foundation Symantec Connect Symantec Event TMS TechTips Tip/How to Tips/How To Training Troubleshooting Upgrade User Group VDI VMware Virtualization Virtualization Vision Vulnerabilities & Exploits Windows Windows Wise Application Packaging Wise Installation Development Wise Virtual Composer Workflow Solution Workspace Corporate Workspace Profiles Workspace Remote Workspace Streaming Workspace Virtualization XPF baltimore deployment hugo known_issue pcAnywhere solution webcast
© 2010
  • Symantec Corporation
  • Contact Us
  • Get RSS
  • Privacy Policy
  • Symantec.com