Questions tagged as 'c#'

0
answers

Error HttpWebRequest C #

I am making a request in a URL and trying to get the answer, I get the following error:    The underlying connection was closed: Unexpected error in a submission. The point is that this statement worked normally. Below the code: var...
asked by 23.06.2017 / 15:51
1
answer

Separate Asp.Net Context Context and Application Context

I'm creating a repository using the Entity Framework, and the need arose for my entities to communicate with the IdentityUser entity of Identity, but Identity is in a separate layer of my application layer.  Is it possible to create two contex...
asked by 16.06.2017 / 04:09
1
answer

Error creating extension for DataGridView C #?

I have already used extensions for other components and did not give this problem, you are giving error only with DataGridView . The component finds the extension, not the error, the error only displays when compiling the project. Whe...
asked by 01.06.2017 / 18:45
0
answers

List of int no delegate Func is not working

I'm studying something and I came across the following problem. I create a list of 7 elements and treat it within a Func < > it works, but if I increase the items in the list, then my method does not work as it should. That's right: This i...
asked by 02.06.2017 / 16:32
0
answers

Access-Control-Allow-Origin in different environments

I have a very strange problem: the same code works locally and in prod, but does not work in homolog. Basically, the problem is homolog (soon at login) is this:    XMLHttpRequest can not load link . In 'Access-Control-Allow-Origin' header...
asked by 01.06.2017 / 17:28
0
answers

Deserialization Json with DataContractJsonSerializer Null Pointer Exception

At first I'm auditioning if I can communicate right with the Wikipedia API. My first goal is to get data from the API, turn it into an object, and display something on the screen that demonstrates that this process is correct. I created a pac...
asked by 04.06.2017 / 18:15
1
answer

Newtonsoft.Json.JsonReaderException When doing a POST

I'm having trouble doing the post in my API my app until it registers the object but then it crashes the application and closes with this execution error: Newtonsoft.Json.JsonReaderException: Unexpected character encountered while parsing va...
asked by 05.06.2017 / 00:23
0
answers

More than one query on a very slow request on the first request in C #

I have a method that requests data to the bank and in this same method I call another method that also requests the bank (mySql). public class Viagem { public int idViagem { get; set; } ... public Cidade origem { get; set; } publ...
asked by 05.06.2017 / 19:06
0
answers

Error in design mode in xamarin

I'm having this problem in my project using xamarin: IdidaSOensearchandfound this , but it did not work. What is missing is to uninstall everything and I have no guarantee that this will work. I'm waiting for some help.     
asked by 19.06.2017 / 15:22
1
answer

How to do a search in C #? [closed]

I'm having some difficulty doing a search as the picture illustrates. UsingcomboBoxworked,hereisthecodeClasspublicvoidpesquisar(intID){ArtigoList=newArtigo();SqlConnectionconexao=newSqlConnection(caminho);SqlCommandcmd=newSqlCommand();cmd.Co...
asked by 19.06.2017 / 11:36