ModuleFactoryFindByGuid Method |
Namespace: AskiaPortalCmn
Find the module using his guid
var context = ContextFactory.CreateByUserGuid(Guid.Parse("20BE5F84-F006-49A0-9674-4B16A090AF2D")); var contextValidation = context.Validate(); if (!contextValidation.Success) { throw contextValidation.Exception; } var homeGuid = Guid.Parse("9821219b-0768-41cc-81d8-cf3b1ade9317"); var homeModule = ModuleFactory.FindByGuid(context, homeGuid); if (homeModule != null) { Console.WriteLine("Module Guid={0} was found: {1}", module.Guid, module.Name); } else { Console.WriteLine("The specified module was not found."); }