I'm having trouble with my ASP.NET application. Basically I've got it hooked up to an entity model representing a MySql database. I've launched applications before using this same database, and they deploy just fine, however when I run this application I'm getting the following error:
FIXED THIS ERROR
Now I'm receiving this error:
Exception Details: System.Data.MetadataException: Unable to load the specified metadata resource.
[MetadataException: Unable to load the specified metadata resource.]
System.Data.Metadata.Edm.MetadataArtifactLoaderCompositeResource.LoadResources(String assemblyName, String resourceName, ICollection`1 uriRegistry, MetadataArtifactAssemblyResolver resolver) +2490148
System.Data.Metadata.Edm.MetadataArtifactLoaderCompositeResource.CreateResourceLoader(String path, ExtensionCheck extensionCheck, String validExtension, ICollection`1 uriRegistry, MetadataArtifactAssemblyResolver resolver) +170
System.Data.Metadata.Edm.MetadataArtifactLoader.Create(String path, ExtensionCheck extensionCheck, String validExtension, ICollection`1 uriRegistry, MetadataArtifactAssemblyResolver resolver) +8517824
System.Data.Metadata.Edm.MetadataCache.SplitPaths(String paths) +271
System.Data.Common.Utils.<>c__DisplayClass2.<Evaluate>b__0() +19
System.Data.Common.Utils.Result.GetValue() +100
System.Data.Common.Utils.Memoizer`2.Evaluate(TArg arg) +181
System.Data.EntityClient.EntityConnection.GetMetadataWorkspace(Boolean initializeAllCollections) +292
System.Data.Objects.ObjectContext.RetrieveMetadataWorkspaceFromConnection() +29
System.Data.Objects.ObjectContext..ctor(EntityConnection connection, Boolean isConnectionConstructor) +205
System.Data.Objects.ObjectContext..ctor(String connectionString, String defaultContainerName) +27
AgentActivity.shoretelEntities..ctor() in c:\Projects\NET\AgentActivity\AgentActivity\ShoretelServer.Designer.cs:34
AgentActivity.ReturnFile.ReturnAgentActivity(String startDate, String endDate) in c:\Projects\NET\AgentActivity\AgentActivity\ReturnFile.aspx.cs:271
AgentActivity.ReturnFile.Page_Load(Object sender, EventArgs e) in c:\Projects\NET\AgentActivity\AgentActivity\ReturnFile.aspx.cs:44
System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +14
System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +35
System.Web.UI.Control.OnLoad(EventArgs e) +91
System.Web.UI.Control.LoadRecursive() +74
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2207
Any ideas? I'm at a loss on this one, I don't even where to begin
It seems that the MySQL connector has not been deployed.
Have you verified if the MySQL connector is available on your server?
Checkout this post: Deploy MySQL data provider to Production
Related
The .NET project that works is on .NET framework 4.6.1. The one that does not work is on .NET framework 4.7.2.
This is the Function:
return DAL.DALGeneral.SelectScalar("GetYearName", new Dictionary<string, object>() { { "Year", year } }).ToString();
This is the Error message:
[NullReferenceException: Object reference not set to an instance of an object.]
DAL.DALGeneral.GetConnectionString(String DataBase) +83
DAL.DALGeneral.SelectScalar(String spName, Dictionary`2 parameters, String DataBase, String ConnectionString) +123
OnlineYudGimelDaledSignIn.Models.LookUp.GetYearName(Int32 year) in C:\Users\giln\source\repos\OnlineYudGimelDaledSignIn\OnlineYudGimelDaledSignIn\Models\LookUp.cs:58
OnlineYudGimelDaledSignIn.Site.Page_Load(Object sender, EventArgs e) in C:\Users\giln\source\repos\OnlineYudGimelDaledSignIn\OnlineYudGimelDaledSignIn\Site.Master.cs:29
System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +52
System.Web.UI.Control.OnLoad(EventArgs e) +97
System.Web.UI.Control.LoadRecursive() +61
System.Web.UI.Control.LoadRecursive() +134
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +693
Im stumped as to why, the same function with the same arguments works from an other project.
I tried sending different arguments to the function and i get different error, but i need it to be these arguments.
Ok, so i had a missing connection string in the web.config file in the second project. I didn't realize dll reference uses the current project config file, and not his own somehow.
I have already publish my web application but i am facing an error i tried a lot to fix it and i search a lot on web but i couldnt fix it, so please could you help me to fix this issue.
<connectionStrings>
<add name="BeravaConnectionString"
connectionString="Data Source=156.74.335.445; User ID=varooo; database = betop; Password:Sdvavava"
providerName="System.Data.SqlClient" />
Server Error in '/' Application.
Format of the initialization string does not conform to specification
starting at index 118.
Description: An unhandled exception occurred during the execution of
the current web request. Please review the stack trace for more
information about the error and where it originated in the code.
Exception Details: System.ArgumentException: Format of the
initialization string does not conform to specification starting at
index 118.
Source Error:
An unhandled exception was generated during the execution of the
current web request. Information regarding the origin and location of
the exception can be identified using the exception stack trace below.
Stack Trace:
[ArgumentException: Format of the initialization string does not
conform to specification starting at index 118.]
System.Data.Common.DbConnectionOptions.GetKeyValuePair(String
connectionString, Int32 currentPosition, StringBuilder buffer, Boolean
useOdbcRules, String& keyname, String& keyvalue) +5360365
System.Data.Common.DbConnectionOptions.ParseInternal(Hashtable
parsetable, String connectionString, Boolean buildChain, Hashtable
synonyms, Boolean firstKey) +124
System.Data.Common.DbConnectionOptions..ctor(String connectionString,
Hashtable synonyms, Boolean useOdbcRules) +95
System.Data.SqlClient.SqlConnectionString..ctor(String
connectionString) +59
System.Data.SqlClient.SqlConnectionFactory.CreateConnectionOptions(String
connectionString, DbConnectionOptions previous) +24
System.Data.ProviderBase.DbConnectionFactory.GetConnectionPoolGroup(DbConnectionPoolKey
key, DbConnectionPoolGroupOptions poolOptions, DbConnectionOptions&
userConnectionOptions) +167
System.Data.SqlClient.SqlConnection.ConnectionString_Set(DbConnectionPoolKey
key) +61
System.Data.SqlClient.SqlConnection.set_ConnectionString(String value)
+66 System.Data.SqlClient.SqlConnection..ctor(String connectionString, SqlCredential credential) +26
System.Data.SqlClient.SqlConnection..ctor(String connectionString) +6
beravoSV.Berava.Page_Load(Object sender, EventArgs e) +311
System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender,
EventArgs e) +51 System.Web.UI.Control.OnLoad(EventArgs e) +92
System.Web.UI.Control.LoadRecursive() +54
System.Web.UI.Page.ProcessRequestMain(Boolean
includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
+772
I believe it should be Password=Sdvavava, instead of Password:Sdvavava. Use an equals sign instead of a colon, like the other parameters.
I my share point site I have one List named "People List" and one Wiki Page Library named "People". I have created one visual webpart to display data from People list. I have created webpart property to read listname.The webpart property name for my visual webpart is "People". When I check whether list exists in my site using the following function it returns true:-
public static bool isListExists(SPWeb spWeb, string listName)
{
return spWeb.Lists.TryGetList(listName) != null;
}
But there is no List named "People" exists in my site. Only wiki page library named "People" exists. When I added my webpart in "MySite/People/default.aspx" page I got error.
Column 'Title' does not exist. It may have been deleted by another user.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.ArgumentException: Column 'Title' does not exist. It may have been deleted by another user.
Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
Stack Trace:
[ArgumentException: Column 'Title' does not exist. It may have been deleted by another user.]
Microsoft.SharePoint.SPFieldCollection.GetField(String strName, Boolean bThrowException) +26422968
Microsoft.SharePoint.SPListItem.GetValue(String strName, Boolean bThrowException) +47
Microsoft.SharePoint.SPListItem.get_Item(String fieldName) +12
CL.DanceStudio.Portal.CLDance_Instructor.<>c__DisplayClass3.<Select>b__1() +1155
Microsoft.SharePoint.<>c__DisplayClass4.<RunWithElevatedPrivileges>b__2() +729
Microsoft.SharePoint.Utilities.SecurityContext.RunAsProcess(CodeToRunElevated secureCode) +27491206
Microsoft.SharePoint.SPSecurity.RunWithElevatedPrivileges(WaitCallback secureCode, Object param) +27194345
Microsoft.SharePoint.SPSecurity.RunWithElevatedPrivileges(CodeToRunElevated secureCode) +93
CL.DanceStudio.Portal.CLDance_Instructor.CLDance_InstructorUserControl.Select() +291
CL.DanceStudio.Portal.CLDance_Instructor.CLDance_InstructorUserControl.Page_Load(Object sender, EventArgs e) +52
System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +25
System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +42
System.Web.UI.Control.OnLoad(EventArgs e) +132
System.Web.UI.Control.LoadRecursive() +66
System.Web.UI.Control.AddedControl(Control control, Int32 index) +350
CL.DanceStudio.Portal.CLDance_Instructor.CLDance_Instructor.CreateChildControls() +194
System.Web.UI.Control.EnsureChildControls() +146
System.Web.UI.Control.PreRenderRecursiveInternal() +61
System.Web.UI.Control.PreRenderRecursiveInternal() +224
System.Web.UI.Control.PreRenderRecursiveInternal() +224
System.Web.UI.Control.PreRenderRecursiveInternal() +224
System.Web.UI.Control.PreRenderRecursiveInternal() +224
System.Web.UI.Control.PreRenderRecursiveInternal() +224
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +3394
I think it is due to name conflict. Please provide me a solution.
So I get this exception from Telerik's RadGrid when using a custom DataSource but I have no idea what I am doing wrong. Any clues?
Server Error in '/' Application.
Object reference not set to an instance of an object.
Description:
An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details:
System.NullReferenceException: Object reference not set to an instance
of an object.
Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
Stack Trace:
[NullReferenceException: Object reference not set to an instance of an object.]
Telerik.Web.UI.GridResolveEnumerable.GetCollectionItemType(Boolean noItemsInEnumerator, Type& collectionItemType, Object& collectionFirstObject) +101
Telerik.Web.UI.GridResolveEnumerable.ParseProperties() +264
Telerik.Web.UI.GridResolveEnumerable.Initialize() +29
Telerik.Web.UI.GridResolveEnumerable.EnsureInitialized() +45
Telerik.Web.UI.GridResolveEnumerable.get_DataTable() +36
Telerik.Web.UI.GridEnumerableFromDataView..ctor(GridTableView owner, IEnumerable enumerable, Boolean CaseSensitive, Boolean autoGenerateColumns, GridColumnCollection presentColumns, String[] additionalField, Boolean retrieveAllFields, Boolean enableSplitHeaderText) +245
Telerik.Web.UI.GridDataSourceHelper.CreateGridEnumerable(GridTableView owner, IEnumerable enumerable, Boolean caseSensitive, Boolean autoGenerateColumns, GridColumnCollection presentColumns, String[] additionalField, Boolean retrieveAllFields, Boolean enableSplitHeaderText) +172
Telerik.Web.UI.GridDataSourceHelper.GetResolvedDataSource(GridTableView owner, Object dataSource, String dataMember, Boolean caseSensitive, Boolean autoGenerateColumns, GridColumnCollection presentColumns, String[] additionalField, Boolean retrieveAllFields, Boolean enableSplitHeaderText) +322
Telerik.Web.UI.GridTableView.get_ResolvedDataSource() +257
Telerik.Web.UI.GridTableView.CreateChildControls(IEnumerable dataSource, Boolean useDataSource) +480
System.Web.UI.WebControls.CompositeDataBoundControl.PerformDataBinding(IEnumerable data) +67
System.Web.UI.WebControls.DataBoundControl.OnDataSourceViewSelectCallback(IEnumerable data) +123
System.Web.UI.DataSourceView.Select(DataSourceSelectArguments arguments, DataSourceViewSelectCallback callback) +33
System.Web.UI.WebControls.DataBoundControl.PerformSelect() +138
Telerik.Web.UI.GridTableView.PerformSelect() +38
System.Web.UI.WebControls.BaseDataBoundControl.DataBind() +30
Telerik.Web.UI.GridTableView.DataBind() +391
Telerik.Web.UI.RadGrid.DataBind() +191
Telerik.Web.UI.RadGrid.AutoDataBind(GridRebindReason rebindReason) +4251
Telerik.Web.UI.RadGrid.OnLoad(EventArgs e) +201
System.Web.UI.Control.LoadRecursive() +54
System.Web.UI.Control.LoadRecursive() +145
System.Web.UI.Control.LoadRecursive() +145
System.Web.UI.Control.LoadRecursive() +145
System.Web.UI.Control.LoadRecursive() +145
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +772
Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.17929
This error is happening due to some kind of (probably accidental) recursion. I'd suggest the following:
Look for something that triggers a redraw in your redraw code.
Look at your call stack when it fails and see where it is entering this endless recursion.
I'm only partially able to get Lucene .NET to work on GoDaddy. It throws a security exception on this line:
Hits hits = searcher.Search(query, filter);
Here are the details of this exception:
Description: The application attempted to perform an operation not allowed by the security policy. To grant this application the required permission please contact your system administrator or change the application's trust level in the configuration file.
Exception Details: System.Security.SecurityException: Request for the permission of type 'System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed.
[SecurityException: Request for the permission of type 'System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed.]
WeakHashTable.set_Item(Object key, Object value) in SupportClass.cs:1231
Lucene.Net.Search.CachingWrapperFilter.Bits(IndexReader reader) in CachingWrapperFilter.cs:69
Lucene.Net.Search.IndexSearcher.Search(Weight weight, Filter filter, HitCollector results) in IndexSearcher.cs:175
Lucene.Net.Search.IndexSearcher.Search(Weight weight, Filter filter, Int32 nDocs) in IndexSearcher.cs:156
Lucene.Net.Search.Hits.GetMoreDocs(Int32 min) in Hits.cs:104
Lucene.Net.Search.Hits..ctor(Searcher s, Query q, Filter f) in Hits.cs:67
Lucene.Net.Search.Searcher.Search(Query query, Filter filter) in Searcher.cs:57
details.RetrieveDocument() in d:\hosting\5304481\html\details.aspx.cs:42
details.Page_Load(Object sender, EventArgs e) in d:\hosting\5304481\html\details.aspx.cs:28
System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +14
System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +35
System.Web.UI.Control.OnLoad(EventArgs e) +99
System.Web.UI.Control.LoadRecursive() +50
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +6785
System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +242
System.Web.UI.Page.ProcessRequest() +80
System.Web.UI.Page.ProcessRequestWithNoAssert(HttpContext context) +21
System.Web.UI.Page.ProcessRequest(HttpContext context) +49
ASP.details_aspx.ProcessRequest(HttpContext context) in App_Web_pux0zsik.0.cs:0
System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +181
System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +75
Before I give up on GoDaddy and move to DiscountASP, I wanted to check if anyone would know how I can tweak the code to operate fully in a Medium Trust environment.
Thanks.
I have answered a different question on getting Lucene.Net to work in medium trust. This is on newer versions of the library.
Lucene.NET in medium trust