Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 9 years ago.
Improve this question
I want to build the Pentomino game in C#/XAML for Windows 8(8.1). I need field and draggable figures.
How I can do it? For draggable I'm using ManipulationDelta property, but how do I know that the figure is in the field and how do I attach it (figure in field)?
As your question stands, it's too broad.
For future reference, you should try splitting your problem into smaller problems, and asking seprate questions for each of them after doing some home research first.
Also, sharing some code about what you've tried can get more people to help you.
Having said that, I've never worked with XAML, though I've worked with C# for some time now.
About your problems:
For pentomino you will need a board. using Grid or DataGridView sounds like a good approch to me.
For representing your figures, your grid can be queried to find out if your figure can be droped on a certain square. Prepare for writing some for loops.
Abput drag'n drop, here are some links that you may find useful:
XAML GridView to GridView Drag and Drop Mouse vs Touch
Dropping an item on an UserControl item in GridView doesnt trigger Drop event (includes sample project)
How do I drag an element in Windows 8 XAML app?
Related
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 5 years ago.
Improve this question
Is it possible to change the style of datetime picker in windows c# application, I want round shape border to my calendar. Required style and current view is provided in Image . Thank you.
Syncfusion DateTimePickerAdv supports creating rounded corner DateTimePicker. Here is an example.
Screenshot
You need Syncfusion Essential Studio to be installed for the sample to work.
The entire product is available in this link.
Note: I work for Syncfusion.
Short answer: No
Long answer: You can't do that 'out of the box' in win forms application, unless you are ready to pull your hair out to write custom controls (Even then you will not achieve what you are expecting, like above image)
Other options would be to use WPF and/or use some 3rd party controls (like Telerik or Syncfusion)
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 7 years ago.
Improve this question
I know that this question was asked before but i dont know if its me or this question was not answered properly, maybe because im new to programming... anyways i'm creating this application where i'm suppose to display a WPF window over directX games, the window will display normal data like a list or something. can anyone help me by guiding or even posting the code?
SwapChainBackgroundPanel is a XAML element for developing full-screen, primarily DirectX-focused apps. Unlike SurfaceImageSource and VirtualSurfaceImageSource, SwapChainBackgroundPanel is a XAML element rather than an ImageSource; it inherits from the XAML Grid layout panel and enables apps to create and fully control a full-screen DirectX swap chain, on top of which all other XAML content is overlaid
combining-xaml-and-directx
Introducing-DirectX-to-WPF
wpf-and-directx-game-overlay
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
I need to dynamically switch between weeks of year to show some tasks stored in DB in a similar way which is used in Windows Phone 8.1 Calendar app. But I can´t find the best xaml UserControl to get this behavior. I tried to use Hub with three sections, but I can´t figure out how to find out which section is currently showed(which eventHandler from section2 is raised when you move from section1 to section2) to dynamically change displayed section titles.
Any help wold be appreciated.
In the calendar App of Windows Phone 8.1 they're using a Pivot control to show the weeks and switch between them using swipe or clicking the item's inactive header.
Check this out: http://msdn.microsoft.com/en-US/library/windows/apps/xaml/windows.ui.xaml.controls.pivot.aspx
If you want to know which HubSection is currently in the view check this: How can I tell which HubSection is selected
//Nady
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 2 years ago.
Improve this question
I'm trying to make a dashboard application, and I'm trying to create the layout rules for it and such and I'm not sure the best way to go about it. Originally I had a custom grid control, so I could add my custom controls to it easily enough. It worked in the sense that if you initially put stuff there, it was fine. But I want to implement a drag and drop facility in it and it kinda doesn't really like that.
The biggest annoyance is just detecting what position my mouse is on in terms of what row and column its in in the grid. So So I thought instead of a grid, I could use a Canvas, and just manually measure the grid slots. But I'm not sure if there's a better way. I'd like to mimic how on android, you can have widgets for the home screen and you can drag and drop them around the screen. I'd like it to just be like that essentially.
When dragging, I'd like have a green rectangle move instead of the thing and make it red if it overlaps with something else. Like I said, basically just like how android widgets work. I'd love some code examples since I'm new to WPF. If you've got any more general suggestions as well, that would be well appreciated.
Thank you!
check out blacklight and its newer version on github
the dashboard demo is what you need to look at.
You may have trouble to compile the code, but simply by removing the silverlight projects you can get the WPF demo running.
I know this is an old question. Creating this answer for anyone else who stumbles onto this question looking for a WPF Dashboard. I couldn't find any other Dashboards with dynamic widgets out in the wild so I created my own and I am sharing for anyone else who needs a better solution. This sounds like what Gentatsu was looking for in his initial question.
You can find it here:
https://github.com/DustinBryant/WpfDashboardControl
Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 9 years ago.
Improve this question
I'm using visual studio 2012 and i'm finding it extremely difficult(and irritating) to handle multiple panels. I have almost 20 panels stacked on top of each other. I had to make changes to a lower panel so I removed the panels from the top and updated it. Now the lower panel buttons and group boxes keep sticking on all other upper panel buttons and keep covering them.
So basically i can't see half portion of upper panels as the lower panel's controls keep covering 'em up. I don't know what caused this. Please help me out.
Without seeing what your problem looks like it is hard to answer, but since you have multiple panels you probably accidently changed the Parent of some of your controls or panels.
I find that working with layered controls can be a pain, you need to get used to using the BringToFront and SendToBack Editor Commands.
To answer your question you can try looking at your InitializeComponent Method to see if you can determine exactly what happened.