This question relates to the one shown here http://fogbugz.stackexchange.com/questions/5316/wiki-page-generator.
Basically I use code similar to this as follows:
CWikiPage newWikiPage = api.WikiPage.NewWikiPage();
newWikiPage.ixWiki = 3; //3 is Wiki We want it to belong to
newWikiPage.sHeadline = "TEST PAGE";
newWikiPage.sBody = "<h1>Test Page Content</h1>";
newWikiPage.ixWikiPageParent = 5146; //Make thos a Child page
newWikiPage.CommitWithComment("Create Test Page");
This creates a Wiki Page in the desired Wiki as a child to the specified WikiPage, however the WikiPage does not seem to be saved correctly. When I do other Queries the WikiPage does not show up until I go to the page with the Wiki UI and click edit and save it, then the page will show up in Queries. Also the color of the in the side navigation pane is lighter until I go and manually save it. I think the light color means the Wiki is new but not yet saved? Is there a way to save it via code so the user does not need to go and manually save it before I can access it via Database Query?