LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

.NET Month Calendar - How to determine if showing months instead of days?

This KB

https://knowledge.ni.com/KnowledgeArticleDetails?id=kA00Z0000004AQ2SAM&l=en-US

shows how to create a UI using the .NET MonthCalendar control.

 

Is there a way to determine when the control is showing months

MGiacomet_0-1647194333756.png

 

instead of dates?

MGiacomet_1-1647194382556.png

 

0 Kudos
Message 1 of 8
(1,641 Views)

Wow! Why "didn't" I think about Google...

 

Seriously, I can't find a property/method/event that answers my question. Maybe you can Google again?

0 Kudos
Message 3 of 8
(1,582 Views)

@MGiacomet wrote:

Wow! Why "didn't" I think about Google...

 

Seriously, I can't find a property/method/event that answers my question. Maybe you can Google again?


This person went out their way to insulate you from doing the Googling yourself.  Be more respectful in your replies, or Google may be the only help you get.

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
0 Kudos
Message 4 of 8
(1,574 Views)

@MGiacomet wrote:

 

Seriously, I can't find a property/method/event that answers my question. Maybe you can Google again?


That's because there is none! Maybe you can "guestimate" if it is in one mode or the other from reading a combination of properties and doing some smart interpolation between them, but the documentation on MSDN is the canonical documentation and if it isn't documented in there, it almost certainly is not present (or hidden by Microsoft for some good reason).

 

In any case, it is not a LabVIEW problem but a Microsoft problem that you have to take up with them if you hope for a different answer.

Rolf Kalbermatter
My Blog
0 Kudos
Message 5 of 8
(1,569 Views)

The .NET is a wrap around Win32 API.

There is a link on that page, "For more information on month calendar controls, see Month Calendar Control Reference."

You can solve the problem by sending a message (MCM_GETCURRENTVIEW) to the window.

 

George Zou
Message 6 of 8
(1,559 Views)

Thank you very much, Zou!

0 Kudos
Message 7 of 8
(1,522 Views)

@zou wrote:

The .NET is a wrap around Win32 API.

There is a link on that page, "For more information on month calendar controls, see Month Calendar Control Reference."

You can solve the problem by sending a message (MCM_GETCURRENTVIEW) to the window.


It seems that the .Net wrapper is pretty old. It doesn't support this and many other messages and all of them are declared to be added in Windows VISTA or newer. So the .Net wrapper seems not to have been updated since Windows XP. 

Rolf Kalbermatter
My Blog
0 Kudos
Message 8 of 8
(1,510 Views)