I have a master page with a menu and submenu, which point to SiteMapDataSources that reference a Web.config file in my project. These are working fine with the exception of one quirk. Because of the way I would like to organize the pages on the site I need some pages to reside in directories that do not have default.aspx files defined for them. For example:
\
Default.aspx
Directory1\
Default.aspx
Page1.aspx
Directory2\
Page2.aspx
If a Page2.aspx resides in the sitemap and the menu entry for Page2.aspx is pressed an error is generated that states "Could not find the sitemap node with URL '~/Directory2/'." Obviously I can get around this by creating a default.aspx page in Directory2 and including it in the menu, but I don't want to.
Is there a way to disable the functionality of the menu, SiteMapDataSource or the Web.sitemap to not bother checking whether a default page was included and just use the sitemap as a menu structure? I've looked over the relevant methods and properties but I have not found anything promising. Or do I need to programmatically create the menu structure and assign it to the menus instead of using a sitemap file?
Thanks!
Robert