using System.Collections.Generic; using Microsoft.Practices.Composite.Modularity; using Microsoft.Practices.Composite.Regions; namespace ModuleA { [Module(ModuleName = "ModuleA")] public class ModuleA : IModule { #region Fields // Member variables private readonly IRegionManager m_RegionManager; #endregion #region Constructor public ModuleA(IRegionManager regionManager) { m_RegionManager = regionManager; } #endregion #region IModule Members public void Initialize() { // Get main region var mainRegion = m_RegionManager.Regions["MainRegion"]; // Load Module A var view = new ModuleAView(); mainRegion.Add(view, "ModuleA.ModuleAView"); } #endregion } }
By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.
If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.
This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)