Dear All,
I created a web site in dotnetnuke and uploaded it online(HostingServer), but it is not working and it is giving me an error "Object reference set to an instance".
When i tracked it down on hosting server , i found that it is at the follwoing code position , error is listed below the code.
It does not find ADMIN/SKINS/Language.ascx file even though it is present at the same location.
Kindly advise me whats the problem and how can i solve it, because i am stucked and cannot move forward with the web site.
I think it is not loading the ctlSkin object properly and it gives me an error on default.aspx.vb page at ctlSkin.ID="DNN"
Thank you in advance
-------------------------------------------------------------------------------------------------------
Private Function LoadSkin(ByVal SkinPath As String) As DotNetNuke.UI.Skins.Skin
Dim ctlSkin As DotNetNuke.UI.Skins.Skin = Nothing
Try
If SkinPath.ToLower.IndexOf(Common.Globals.ApplicationPath.ToLower) <> -1 Then
SkinPath = SkinPath.Remove(0, Len(Common.Globals.ApplicationPath))
End If
Response.Write("~" & SkinPath)
ctlSkin = CType(LoadControl("~" & SkinPath), DotNetNuke.UI.Skins.Skin)
' call databind so that any server logic in the skin is executed
ctlSkin.DataBind()
Catch exc As Exception
' could not load user control
Response.Write(exc.Message)
Response.Write("<br/>")
Response.Write(exc.InnerException)
Response.Write("<br/>")
Response.Write(exc.Source)
Response.Write("<br/>")
Response.Write(exc.StackTrace)
Response.Write("<br/>")
Response.End()
Dim lex As New PageLoadException("Unhandled error loading page.", exc)
If PortalSecurity.IsInRoles(PortalSettings.AdministratorRoleName) = True Or PortalSecurity.IsInRoles(PortalSettings.ActiveTab.AdministratorRoles.ToString) = True Then
' only display the error to administrators
SkinError.Text &= "<div style=""text-align:center"">Could Not Load Skin: " & SkinPath & " Error: " & Server.HtmlEncode(exc.Message) & "</div><br>"
SkinError.Visible = True
End If
LogException(lex)
Err.Clear()
End Try
'check for and read skin package level doctype
SetSkinDoctype(SkinPath)
Response.Write(ctlSkin.ID)
Response.End()
Return ctlSkin
End Function
--------------------------------------------------------------------------
--~/Portals/_default/Skins/MinimalExtropy/index.ascxThe file '/Admin/Skins/Language.ascx' does not exist.
System.Web.HttpParseException: The file '/Admin/Skins/Language.ascx' does not exist. ---> System.Web.HttpException: The file '/Admin/Skins/Language.ascx' does not exist. at System.Web.UI.Util.CheckVirtualFileExists(VirtualPath virtualPath) at System.Web.Compilation.BuildManager.GetVPathBuildResultInternal(VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile) at System.Web.Compilation.BuildManager.GetVPathBuildResultWithNoAssert(HttpContext context, VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile) at System.Web.Compilation.BuildManager.GetVPathBuildResult(HttpContext context, VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile) at System.Web.UI.BaseTemplateParser.GetReferencedType(VirtualPath virtualPath, Boolean allowNoCompile) at System.Web.UI.BaseTemplateParser.GetUserControlType(VirtualPath virtualPath) at System.Web.UI.MainTagNameToTypeMapper.ProcessUserControlRegistration(UserControlRegisterEntry ucRegisterEntry) at System.Web.UI.BaseTemplateParser.ProcessDirective(String directiveName, IDictionary directive) at System.Web.UI.TemplateControlParser.ProcessDirective(String directiveName, IDictionary directive) at System.Web.UI.TemplateParser.ParseStringInternal(String text, Encoding fileEncoding) --- End of inner exception stack trace --- at System.Web.UI.TemplateParser.ProcessException(Exception ex) at System.Web.UI.TemplateParser.ParseStringInternal(String text, Encoding fileEncoding) at System.Web.UI.TemplateParser.ParseString(String text, VirtualPath virtualPath, Encoding fileEncoding)
System.Web
at System.Web.UI.TemplateParser.ParseString(String text, VirtualPath virtualPath, Encoding fileEncoding) at System.Web.UI.TemplateParser.ParseReader(StreamReader reader, VirtualPath virtualPath) at System.Web.UI.TemplateParser.ParseFile(String physicalPath, VirtualPath virtualPath) at System.Web.UI.TemplateParser.ParseInternal() at System.Web.UI.TemplateParser.Parse() at System.Web.UI.TemplateParser.Parse(ICollection referencedAssemblies, VirtualPath virtualPath) at System.Web.Compilation.BaseTemplateBuildProvider.get_CodeCompilerType() at System.Web.Compilation.BuildProvider.GetCompilerTypeFromBuildProvider(BuildProvider buildProvider) at System.Web.Compilation.BuildProvidersCompiler.ProcessBuildProviders() at System.Web.Compilation.BuildProvidersCompiler.PerformBuild() at System.Web.Compilation.BuildManager.CompileWebFile(VirtualPath virtualPath) at System.Web.Compilation.BuildManager.GetVPathBuildResultInternal(VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile) at System.Web.Compilation.BuildManager.GetVPathBuildResultWithNoAssert(HttpContext context, VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile) at System.Web.Compilation.BuildManager.GetVPathBuildResult(HttpContext context, VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile) at System.Web.UI.TemplateControl.LoadControl(VirtualPath virtualPath) at System.Web.UI.TemplateControl.LoadControl(String virtualPath) at DotNetNuke.Framework.DefaultPage.LoadSkin(String SkinPath)