Questions tagged as 'c#'

1
answer

Mapping controls windows forms

I'm developing a descktop application in C # The 4.5 framework I did not think the application could grow and have many fields, so there was a need to do automatic (from / to) mapping of controls to entities ... Example. public Pessoa Ge...
asked by 09.08.2018 / 12:48
2
answers

Show GroupBy List using Lambda, in the view. ASP.NET MVC

Well, I have a little big problem here. I make the query in the database using Lambda , and I use the GroupBy tag, the query is bringing objects correctly, the problem is that I can not show in the view. gives an error when I use...
asked by 14.08.2018 / 16:58
1
answer

How to Bind the Visibility of a Label to the Size of a List

I have a list of objects of type "BasicVariable", a% of them%, and I need the Graphic Interface to show a Label when the number of items in this collection exceeds 1000, I think the binding is correct but I did not get one how the counter and UI...
asked by 31.07.2018 / 18:38
3
answers

Use string to reference variable

I want to pass to the function execSQL the name of the variable that I want to use in % with% and from string SQL, pass the variable directly to the base.consulta() function, ie pass the variable that has the same name as string...
asked by 31.07.2018 / 18:18
1
answer

Error System.Data.Entity.Infrastructure.DbUpdateConcurrencyException while doing update with entity

Good morning. I need to do an update via entity and it accuses me of the following error: System.Data.Entity.Infrastructure.DbUpdateConcurrencyException: 'Store update, insert, or delete statement affected an unexpected number of rows (0)....
asked by 01.08.2018 / 13:43
1
answer

Highlight with bold a concatenated item

I would like to highlight in bold a part of the text that is in the DisplayAlert notification. DisplayAlert("Alerta", "Deseja realmente incluir o lance de valor de R$ " + EntryLance.Text + "?", "Sim", "Não"); Obs : If you can give me an...
asked by 04.10.2018 / 19:41
1
answer

How to save the return of a Webservice to disk?

I need to save a return of a webservice to the directory. How do I write the value of this ret variable to a xml file. Return: XML of type Results.xsd I tried this way: WSHP.XMLServer ws = new WSHP.XMLServer(); va...
asked by 02.10.2018 / 19:58
2
answers

WebApi Token C # Auth

I am issuing a token, but at the moment making a request with the token, returns the following message:    "Message": "Authorization has been denied for this request." I am passing user and static password File: startup.cs private...
asked by 04.10.2018 / 17:04
1
answer

How do I set acceptable single values for an Enum property in a Serializable class?

Given enum as an example: public enum IcmsCst { [XmlEnum("00")] Cst00, [XmlEnum("10")] Cst10, [XmlEnum("20")] Cst20, ... } Is there a way to annotate so that I could specify that a particular type of ICMS could only a...
asked by 18.07.2018 / 22:07
1
answer

How to debug a Windows service?

I did a Windows E-mail Service every 5 minutes and would like to know how to debug it. I saw several tutorials on the internet, but I could not perform debugging. Would anyone know how to debug the service?     
asked by 24.07.2018 / 19:53