I'm working on a big project(big for me), where I've one main window that host 3 usercontrols using a library like avalondock to have an IDE-like apparance like visualstudio.
The app should work like this: the main window is loaded and ask with a openfiledialog to open a binary log file, then this log it's displayed in the 3 usercontrols in differtent way (pie chart,line chart and text), if the user change some value in the text view the other have to reflect it. Then if the user want, he can save the changed log with a savefiledialog.
So, I have more than 4k line of code for each usercontrol now; and things start to be a little messy..
So I'm planing to refactor it. For UI reasons I opted to wpf instead of winform; Now the thing that I would avoid is that:
I defined a shared array in the main window, and then to manipulate it from the usercontrol (placed into the mainwindow), I have to refer it as instance, that is not very readable.
I searched and tryed to implement MVVM pattern using a framwork (test done with caliburnmicro and stylet), but I'm struggling to understand how to share data between VMs. Considering that, test after test I had already rewrite the all project 6 time, I'm looking for some advice to made the code more readable and how structure the app, like use or not user design pattterns like mvvm, etc..
So anyone have any advice?