CodeGen error in v1.10.2 $20 PayPal Bounty
I do not have my Stripe account set up yet, so I am offering a $20 bounty for some help with this problem.
I am new to Orchard and am in the process of going through the Dojo Course videos provided by Lombiq. (Thank you Lombiq for some great videos!)
I am concerned that I may not be configuring Visual Studio correctly and that is causing the following codegen error. I checked the error log and it was empty.
Please tell me what I am doing wrong or am failing to do.
Thanks very much.
Procedure to re-create codegen error.
1. Copy Orchard Source to a new folder: a. create a new folder b. copy OCms v1.10.2 lib and src folders to new folder 2. Rename .sln file from Orchard.sln to OCmsCodeGenErrorTestProj.sln 3. Open solution in Visual Studio 2017 Community. 4. Build solution to confirm no errors: Build succeeded. 5. Start/Configure Web Site a. In VS2017, type Ctrl/F5 to start web site b. Site name: OCmsCodeGenErrorTestSite c. user name: admin d. password: password e. Data: SSCompact f. Recipe: Default Site started successfully. 6. Create scaffold for new Theme. a. Using Windows Explorer, under Orchard.Web folder, opened "bin" folder b. right clicked Orchard.exe c. selected "run as administrator" option The command line window appeared. d. at "orchard>" prompt, entered: "feature enable Orchard.CodeGeneration" "Code Generation was enabled" message appeared. e. at orchard> prompt, entered:
codegen theme DojoCourseTheme /CreateProject:true /IncludeInSolution:true /BasedOn:TheThemeMachine
The "Creating Theme DojoCourseTheme" message appeared followed by this error:
---------(beginning of error text)----------------
Error executing command "codegen theme DojoCourseTheme"
Specified argument was out of the range of valid values. Parameter name: startIndex"
Exception Details: System.ArgumentOutOfRangeException: Specified argument was out of the range of valiid values. Parameter name: startIndex
[ArgumentOutOfRangeException: Specified argument was out of the range of valid values. Parameter name: startIndex] at System.String.Insert(Int32 startIndex. String value)
at Orchard.CodeGeneration.Commands.CodeGenerationCommands.AddToSolution(TextWriter output, String projectName, String projectGuid, String containingFolder, String solutionFolderGuid)
at Orchard.CodeGeneration.Commands.CodeGenerationCommands.CreateThemeFromTemplates(TextWriter output, String themeName, string baseTheme, String projectGuid, Boolean includeInsolution)
at Orchard.CodeGeneration.Commands.CodeGenerationCommands.IntegrateTheme(String themeName, string baseTheme)
at Orchard.CodeGeneration.Commands.CodeGenerationCommands.CreateTheme(String themeName)
---------(end of error message text)----------------