Results 1 to 9 of 9

Thread: Changing colour of cell in Microsoft Calendar Control?

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Sep 2002
    Location
    South Africa
    Posts
    105

    Changing colour of cell in Microsoft Calendar Control?

    I am using the Microsoft Calendar Control 9.0. What I want to do is change the colour of a specific cell on a specific date. (either the backcolour of the cell or the colour of the date) How do I do this in code?

  2. #2
    PowerPoster
    Join Date
    Aug 2001
    Location
    new jersey
    Posts
    2,904
    suggestions:

    1) use the object browser to find the properties and methods that you need

    2) do what you want while capturing a macro and see what the code is behind the macro

  3. #3
    Fanatic Member WorkHorse's Avatar
    Join Date
    Jul 2002
    Location
    Where you live.
    Posts
    591
    phinds: How do you record s macro on a Calendar control?

    The Calendar control doesn't support properties to change a single day font. It's not that fancy of a control. Work-arounds aren't pretty: Either throw up another control (label, tetbox, picture, etc.) that looks like the day button and have the click event change the Calandar date, or write a bunch of APIs, which I wouldn't even try, or find/buy a different control, or make your own, or make a mock-up calendar using other controls. It would be nice if Calendar could do this so you could highlight Today or Holidays, etc., but it doesn't.

  4. #4
    PowerPoster
    Join Date
    Aug 2000
    Location
    IN SILENCE
    Posts
    6,441

    Well

    I tried this awhile back without success. Now I just use a DTpicker control...
    Remaining quiet down here !!!

    BRAD HAS GIVEN ME THE ULTIMATIVE. I have chosen to stay....

  5. #5
    Fanatic Member WorkHorse's Avatar
    Join Date
    Jul 2002
    Location
    Where you live.
    Posts
    591
    Is DTpicker a component available in VB6. It's not in my VB5 list or VBA6. I don't have VB6 on hand to check. I haven't tried the DTpicker. Do I need to use VB6 to get the component or is it in a reference somewhere?

  6. #6
    -= B u g S l a y e r =- peet's Avatar
    Join Date
    Aug 2000
    Posts
    9,629
    Hi there WorkHorse, the DTP is found in the components list, you have to find 'Windows Common Controls-2 6.0'. I do not know if this shipped with vb5 or not...

    the name of the file is MSComCt2.ocx

    -= a peet post =-

  7. #7
    PowerPoster
    Join Date
    Aug 2000
    Location
    IN SILENCE
    Posts
    6,441

    Well

    If he had the SP5 patch, wouldn't he have access to the control?
    Remaining quiet down here !!!

    BRAD HAS GIVEN ME THE ULTIMATIVE. I have chosen to stay....

  8. #8
    -= B u g S l a y e r =- peet's Avatar
    Join Date
    Aug 2000
    Posts
    9,629
    I really don't know James, I know its shipped with VB6 all editions, but VB5 SP X, I don't know
    -= a peet post =-

  9. #9
    PowerPoster
    Join Date
    Aug 2000
    Location
    IN SILENCE
    Posts
    6,441

    Well

    I tried to attch it here, but it's too large. I can send it to you if you provide your email address...
    Remaining quiet down here !!!

    BRAD HAS GIVEN ME THE ULTIMATIVE. I have chosen to stay....

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