Here is the error message in part:
Error parsing Website
TemplateCould not find a part of the path
'C:\HostingSpaces\abetterfund\dev.abetterfundraiser.com\wwwroot\Portals\_default\EventQueue\EventQueue.config'.
at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath) at System.IO.FileStream.Init(String
path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights,
FileShare share, Int32 bufferSize, FileOptions options
Note this part: EventQueue\EventQueue.config this path part doesn't exist. Code that I wrote to find where a portal id isn't in Portal Alias, which verifies a botched programmatic child portal creation and then deletes the portal, is after this block of code. Since the code throws the exception above ... my fix doesn't fire in this use case:
intPortalId = objPortalController.CreatePortal(txtPortalName.Text,
adminMasterRep,
txtDescription.Text,
txtKeyWords.Text,
template, <-- the template is passed here. The exception is being swallowed in the Portal Controller Create Portal event and doesn't bubble up. This particular code itself is in the Try{} in my code but the Catch{} doesn't see it so I can't fire my code there either. (Or in Finally{} for the same reason)
homeDir,
strPortalAlias,
strServerPath,
strChildPath,
blnChild);
There is still a work around. When the error comes up, have the end users instructed to browse back to refresh the page. And in the Page Load event, set up a link to find the Portal entry with no matching Portal Alias, either allowing user intervention or handling the delete in this case on page refresh but give the user a friendly message to try again.
It seems the portal creation code is buggy. Any input on how to fix this without a laborious work around is appreciated.
There is a fix for regular ASP.Net sites to create a Services Project but unless I miss something, to use that in DNN requires a core code edit. That link is here: http://support.microsoft.com/kb/827421
Thanks!