Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > ActiveX COM > Report Control
  New Posts New Posts RSS Feed - [SOLVED] Does simple way to set cell backcolor?
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

[SOLVED] Does simple way to set cell backcolor?

 Post Reply Post Reply
Author
Message
fatwood View Drop Down
Newbie
Newbie


Joined: 05 April 2009
Status: Offline
Points: 8
Post Options Post Options   Thanks (0) Thanks(0)   Quote fatwood Quote  Post ReplyReply Direct Link To This Post Topic: [SOLVED] Does simple way to set cell backcolor?
    Posted: 29 November 2011 at 10:22pm
I want to set column(3) backcolor to RED. 

...
Item = Record.AddItem "xxxxxxxxxx"
Item.BackColor = vbRED

Is any smple way to do this?

Like this:

Back to Top
jpbro View Drop Down
Senior Member
Senior Member
Avatar

Joined: 12 January 2007
Status: Offline
Points: 1355
Post Options Post Options   Thanks (0) Thanks(0)   Quote jpbro Quote  Post ReplyReply Direct Link To This Post Posted: 02 December 2011 at 11:30pm
You mean simpler than Item.Backcolor = vbRed?
Product: Xtreme SuitePro (ActiveX) version 16.2.6
Platform: Windows XP - SP3

Language: Visual Basic 6.0 SP6

Back to Top
Aaron View Drop Down
Senior Member
Senior Member
Avatar

Joined: 29 January 2008
Status: Offline
Points: 2192
Post Options Post Options   Thanks (0) Thanks(0)   Quote Aaron Quote  Post ReplyReply Direct Link To This Post Posted: 03 December 2011 at 12:56pm
Hi,
 
Easiest way is to set BackColor in BeforeDrawRow event
 
Private Sub wndReportControl_BeforeDrawRow(ByVal Row As XtremeReportControl.IReportRow, ByVal Item As XtremeReportControl.IReportRecordItem, ByVal Metrics As XtremeReportControl.IReportRecordItemMetrics)
    
    Select Case Item.Index
        Case 1
            Metrics.BackColor = vbRed
        Case 2
            Metrics.BackColor = vbYellow
        Case 3
            ....
    End Select
       
End Sub
 
 
 
Voila Wink
 
 
 
Product: Xtreme SuitePro (ActiveX) version 15.0.2
Platform: Windows XP (32bit) - SP 2
Language: Visual Basic 6.0

Zero replies is not an option....
Back to Top
fatwood View Drop Down
Newbie
Newbie


Joined: 05 April 2009
Status: Offline
Points: 8
Post Options Post Options   Thanks (0) Thanks(0)   Quote fatwood Quote  Post ReplyReply Direct Link To This Post Posted: 29 December 2011 at 3:32am
thx Aaron.
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.203 seconds.