Solved

How to create custom picker control in c# Windows 8.1

Posted on 2015-01-21
4
186 Views
Last Modified: 2015-01-26
I want to create a picker (for Desktop and phone if possible), that has 6 selections (rather then three like the DatePicker). Can this be done? I am fairly new to C#. Does it have to be made from scratch, or can something be copied and modified? I see examples of modifying existing pickers, but not adding to, or creating a new\larger version. Can the User Control template be used to do this?  Is there is an example of creating a whole new picker control that is not a variation of the date\time\color selection controls.   I am thinking that because I can find nothing other than a date\time\color picker, that this cannot be done.  Should I be considering scrolling combo box's?
0
Comment
Question by:eelou
  • 2
  • 2
4 Comments
 
LVL 29

Expert Comment

by:anarki_jimbel
ID: 40563055
I'd say you need a what is called "composite" custom control.  
And in your case, I believe, you need to write it from a scratch.
Try to follow steps in MSDN guidelines:

https://msdn.microsoft.com/en-us/library/vstudio/6hws6h2t(v=vs.100).aspx

https://msdn.microsoft.com/en-us/library/vstudio/5t70dw29(v=vs.100).aspx
0
 

Author Comment

by:eelou
ID: 40565596
That's a bit much for a newbie.  Looks like I will put combobox's next to each other.
0
 
LVL 29

Accepted Solution

by:
anarki_jimbel earned 500 total points
ID: 40565712
Yes, I agree: writing custom controls might be a bit challenging exercise, but it depends on a specific task...

Have a look at this example:
https://msdn.microsoft.com/en-us/library/vstudio/a6h7e207(v=vs.100).aspx

Or try goggling other tutorials and examples.
0
 

Author Comment

by:eelou
ID: 40571118
This might be the way to go, and eventually I might try it.  For now, I am closing this question, as no one else has come up with anything else.
0

Featured Post

Backup Your Microsoft Windows Server®

Backup all your Microsoft Windows Server – on-premises, in remote locations, in private and hybrid clouds. Your entire Windows Server will be backed up in one easy step with patented, block-level disk imaging. We achieve RTOs (recovery time objectives) as low as 15 seconds.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you use NetMotion Mobility on your PC and plan to upgrade to Windows 10, it may not work unless you take these steps.
Today, still in the boom of Apple, PC's and products, nearly 50% of the computer users use Windows as graphical operating systems. If you are among those users who love windows, but are grappling to keep the system's hard drive optimized, then you s…
Windows 8 comes with a dramatically different user interface known as Metro. Notably missing from the new interface is a Start button and Start Menu. Many users do not like it, much preferring the interface of earlier versions — Windows 7, Windows X…
In this video, we discuss why the need for additional vertical screen space has become more important in recent years, namely, due to the transition in the marketplace of 4x3 computer screens to 16x9 and 16x10 screens (so-called widescreen format). …

786 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question