I'm currently working on a WPF project under VS2010 where I need to make some CRUD operations directly using a datagird, so I've found it easier to work on Binding WPF Controls to an Entity Data Model which allows a lot of additional features that made my work easier.
so I've followed this tutorial http://msdn.microsoft.com/en-us/library/dd465159(VS.100).aspx
and everything is working fine for me .
But the problem that I'm now facing is how to make Insert/Delete Operations using the same method. I've tried to google this problem a lot but I couldn't find the right answers, so I come to you guys hoping to find some help.
Related
I'm learning ReactiveUi and trying the sample from here https://reactiveui.net/docs/getting-started/ This is a great examle, but now I would like to replace the List SearchResults with a ICollectionView to have more grouping / sorting capability.
The documentation contains a ReactiveCollectionViewSource here and but I'm unable to find a sample how to use it with the starting code. Is that the right track?
The ReactiveCollectionViewSource is for the iOS project only.
You should be able to use standard WPF ways of generating your CollectionView and use CollectionViewSource.GetDefault() etc.
You can then use WPF or ReactiveUI bindings to bind that to your controls.
One thing of note is that DynamicData is going to be in the near future the preferred solution for data management in RxUI projects. Worth seeing if it fits in your problem space. https://github.com/RolandPheasant/DynamicData - There is a DynamicData channel on the Reactive slack channel if you need help with the framework https://reactiveui.net/slack
Recently I started a project in WinForms. I'm coming from WPF background and I find some things new to me. For example every time I want to change a property of WinForms control I have to scroll up and down to find it.
It drives me mad. I would rather type first few letters of looked up property and edit it in a couple of seconds. Is there a way to speed up this annoying process?
There is no easy way to filter properties of control. I know how you feel, as I switch between WPF and WinForms from project to project. But you can always either Categorize them or sort them alphabetically... I am sure you'll get used to it eventually, but you have to understand though, Windows Forms are not as "innovative" as WPF is. Therefore you'll see some things are rather more "traditional" than WPF in WinForms! Sorry mate :)
There is a VS Extension called RapidDesign. It is a payed project but I think it's worth the price. It does exactly what you need and even more. (Note!!! I am not connected in anyway with the author/company that develops this product)
https://visualstudiogallery.msdn.microsoft.com/c820e3a0-add2-4a43-943c-029e296ab00d
You can download the extension directly from VisualStudio galery or you can install it from inside VS by going to Tools->Extensions And Updates...->Online->and search for RapidDesign
This might be a stupid question, but there are soo many combinations of approach (wpf, silverlight, winforms, html5) with incompatibility at mscorlib level, that I got completely lost.
I would like to be able to have a few windows mainly displaying realtime charts.
Probably with interaction among the windows (click in one, pop and display a new windows)
If it can be viewed on the web, perfect.
But I dont want to have to deal with another layer of nasty stuff for those features (like having to setup some "WCF" on a "IIS", kill me first)
In the end I was thinking of using FSharpChart on Silverlight.
Is that possible and/ or the best option ?
Thanks for your suggestions
update
I see that system.drawing which fsharpchart relies on is not silverlight supported..
Try Dynamic Data Display instead of FSharpChart. It runs on Silverlight: http://research.microsoft.com/en-us/um/cambridge/groups/science/tools/d3/dynamicdatadisplay.htm
It's not as F# Interactive friendly as FSharpChart, but you can easily wrap it in a handful of functions to make it more usable
Hi i am trying to find the best way to manage the Data (that comes from tables in a Database) in your App.
My main question is, what is the best approach to take to then i successfully work with Bindings, Notifying Properties/Collections Changes?
My App is to manage the Inventory of all kind of things in an Enterprise, so i collect the Data to my App, and then i am using DataViews to store it? But this is the best approch to then i can work with bindings and Notifying Changes?
I am recently entering in WPF (about 2 months), the concept of ViewModel it's what i am trying to understand now, because seems that is the most thing used to manage the Data stored in an WPF App. Or maybe i am understanding all wrong.
What I am asking is for advices and examples to then i understand which is the best aprroach.
Note: In my case i have a Main Window with a DataGrid which have DataGridTextColumns and DataGridComboBoxColumns, and i have auxiliary Windows to manage Categories, Places and etc with ListViews.
Thanks in advance!
When we are talking about WPF, then of-course we are talking about MVVM pattern, its the best way :)
This link is the best start point for MVVM pattern:
MVVM for Beginners
A while ago, I posted a question regarding switching between a Blend-authored GUI and a Visual Studio-authored one. I got it to work okay by adding my Blend project to my VS2008 project and then changing the Startup Application and recompiling. This would result in two applications that had completely different GUIs, yet used the exact same ViewModel and Model code. I was pretty happy with that.
Now that I've learned about the Laurent Bugnion's MVVM Light Toolkit, I would really like to leverage his efforts to make this process of supporting multiple GUIs for the same backend code possible. The question is, does the toolkit facilate this, or am I stuck doing it my previous way?
I've watched his video from MIX10 and have read some of the articles about it online. However, I've yet to see something that indicates that there is a clean way to allow a user to either dynamically switch GUIs on the fly by loading a different DLL. There are MVVM templates for VS2008 and Blend 3, but am I supposed to create both types of projects for my application and then reference specific files from my VS2008 solution?
UPDATE
I re-read some information on Laurent's site, and seemed to have forgotten that the whole point of the template was to allow the same solution to be opened in VS2008 and Blend. So anyhow, with this new perspective it looks like the templates are actually intended to use a single GUI, most likely designed entirely in Blend (with the convenience of debugging through VS2008), and then be able to use two different ViewModels -- one for design-time, and one for runtime.
So it seems to me like the answer to my question is that I want to use a combination of my previous solution, along with the MVVM Light Toolkit. The former will allow me to make multiple, distinct GUIs around my core code, while the latter will make designing fancy GUIs in Blend easier with the usage of a design-time ViewModel. Can anyone comment on this?
I checked your previous question and this one, and I had never really heard about switching projects to work in Blend and in Studio, and end up with two different UIs. I think this was not the intent of MSFT when they built Blend. Instead, the possibility to open the exact same project and code files in both IDEs (and all the discussions I had with the various teams at MSFT) hints that the intent was in fact to have one application only which can be edited in both environments.
I think that in the end, the goal is to have a variety of tools that you can use to edit your UI - XAML, Visual Studio designer, Blend. Depending on your role in the project (developer, designer, integrator) and depending on your ability with the tools, you can choose one or the other.
This doesn't mean that we never switch templates! Depending on the kind of application (for example between a SL4 desktop application or a WinPhone7 application), we use the same ViewModel (and below) code, but slap a different UI altogether on the files. I demoed how to do that in this video:
http://channel9.msdn.com/posts/kreekman/TechDays-2010-Understanding-the-Model-View-ViewModel-pattern/
This is the same talk I gave at MIX but extended by 15 minutes where I show how to reuse the ViewModel and model files, but use a completely different UI for WinPhone7.
Another application is switching templates when a window is resized (used very often in WPF, but also applicable to Silverlight) in order to show less details or a different layout for different screen sizes.
I hope that this reply doesn't confuse you :) and in fact, I'd love to hear your comments on that before we continue the discussion.
Cheers,
Laurent
I think MEFedMVVM would be a good candidate for this. It is simple and you can combine it with other frameworks.