protected override void ExecuteCmdlet() { switch (ParameterSetName) { case "WithContent": { SelectedWeb.AddWikiPageByUrl(ServerRelativePageUrl, Content); break; } case "WithLayout": { SelectedWeb.AddWikiPageByUrl(ServerRelativePageUrl); SelectedWeb.AddLayoutToWikiPage(Layout, ServerRelativePageUrl); break; } default: { SelectedWeb.AddWikiPageByUrl(ServerRelativePageUrl); break; } } }