Windows error 0x80131501, -2146233087

Detailed Error Information

COR_E_SYSTEM[1]

Message"System.Exception"
Comment The base class for the runtime's "less serious" exceptions

HRESULT analysis[2]

FlagsSeverityFailure
Reserved (R)false
OriginMicrosoft
NTSTATUSfalse
Reserved (X)false
FacilityCode19 (0x013)
NameFACILITY_URT[2][3]
DescriptionThe source of the error code is .NET CLR.[2][3]
Error Code5377 (0x1501)

Questions

6votes
0answers

Why does Blend/Visual Studio always generate ResourceDictionary "Source" Incorrectly?

BRIEF I'm starting to go crazy. I've been chasing this issue for about a day now and I can't figure out how to easily resolve it. So I figured I'd drive you all crazy with this too (hopefully you have better luck than me). Note: A link to a zipped [...] read more
c#
xaml
visual-studio-2017
resourcedictionary
blend
5votes
4answers

Debugging Visual Studio 2017 Extension Does Not Find Assembly

I'm trying to update my Diff All Files Visual Studio extension to support VS 2017. When debugging my extension it is complaining that it cannot find a required assembly: System.Windows.Markup.XamlParseException occurred HResult=0x80131501 Message=Could not load file or assembly 'QuickConverter, PublicKeyToken=9c892aa7bc2af2cf' or one of its dependencies. The system cannot find the [...] read more
.net
visual-studio
visual-studio-2017
assemblybinding
4votes
1answer

Dapper problem with a nullable Guid? types

I have problem with Dapper and Guid? type. I created that demo project: Database MySQL (table entities): CREATE TABLE `entities` ( `id` int NOT NULL AUTO_INCREMENT, `notnullguid` char(36) NOT NULL, `nullguid` char(36) DEFAULT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci; First Guid field - not null, second [...] read more
c#
.net
dapper
4votes
2answers

IDX10632: SymmetricSecurityKey.GetKeyedHashAlgorithm( 'HS512' ) threw an exception when validating JWT using HS512 ALGO

I'm using the NuGet package System.IdentityModel.Tokens.Jwt version 4.0.4.403061554. I have an implementation that validates a JWT and it works fine for algo HS256. However if I change my JWT to be generated using algo HS512 then I receive an error during validation. System.IdentityModel.SignatureVerificationFailedException HResult=0x80131501 Message=IDX10503: Signature validation failed. Keys tried: [...] read more
c#
security
encoding
jwt
identity
3votes
1answer

How to resolve the Dapper System.Data.DataException HResult=0x80131501 InvalidCastException Invalid cast from 'System.String' to 'System.Uri'

Recently, I refactored some code which resulted in changing the type of some properties of an entity from System.String to System.URI. The names of the properties in question contained the substring URI or URL and the SonarLint static code analyzer was recommending that the code be refactored to use the [...] read more
c#
.net
dapper
3votes
1answer

Problem when serializing and de-serializing RichTextBox in WPF

I have an experimental WPF probject like Microsoft Word. The main component is RichTextBox. Users can edit the content and save it to somewhere. The below methods are used in serializing and deserializing the content to/from a remote database. public static byte[] FlowDocumentSerializingV2WithXamlWriter(FlowDocument flowDocument) { using(MemoryStream buffer = new MemoryStream()) [...] read more
c#
wpf
serialization
3votes
1answer

Getting error in Entity Framework when trying to add an item

I'm getting the below error when trying to add an item to the database context. I'm using Entity Framework in a Web API project. The sample code is shown below. Exception > System.Data.Entity.Infrastructure.DbUpdateException > HResult=0x80131501 Message=An error occurred while updating the entries. See > the inner exception for details. Source=EntityFramework [...] read more
c#
entity-framework
asp.net-web-api
entity-framework-6
asp.net-web-api2
3votes
2answers

Exclude an array in a LINQ expression that connects to CRM

I am trying to run a LINQ query that gets all objects of a specific type [new_contact], but filters out those with a specific field value [new_identifier] that matches in a list [excludeIdentifiers]. public static List<new_placement>ActivityCounter(Account account, CRM2011DataContext CRMcontext) { int[] excludedIdentifiers = { 6, 7, 8, 9, 13, 14, [...] read more
c#
linq
visual-studio-2017
dynamics-crm-2016
2votes
1answer

Property InvalidDataException on instantiation

I'm using the Rustici Scorm Cloud API to generate a URL to preview some learning material: * API docs: buildCoursePreviewLaunchLink * NuGet package: 1.0.0 The code creates a LaunchLinkRequestSchema object with the string field RedirectOnExitUrl populated. However, I get an InvalidDataException at the point of instantiation: CODE var l = [...] read more
c#
instantiation
scorm-cloud-api
2votes
1answer

Dapper failing to read SQL uniqueidentifier type to string

I have the following class: public class User { public string Id { get; set; } public string UserName { get; set; } public string DisplayName { get; set; } public DateTime RegistrationDateTime { get; set; } public DateTime LastLoginDateTime { get; set; } public bool IsAdmin { get; set; [...] read more
c#
sql-server
dapper
2votes
0answers

.NET WCF not working in VM

As the question title states, my WCF communications do not work when running in a VM environment. The VM is Windows 7 x64 same as the host system. I have a .Net service running with a .Net windows form client that attempts to connect to the service. On the physical [...] read more
c#
.net
vb.net
wcf
1vote
2answers

WPF: InvalidCastException: Unable to cast object of type 'System.Windows.Style' to type 'System.Windows.ResourceDictionary'

I try to re-style TextBoxes in my Control to have the same look for ReadOnly as if they were Disabled. Last week I could achieve this without any problem like this: <UserControl.Resources> <Style TargetType="{x:Type Border}" x:Key="TextBoxBorderStyle"> <Style.Triggers> <DataTrigger Binding="{Binding IsReadOnly, RelativeSource={RelativeSource Mode=FindAncestor, AncestorType=TextBoxBase}}" Value="True"> <Setter Property="Opacity" Value="0.56"/> </DataTrigger> </Style.Triggers> </Style> [...] read more
c#
wpf
windows
xaml
exception
1vote
0answers

Visual Studio Installer fails to run

Visual Studio installer will not run. First was trying to install additional feature from Visual Studio. Then running the visual studio installer from start menu. Then deleting the installer directory and trying to run it from a fresh VS online installer. Here is the error message from the log Error [...] read more
visual-studio
1vote
2answers

Problem with HTTPs request and SslStream on some sites

I have a simple C# app that makes a HTTPs request using TcpClient and SslStream. Everything works fine, except some websites that use TLS 1.3 are failing. I upgraded project to .Net Framework 4.8, also read slowly https://docs.microsoft.com/es-es/dotnet/framework/network-programming/tls but i can't achieve a solution. I'm using Windows 10 64bit compilation [...] read more
c#
ssl
sslstream
tls1.3
1vote
1answer

C# Dapper SQL Server Connection Error : Dapper Connect to anther database not exist in connection string

I am using Dapper to connect to the SQL server database My database was SeasonDB, I created anther database called SeasonDb2 to test modifications it was working well until I removed SeasonDb2 from the SQL server and change the Connection string to SeasonDB get Connection String from config file <connectionStrings> [...] read more
c#
sql-server
dapper
1vote
1answer

How to catch exception when database connection is lost when using EF?

I'm using ADO.NET Entity Data Model EF Designer from the database. My SQL server is on another PC and when I lost connection with the database my app stops and I can only shut it down. I get: System.Data.Entity.Core.EntityException HResult=0x80131501 Message=The underlying provider failed on Open. Source=EntityFramework Inner Exception 1: [...] read more
c#
.net
entity-framework
database-connection
1vote
0answers

Servicestack service fail to use HttpClient

I have REST API service using Servicetack.Service in ServiceStack.AppHost. One of my web services is calling other 3rd party's web service. When it call the 3rd party using HttpClient I get this exception: System.Security.Authentication.AuthenticationException HResult=0x80131501 Message=A call to SSPI failed, Inner Exceptin: Win32Exception: The message received was unexpected or badly [...] read more
c#
httpclient
servicestack
1vote
2answers

Entity Framework DB Update

Exception: HResult=0x80131501 Message=An error occurred while updating the entries. See the inner exception for details. Source=EntityFramework StackTrace: at System.Data.Entity.Internal.InternalContext.SaveChanges() at System.Data.Entity.Internal.LazyInternalContext.SaveChanges() at System.Data.Entity.DbContext.SaveChanges() at SQDCDashboard.Services.Services.WindowsOrderImporterService.ImportOrder(DateTime date) in C:\Users\ME\source\repos\SQDC Dashboard\SQDCDashboard\SQDCDashboard.Services\Services\WindowsOrderImporterService.cs:line 145 at SQDCDashboardOrderImporterTester.Program.Main(String[] args) in C:\Users\ME\source\repos\SQDC Dashboard\SQDCDashboard\SQDCDashboardOrderImporterTester\Program.cs:line 11 Inner Exception 1: UpdateException: An error occurred while updating the entries. See the [...] read more
c#
asp.net-mvc
entity-framework
1vote
1answer

How to Access Dapper Results When Using Dynamic Due to Enum

I have a Dapper DB call that has a column that maps to an enum on the type. From what I understand, I have to query using dynamic because the query can't map to my Request type since Status is an enum on it. So I tried using this: public [...] read more
c#
dynamic
dapper
1vote
0answers

WPF App (.NET Core) clr-namespace reference to Class Library (.NET Core) Could not load file or assembly

I have a solution with two projects created in Visual Studio Community 2019 version 16.4.2. The first project is View.csproj, a .NET Core 3.1 WPF app. The second project is ViewModel.csproj, a .NET Core 3.1 Class Library. When I run the code below, I get the following runtime error. What [...] read more
c#
wpf
xaml
.net-core
1vote
0answers

Can I get some help in utilizing the ReportExecutionService to execute my SSRS script

Here is my console app code: private static void CreateSSRSPDF() { string FullFilePath = "C:\\NewIbidReport"; ReportExecutionService rs = new ReportExecutionService(); string format = "PDF"; string reportPath = "http://bushssrs02dev/ReportServer/Sam%20"+"-"+"%20Student%20Reports/IBid%20Audit%20Analysis.rdl"; string mimeType = "application/pdf"; ParameterValue[] parameters = new ParameterValue[1]; parameters[0] = new ParameterValue(); parameters[0].Name = "StudentStatus"; parameters[0].Value = "Active"; byte[] results = [...] read more
c#
reporting-services
1vote
1answer

Trouble Accessing Azure WCF relay Getting "The endpoint was not found. Endpoint does not exist." Error

I have been trying to use Azure WCF relay with two ASP applications as Given in the link https://docs.microsoft.com/en-us/azure/service-bus-relay/service-bus-dotnet-hybrid-app-using-service-bus-relay the example explains to create a console server and MVC Client application to connect using azure service bus relay. I created RootManageSharedAccessKey as mentioned and Given primary key to both of [...] read more
c#
azure
azure-relay
1vote
1answer

Calling F# function with a button from WPF (FsXaml approach)

I'm trying to make a Button Hello World application with F#, WPF and FsXaml. I started following this guide: https://www.c-sharpcorner.com/article/create-wpf-application-with-f-sharp-and-fsxaml/ Everything works fine when I just load things on xaml and compile, but I haven't managed to call a function by pressing a button and the guide ends before he [...] read more
wpf
f#
fsxaml
1vote
1answer

Cannot successfully iterate through AccountManagement.GroupPrincipal GetMembers Object

I am using System.DirectoryServices.AccountManagement.GroupPrincipal FindByIdentity in C# to create an object containing the group members (user IDs and names) for the target group. My goal is to iterate through the resulting list of UserPrincipals and print the SamAccountName and DisplayName for each. For some target groups, this is working fine; [...] read more
c#
active-directory
1vote
1answer

CommunicationException: An error occurred on client side while making the HTTP request (HTTP.SYS) to third-party WebService

I'm from Brazil and our government released a WebService meant to inform employees' payroll that's called eSocial. I'm developing a solution to communicate with this service for about a year now and I found this error in some customers' machines while trying to send information to the government WebService: > [...] read more
c#
wcf
1vote
1answer

Binding to a data source from two different views. MVVM, WPF

So here is the setup. I have two different WPF views. StandardEngineeredView and StandardEngineeredPrintView. I have an ObservableCollection called ModelRevisionList in my StandardEngineeredViewModel. What I am doing is trying to bind to the ModelRevisionList data source from two different views. I have the data context of my views set to [...] read more
c#
wpf
mvvm
binding
mvvm-light
1vote
1answer

MySQL and C# Entity Framework "ProviderIncompatibleException"

i'm following the MySql tutorial to entity framework as listed here: https://dev.mysql.com/doc/connector-net/en/connector-net-entityframework60.html I have installed in my project via NuGet: - Entity Framework v6.2.0 - MySql.Data.Entity v6.10.7 And their corresponding dependencies. I have installed the MySql CONNECTOR/NET v8.0.11. I added the provider and connectionString to the App.config: <entityFramework codeConfigurationType="MySql.Data.Entity.MySqlEFConfiguration, MySql.Data.Entity.EF6"> [...] read more
c#
mysql
entity-framework
entity-framework-6
1vote
2answers

SSIS package fails and then runs successfully 15 minutes later

I have an SSIS package that is scheduled to run every weekday morning at 8:15. It copies data to and from Active Directory and SQL. About two weeks ago, it started failing, with no changes having been made to the server (beyond MS updates). The funny thing is that if [...] read more
sql
ssis
active-directory
1vote
0answers

how to set focus programatically to a specific property item in xceed propertygrid

The closest solution posted was for a Mindscape propertygrid, so does not exactly translate. http://www.mindscapehq.com/forums/thread/1222 It uses an attached property. I am stuck on how to implement the attached property. I get this error in the XAML designer and when I try to run the app. System.Windows.Markup.XamlParseException HResult=0x80131501 Message=The type [...] read more
wpf
focus
propertygrid
xceed
1vote
2answers

WCF error - Can't get service endpoint up

I started working with WCF recently, and I'm having a problem that I just don't have a clue how to solve. I start a WCF Service using Service Host, but when I use the URI in a browser it doesn't show the contract of the service, and it gives an [...] read more
c#
web-services
wcf
1vote
1answer

Load style library into WPF

LONG QUESTION: I downloaded a style library (Selen.Wpf) via NuGet. Now I want to use its styles. Frankly, this little task drove me crazy by now. First approach - Using MergedDictionarys: Ideally I would add the styles as follows <Application.Resources> <ResourceDictionary> <ResourceDictionary.MergedDictionaries> <ResourceDictionary> <BitmapImage x:Key="ImgHelp" UriSource="pack://application:,,,/Resources/Help_32x.png"/> <!--Lots of our own [...] read more
c#
wpf
xaml
0votes
0answers

Entity connection string in Asp.net MVC

<connectionStrings> <add name="DefaultConnection" connectionString="Data Source=(LocalDb)\MSSQLLocalDB;Initial Catalog=aspnet-OnlineShoppingStore-20181119035803;Integrated Security=Ture; AttachDbFilename=|DataDirectory|\aspnet-OnlineShoppingStore-20181119035803.mdf" providerName="System.Data.SqlClient" /> <add name="dbMyOnlineShoppingEntities" connectionString="metadata=res://*/DAL.Model1.csdl|res://*/DAL.Model1.ssdl|res://*/DAL.Model1.msl;provider=System.Data.SqlClient;provider connection string=&quot;data source=.;initial catalog=dbMyOnlineShopping;integrated security=True;MultipleActiveResultSets=True;App=EntityFramework&quot;" providerName="System.Data.EntityClient" /> </connectionStrings> Throwing Exceptions System.Data.Entity.Core.EntityException HResult=0x80131501 Message=The underlying provider failed on Open. Source=<Cannot evaluate the exception source> StackTrace: <Cannot evaluate the exception stack trace> Inner Exception 1: SqlException: A network-related or [...] read more
c#
sql-server
asp.net-mvc
0votes
1answer

Can I run the SSIS Transfer Database Task as member of db_owner role?

I'm attempting to transfer a database (online mode) from server A to server B, using a SSIS package running on server C. The SSIS package access server A with a SQL Server login, which is a member of the db_owner role in the database to be transferred. When I verify [...] read more
sql-server
ssis
permissions
0votes
1answer

WPF ComboBox Item Template Not Found

I'm trying to create a combo box with a custom data template but there will be several combo boxes that use the same template so I would like to make it a resource. It wasn't working so I created a simple test project to test this and sure enough I [...] read more
c#
wpf
combobox
datatemplate
0votes
1answer

WCF transportWithMessageCredential

My experience with WCF is minimal so I'm sure I'm doing something wrong. But after hours of research I'm either not asking the right questions or I'm just old fashion stuck. I have a windows form application (VB) with a service reference to a WCF WSDL that according to the [...] read more
vb.net
wcf
wcf-binding
wcf-security
0votes
1answer

How to run a powershell command in c#

So I am attempting to change the creation date of a text file in C#. The user will type in thr creation date of the file, it will then change the text files creation date to what the user inputted. Trouble is it keeps adding a ' for some reason [...] read more
c#
string
visual-studio
powershell
0votes
1answer

C#, WPF - Items of ListView wont show when using ControlTemplate and Binding

I'm trying to add Objects of a own-builded class to ListView with GridView in it. The DataBinding is working without any problems and the Items are displayed well and in the correct way. This is the StyleTemplate of the ListView: <Style x:Key="Orig_FileViewTemplate" TargetType="ListView"> <Setter Property="VerticalAlignment" Value="Stretch"></Setter> <Setter Property="HorizontalAlignment" Value="Stretch"></Setter> </Style> [...] read more
c#
wpf
listview
templates
binding
0votes
0answers

An EdmType cannot be mapped to CLR classes multiple times. The EdmType is mapped more than once

I have a solution with 8 entity models and 5 projects, when I recompile the solution xaml crashes giving me "An item with the same key has already been added." I was able to debug my xaml and it appears to be entity framework related. The CreateObjectSet fails on several [...] read more
c#
entity-framework
0votes
1answer

Processing an uploaded Zip File in Azure Blob Storage

I have an Azure function that gets triggered when a blob gets uploaded to a certain directory. It processes a zip file. When I upload the file to the container with the Azure storage explorer, it works perfectly. When I upload it through web API, it blows up. If I [...] read more
c#
azure
azure-storage-blobs
0votes
1answer

Assembly dependencies issue

Situation: I have tree projects (ZShared, ZSearcher and ZClient) where they will be referenced in each other. ZShared is a common DLL assembly containing some styles and resources. ZSearcher is also a DLL assembly with some WPF controls. ZClient in theory can be anything (WPF app, Winforms, Excel etc.) for [...] read more
c#
wpf
dll
.net-assembly
0votes
2answers

Principal Error in AD when user is in group?

I have the following code, which works fine, as long as the user isn't in defined group (groupName) all values are defined in this function or somewhere else and are implemented correctly, the values are correct in this function: public void AddUserToGroup(string userId, string groupName) { string ss = Password(); [...] read more
c#
active-directory
userprincipal
0votes
1answer

How to style my combobox as the Office 2016 Telerik version?

I have this combo box xaml code: <ComboBox Width="250" Height="25" Foreground="#545454" ItemsSource="{StaticResource ParametersArray}"> <Style TargetType="{x:Type ComboBox}"> <Setter Property="Template"> <Setter.Value> <ControlTemplate TargetType="{x:Type ComboBox}"> <ControlTemplate.Triggers> <Trigger Property="IsMouseOver" Value="true"> <Setter Property="Background" Value="Blue" /> </Trigger> <Trigger Property="IsMouseOver" Value="false"> <Setter Property="Background" Value="Red" /> </Trigger> </ControlTemplate.Triggers> </ControlTemplate> </Setter.Value> </Setter> </Style> <ComboBox.ItemContainerStyle> <Style TargetType="{x:Type ComboBoxItem}"> <Setter Property="Template"> [...] read more
wpf
xaml
combobox
0votes
2answers

System.Windows.Markup.XamlParseException. I encountered this exception below, while trying to compile an XAML code

> Please can someone be of help. I encountered this exception below, while > trying to compile an XAML code > > System.Windows.Markup.XamlParseException HResult=0x80131501 Message='Provide > value on 'System.Windows.Baml2006.TypeConverterMarkupExtension' threw an > exception.' Line number '40' and line position '22'. > Source=PresentationFramework StackTrace: at > System.Windows.Markup.XamlReader.RewrapException(Exception e, IXamlLineInfo > lineInfo, [...] read more
c#
xaml
0votes
1answer

Unable to Bind Window Title to MVVM Data Context

I have a Net Framework 4.7.2. Application that I'm writing in WPF/C#. I'm trying to bind the Main Windows' Title to a property on its Data Context, PartyName, but I keep getting an error at runtime. Here's the XAML for the window: <Window x:Class="MyDM.View.Windows.MainWindow" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:vm="clr-namespace:MyDM.ViewModel" xmlns:ctrl="clr-namespace:MyDM.View.Controls" Height="778" Width="459" [...] read more
c#
wpf
data-binding
0votes
1answer

Conversion overflows in saving decimal entity framework 6

I have a decimal property in Product entity: public class Product { public Guid Id { get; set; } public decimal Price { get; set; } } I want to config precision in model mapping: class Context : DbContext { public DbSet<Product> Products { get; set; } public Context() : [...] read more
c#
entity-framework
decimal
0votes
0answers

Why do I get errors when trying to connect to localhost?

I am working on a project that needs to connect to a node.js server running express.js that is running on my computer. I run the following code: HttpWebRequest myRequest; WebResponse myResponse; StreamReader sr; myRequest = (HttpWebRequest)WebRequest.Create("https://localhost:1337/Test.txt"); myRequest.Method = "GET"; myResponse = myRequest.GetResponse(); sr = new StreamReader(myResponse.GetResponseStream(), Encoding.UTF8); sr.Close(); myResponse.Close(); and [...] read more
c#
httpwebrequest
0votes
1answer

How to use Acumatica Contract API to change stock item ID

I'd like to use the contract API to change the Inventory ID on items. It seems like I should be able to do this, but I think I'm missing how I send the new InventoryID to the invoked method. I'm using a web service endpoint with the ChangeID method added. [...] read more
acumatica
0votes
0answers

Why is my SSRS ReportExecutionService not recognizing my set parameter Values

Here is my code set up using the ReportExecutionService ReportExecutionService rs = new ReportExecutionService(); string format = "PDF"; string reportPath = "/Sam - Faculty and Course Reports/Class List Report (Phase)"; string mimeType = "application/pdf"; ParameterValue[] parameters = new ParameterValue[3]; parameters[0] = new ParameterValue(); parameters[0].Label = "QuarterYear"; parameters[0].Name = "QuarterYear"; parameters[0].Value [...] read more
c#
reporting-services
0votes
2answers

System.ServiceModel.EndpointNotFoundException: There was no endpoint listening

I have a new WPF project in Visual Studio. I want to connect to this url: "http://www.oorsprong.org/websamples.countryinfo/CountryInfoService.wso?WSDL". I have made a Service Reference. When I run it, I get this error (I have translated the text to English): System.ServiceModel.EndpointNotFoundException HResult=0x80131501 Message=There was no endpoint listening at http://www.oorsprong.org/websamples.countryinfo/CountryInfoService.wso, that can accept [...] read more
c#
wcf
service-reference
0votes
1answer

How to switch a column header style with another dynamically when they're used indirectly, inherited using BasedOn in each column

I have a DataGrid. I wish to style it, allowing the user to select a theme from a set of themes (initially Light and Dark). With my knowledge I can do this only for a single theme. I thought about using the DataGridColumnHeader style in Resources using it through DynamicResource [...] read more
c#
wpf
xaml
datagrid
wpf-style
0votes
1answer

An unsecured or incorrectly secured fault was received from the other party. See the inner FaultException for the fault code and detail

When I try to execute a CRM CRUD operation using a Console App, I'm getting the following error: > System.ServiceModel.Security.MessageSecurityException HResult=0x80131501 > Message=An unsecured or incorrectly secured fault was received from the other > party. See the inner FaultException for the fault code and detail. > Source=mscorlib class Program { [...] read more
dynamics-crm
dynamics-365
0votes
1answer

D365 - Get solution list which contains specific string in 'uniquename'

I want to get list of list of solution displayed in DropDown in windows application. So, to get the list of solutions I have written below QueryExpression and added a filter for the same: public EntityCollection GetSolutions(IOrganizationService service, string solutionUniqueNameLike) { QueryExpression querySampleSolution = new QueryExpression { EntityName = "solution", [...] read more
dynamics-crm
microsoft-dynamics
query-expressions
0votes
1answer

Primary key already exists when saving new record using EF6

I have been using this logic for a month and it has stopped working recently. var tool = new Tool() { ToolNumber = toolNumber.Trim(), Description = description.Trim() }; context.AddToTools(tool); context.SaveChanges(); AddToTools just looks like this: public void AddToTools(Tool tool) { base.AddObject("Tools", tool); } I get the error on context.SaveChanges(); > [...] read more
c#
entity-framework-6
0votes
0answers

Having problems debugging and building a WPF app

I've been making modifications to a WPF app we wrote a few years ago using the ModernUI framework, adding a Shared Project, making the necessary changes. However, I've found that I can neither debug the app, nor build it. When I tried to debug the app I get this error: [...] read more
wpf
visual-studio-2017
modern-ui
visual-studio-2019
0votes
2answers

NetDispatcherFaultException while calling RetrieveOrganizationInfoRequest

I'm trying to invoke RetrieveOrganizationInfoRequest. Problem is I can't find it in latest SDK (Install-Package Microsoft.CrmSdk.CoreAssemblies -Version 9.0.2.5) - it existed in 9.0.2.4 SDK and is still supported by CRM. There is a known way how to get around this (I mean other than downgrading SDK) - execute the request [...] read more
c#
dynamics-crm
datacontractserializer
0votes
2answers

Why does my code-first ASP.NET MVC app suddenly not work just because I opened it from another location?

I have a code-first ASP.NET MVC app that ran smoothly and was able to access the data from SQL Server until I copied the project over to another location and opened it from there. I get the following errors: > System.Data.DataException > HResult=0x80131501 > Message=An exception occurred while initializing the [...] read more
sql-server
asp.net-mvc
code-first
0votes
0answers

Is there a way not to call SaveChanges so often in the case of a junction table for a many-to-many relationship?

I need to have an extra field in the junction table of a many-to-many relationship, like so: public class PersonCompany { public int PersonId { get; set; } public int CompanyId { get; set; } public Person Person { get; set; } public Company Company { get; set; } public [...] read more
c#
entity-framework-6
0votes
1answer

API Manager with .NET WCF services

I Have configured a .NET WCF service to work in API Manager and when I test with SoapUI it works as expected. Accessing from my client .NET application (updating only the URL in the binding) I get the following error. How do you pass the token from the .net client...I [...] read more
api
wcf
web
token
0votes
1answer

Chosen as the deadlock victim on simple Add() -> SaveChanges()

This simple program private static void Main(string[] args) { Parallel.For(0, 1000000, InsertTestEntity); } private static void InsertTestEntity(int i) { using (var dbContext = new TestDbContext()) { dbContext.TestEntities.Add(new TestEntity { HugeString = "Baby shark," + string.Join(", ", Enumerable.Repeat("doo", 500)) }); dbContext.SaveChanges(); } } public class TestEntity { [Key] public int Id [...] read more
c#
sql-server
entity-framework
ssms
0votes
1answer

WCF ServiceHost Callback Unstable

Problem The most reproducible scenario is starting the desktop application from a link on the tray application and then requesting the desktop application via a callback to do something. That virtually always throws a timeout error as other subsequent errors. WCF Environment: Server: A System Tray applet Client: WinForms desktop [...] read more
c#
windows
wcf
timeout
pipe
0votes
1answer

Whats the difference between STAThread method attribute and Thread Apartment State?

I think I do have a basic understanding of when STAThread is required, but what is problematic in the approach below? When a new thread is created the Apartment State is set I don't get any issues but when I decorate the method with the STAThread attribute I get an [...] read more
wpf
.net-4.0
thread-safety
0votes
1answer

Prism Unity interception error

PRISM = 6.3; Unity interception=5.3; I am refactoring a class to remove crosscutting concerns using Unity Interception with PRISM viewModelLocator = true. In Module I register the interface and class along with identifying an interceptor: Container.RegisterType<ITaxViewModel, TaxViewModel>( new Interceptor<InterfaceInterceptor>(), new InterceptionBehavior<LoggingInterceptionBehavior>()); I run the application then press the tax button [...] read more
c#
wpf
unity-container
prism
0votes
2answers

SSIS Authentification with SharepointList data source

I'm creating an SSIS Package that imports data from a SharePoint List, I've an authentification issue due to the SPCRED Component I think. for the record I'm using a developement server in a domain whitch is different from the Sharepoint One. So I do specifie this one "SharePoint Server DomainName" [...] read more
sharepoint
ssis
sharepoint-2013
ssis-2012
0votes
1answer

WCF service raises System.IO.InvalidDataException

I try to connect to the NetSuite OpenAir API from a .NET console application using a WCF client. I generated the proxy by adding a service connection and using the following WSDL: http://sandbox.openair.com/wsdl.pl?wsdl&style=document Logging in and reading data works fine as long as the HTTP response does not exceed a [...] read more
c#
.net
wcf
deflate
openair
0votes
0answers

Why do I get concurrent exception in Entity Framework when I'm the only user?

I just graduated and I'm working on my first project. I searched a lot and tried many solutions but none of them seemed to solve the issue. I'm new to .NET and Entity Framework and I'm trying to insert a new row into an existing table via POST call with [...] read more
.net
sql-server
entity-framework
0votes
2answers

System.Data.Entity.Core.EntityException occurred

I am struggling to connect to DB. My db doesn't require any username and pwd. My connection string in Web.config is <connectionStrings> <add name="EmployeeContext" connectionString="Data Source=LAPTOP- HKBMHNCA\SQL2016AGAIN;Initial Catalog=aspnet-CodeFirstWithMVC- 20170821025529;Integrated Security=True;" providerName="System.Data.SqlClient" /> </connectionStrings> The error log is as follows System.Data.Entity.Core.EntityException occurred HResult=0x80131501 Message=The underlying provider failed on Open. Source=EntityFramework StackTrace: [...] read more
asp.net-mvc
entity-framework
0votes
1answer

error generating the XML document - Workday WebAPI

When calling a Workday API Assign_Costing_Allocation there is suddenly an XML generation error: System.ServiceModel.CommunicationException HResult=0x80131501 Message=There was an error in serializing body of message Assign_Costing_AllocationInput: 'There was an error generating the XML document.'. Please see InnerException for more details. Source=mscorlib StackTrace: at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg) at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 [...] read more
c#
xml
soap
xml-serialization
workday-api
0votes
0answers

Crash when trying to run with release, instead of debug - No error

The following stack trace is from me trying to run "Release" instead of "Debug" I've set my warning level to the highest, and there are no warnings or messages. The application works fine in Debug, but crashes without errors in Release I am assuming it has something to do with [...] read more
xaml
debugging
release
formatexception
inner-exception
0votes
0answers

Error when trying to hide columns straight after binding data to datagrid

So I have an XML file which I read in then display the data onto a DataGrid. Once I bind the DataView of the XML file to the ItemsSource of the datagrid I then attempt to hide the 4th column that will be created (it's an ID which I don't [...] read more
c#
timer
datagrid
dataview
dispatchertimer
0votes
0answers

WPF, Cannot register duplicate name 'tabs' in this scope

I'm running into a bit of an issue, as the title says. Every time I name an object in XAML, I get an exception. System.Windows.Markup.XamlParseException HResult=0x80131501 Message='Could not register named object. Cannot register duplicate name 'tabs' in this scope.' Line number '93' and line position '14'. Source=PresentationFramework StackTrace: at System.Windows.Markup.WpfXamlLoader.Load(XamlReader [...] read more
c#
wpf
0votes
1answer

WCF fails to return complex type

I've faced a problem of returning complex type from wcf service and feel lack of knowledge to solve it. The problem is that wcf service brakes the connection when trying to return one complex type (it contains other complex types). The thing is that wcf returns another complex type without [...] read more
wcf
0votes
0answers

WebApi Error : An exception occurred while initializing the database

I have a local database .mdf file which was automatically created with MVC 5 with ASP.NET Identity. The database works in MVC 5 project but not for the WebApi project and it throws an error. Stack Trace for Get Request: System.Data.DataException occurred HResult=0x80131501 Message=An exception occurred while initializing the database. [...] read more
c#
asp.net-mvc
entity-framework
linq
asp.net-web-api
0votes
0answers

Wcf Rest Service Linq Query Failed with Angular JS Application

I am consuming Wcf REST Service into Angular JS Application. I am Facing some error with the linq Query . I got the follwing error on follwing line on debugging mode ..The underlying provider failed on Commit. ReciverAccount.Account_Balance += Convert.ToDecimal(mopneyTransfer.Amount1); dbContextTransaction.Commit(); I ma trying to send money one account to [...] read more
c#
entity-framework
linq
wcf
0votes
1answer

Get Security Token from WSO2 Identity Server 5.3 WS-Trust STS

I have WSO2IS set up with an AD LDS user store and have a WS-Federation Passive STS prototype written in ASP.NET MVC that works and can authenticate as a user defined in AD LDS. I am now attempting to write a simple .NET console app to manually connect to the [...] read more
wso2
wso2is
0votes
0answers

Why is't the file processed blocks with GZipStream and CryptoStream on C#?

I have two methods, one works, the other not. Working method: public static void CompressAndEncrypt(string sourceFile, string encrFile) { int bufferSize = 5242880; using (var readStream = new FileStream(sourceFile, FileMode.Open, FileAccess.ReadWrite)) { using (var writeStream = new FileStream(encrFile, FileMode.OpenOrCreate, FileAccess.Write, FileShare.ReadWrite)) { DESCryptoServiceProvider cryptic = new DESCryptoServiceProvider(); cryptic.Key = ASCIIEncoding.ASCII.GetBytes("ABCDEFGH"); [...] read more
c#
.net
0votes
1answer

Using OxyPlot in Visual Studio debugger extension

I'm trying to use the OxyPlot library in a VS debugger extension (WPF Xaml UserControl), however, even the simplest example fails. The call to InitializeComponent in the control constructor throws the following exception: System.Windows.Markup.XamlParseException occurred HResult=0x80131501 Message=Could not load file or assembly 'OxyPlot.Wpf, PublicKeyToken=75e952ba404cdbb0' or one of its dependencies. The [...] read more
c#
visual-studio
oxyplot
0votes
1answer

How do I do binding in a Visual Studio extension a Stackpanel?

I am writing a Visual Studio extension, which does not seem relevant, but perhaps it is. My code is throwing an exception in the codebehind when the initializeComponent is being called. I have a TeamExplorerSection which creates a "model" and passes it to the SectionView (the xaml) in the constructor. [...] read more
wpf
xaml
visual-studio-2017
xaml-binding
0votes
1answer

MVC EF - System.Data.Entity.Infrastructure.DbUpdateException

I have two models : UserProfile public class UserProfile { public int Id { get; set; } public string Name { get; set; } public virtual ApplicationUser ApplicationUser { get; set; } public virtual ICollection<UserPost> UserPost { get; set; } } UserPost: public class UserPost { [Key] [DatabaseGenerated(DatabaseGeneratedOption.Identity)] public string [...] read more
c#
mysql
sql-server
asp.net-mvc
entity-framework
0votes
1answer

System.Windows.Markup.XamlParseException occurred. Microsoft visual studio community 2017

Please can someone be of help. I encountered this exception below, while trying to compile an XAML code. > System.Windows.Markup.XamlParseException occurred HResult=0x80131501 > Message='Provide value on > 'System.Windows.Baml2006.TypeConverterMarkupExtension' threw an exception.' > Line number '28' and line position '22'. Source=PresentationFramework > StackTrace: at System.Windows.Markup.WpfXamlLoader.Load(XamlReader xamlReader, > IXamlObjectWriterFactory writerFactory, Boolean skipJournaledProperties, [...] read more
c#
xaml
0votes
1answer

Exception when Data Binding ListBox

I am implementing an application in MVVM. Right now I am trying to create an autocomplete that queries a database for potential results. The issue I am having right now is that when I try to set the Collection Property for the Listbox, I get this exception: System.Windows.Markup.XamlParseException occurred HResult=0x80131501 [...] read more
c#
wpf
xaml
mvvm
listbox
0votes
0answers

TaskHost.exe' has exited with code -2147220717 (0x80040313)

I've Navigate to next page and then Navigate back in windows phone 8, If 5 or 6 times i do this app is crashed and output windows shows "TaskHost.exe has exited with code -2147220717 (0x80040313)". I don't know why this is happening. If anybody knows please suggest me. It is [...] read more
windows-phone-8
0votes
0answers

Error 0x80131501 and error 0x89731812 when launching Windows Phone Project in Visual Studio 2012

When I want to launch any Windows Phone project in Visual-Studio 2012 with the Windows Phone emulator, I get the following errors: 0x80131501, and 0x89731812. How do I fix these errors? read more
c#
visual-studio
windows-phone-8
0votes
0answers

Synchronizing Customer between CRM and AX

I am configuring MS Dynamics connector for synchronising MS CRM 2011 and MS AX 2012. It has been working fine with some Entities, but I cannot get the Account to work. I have enabled the Address during the configuration and I can sync Customer Services with their Adresses into CRM's [...] read more
dynamics-crm-2011
microsoft-dynamics
dynamics-ax-2012
-1votes
1answer

How to call stored procedure in for loop using c#

I want call a stored procedure in a loop, but command time out when use command query, but if use linq then call stored procedure causes a runtime error: > System.Data.Entity.Core.EntityException > HResult=0x80131501 > Message=An error occurred while starting a transaction on the provider > connection. See the inner exception [...] read more
sql-server
asp.net-mvc
entity-framework
linq
stored-procedures
-2votes
1answer

XamlParseException: ''Provide value on 'System.Windows.Markup.StaticResourceHolder' threw an exception

Using VS-2017 and working on a WPF (MVVM Pattern) solution shared in TFS with other developers I'am getting this issue since I downloaded a new version of the solution from TFS The solution compiles correctly and works fine on other developer's machines who work on this solution, except mine. ExceptionTrace: [...] read more
.net
wpf
xaml
exception

Comments

Leave a comment

(plain text only)

Sources

  1. https://github.com/dotnet/coreclr/blob/v1.1.0/src/inc/corerror.xml
  2. https://msdn.microsoft.com/en-us/library/cc231198.aspx
  3. winerror.h from Windows SDK 10.0.14393.0

User contributions licensed under CC BY-SA 3.0