473,386 Members | 1,821 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Extending Month Calendar

How can I extend the MonthCalendar control to allow multiple date ranges to
be selected?

For example, I'd like to pass 01/01/2003 - 04/01/2003, 08/01/2003 -
14/01/2003 and have both ranges selected on the control.

Any help would be appreciated!
Nov 15 '05 #1
3 8631
Ed,

You can not. What you really need to do is have a custom control which
will have two instances of the MonthCalendar controls, one for the beginning
of the date range, and one for the end. Then, you can have multiple
instances of this control to indicate multiple ranges.

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Ed Crowley" <cu******@pacbell.net> wrote in message
news:Ou**************@TK2MSFTNGP09.phx.gbl...
How can I extend the MonthCalendar control to allow multiple date ranges to be selected?

For example, I'd like to pass 01/01/2003 - 04/01/2003, 08/01/2003 -
14/01/2003 and have both ranges selected on the control.

Any help would be appreciated!

Nov 15 '05 #2
Is it not possible to use the ownerdraw property to manually highlight
certain date ranges?

The calendar just needs to be read-only, getting the date ranges from a
database.

"Nicholas Paldino [.NET/C# MVP]" <mv*@spam.guard.caspershouse.com> wrote in
message news:u0**************@TK2MSFTNGP12.phx.gbl...
Ed,

You can not. What you really need to do is have a custom control which will have two instances of the MonthCalendar controls, one for the beginning of the date range, and one for the end. Then, you can have multiple
instances of this control to indicate multiple ranges.

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Ed Crowley" <cu******@pacbell.net> wrote in message
news:Ou**************@TK2MSFTNGP09.phx.gbl...
How can I extend the MonthCalendar control to allow multiple date ranges

to
be selected?

For example, I'd like to pass 01/01/2003 - 04/01/2003, 08/01/2003 -
14/01/2003 and have both ranges selected on the control.

Any help would be appreciated!


Nov 15 '05 #3
Ed,

It would be, but the amount of code you would have to do in order to do
this would be massive compared to just having two calendar controls. Also,
having two controls I think would be a better experience for the user, as it
is more clear that you have to set endpoints.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Ed Crowley" <cu******@pacbell.net> wrote in message
news:uF****************@tk2msftngp13.phx.gbl...
Is it not possible to use the ownerdraw property to manually highlight
certain date ranges?

The calendar just needs to be read-only, getting the date ranges from a
database.

"Nicholas Paldino [.NET/C# MVP]" <mv*@spam.guard.caspershouse.com> wrote in message news:u0**************@TK2MSFTNGP12.phx.gbl...
Ed,

You can not. What you really need to do is have a custom control

which
will have two instances of the MonthCalendar controls, one for the

beginning
of the date range, and one for the end. Then, you can have multiple
instances of this control to indicate multiple ranges.

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Ed Crowley" <cu******@pacbell.net> wrote in message
news:Ou**************@TK2MSFTNGP09.phx.gbl...
How can I extend the MonthCalendar control to allow multiple date
ranges to
be selected?

For example, I'd like to pass 01/01/2003 - 04/01/2003, 08/01/2003 -
14/01/2003 and have both ranges selected on the control.

Any help would be appreciated!



Nov 15 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: yaron | last post by:
Do someone know how to reach the access methods of the "month calendar" controler in MFC? Such like getting the date value. Thanks Yaron
0
by: Brian Henry | last post by:
Why does the month calendar have a circled date in design view of it but at runtime its a square that is only 1 pixel wide? it's very hard to see on the high res screens we are using and a thicker...
0
by: Mini Nutz | last post by:
Hi to everyone, I am currently designing a form that uses the MonthCalendar control, other panels are displayed for each day selected with the month calendar. My problem is that after 2...
4
by: Rain | last post by:
Hello, Does anyone know how i can disable the range selection in a month calendar control? I mean i dont want users to to select a range of dates. Can i do this? how? thank you so much.. and...
6
by: dwadish | last post by:
Hai guys !! help me if any code/ property support to a month calendar for enlarging it's size. i want to show pictures in a picture box when changing the month from the calendar control. Can I...
7
by: ajaydesai | last post by:
I have JavaScript code to dispaly two month calendar days at a time, but i have a problem both month that disaplay at a time have same days (for example May and June has same days, June and July have...
6
by: thamaraikeeran | last post by:
i want to display the selected date from the month calendar in the textbox.please tell me how to do?plz reply quikly.
5
by: =?Utf-8?B?bWFib25k?= | last post by:
Hi Using a month calendar control so that my user can select a start and end date for a range that will be used in a SQL query. Problem.....if user selects a date in one month and then scrolls...
3
by: Droopy | last post by:
Hi, Iam using a MonthCalendar.I have hosted this in a popup control.On click of an image,i get my month calendar(i.e. the popup) displayed.Once i choose the date ,the selected date gets populated...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.