CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 1 of 1
  1. #1
    Join Date
    Nov 2005
    Posts
    36

    MSChart Row and Column Names

    I am pulling my info. from a database. The info is comparing software. There are two sessions, one for software in general and one for people that use it everyday. Let's say that 100 people use Outlook, but only 50 use it everyday. So bar1 in row1 will be 100 and bar2 in row1 will be 50.

    I have gotten mostly everything to work, however I can't seem to change the title of the rows. They are stuck at R1, R2...etc

    From the database I am creating a multi-dimensional array.

    Code:
     
    intValue(0) = rs.Fields("Total") 'rs is collection from software
    intValue(1) = rs2.Fields("Total") 'rs2 is collection from everyday use
    
    arrArrayValue(1,1) = "Software"
    arrArrayValue(1,2) = "Everyday Use"
    'This renames the columns C1,C2 into my string
    
    arrArrayValue(1,1) = intValue(0)
    arrArrayValue(1,2) = intValue(1)
    'This set the 2 sets of bars in each row to the value I pulled from my RS
    From what I have researched, doing
    Code:
    arrArrayValue(1,1) = "Outlook"
    arrArrayValue(1,2) = intValue(0)
    arrArrayValue(1,3) = intValue(1)
    Should set the name of the row from R1 to "Outlook" and of course set up the bars as well.

    When I try to use this, it just appends the string to my column name though

    Is there a way to set both column and row names in the array itself, or is there an MSChart property to this?

    Thanks a bunch,
    Buddy


    ***EDIT***

    I got it figured out! If anyone would like to know how, just respond to this post.
    Last edited by Buddy008; January 26th, 2006 at 12:06 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured