Questions tagged as 'c#'

1
answer

Using EF and Dapper in the same project

I'm making a simple insert of a user class, it's taking almost 10 seconds to save the information. So I tried to find other solutions to solve my performance problem and found Dapper . My question is there any way to use the two...
asked by 05.05.2017 / 02:57
1
answer

Capturing StackOverFlowException

Hello, I'm passing some problems on the server and with the application developed in MVC ... I checked that the site was restarting the application pool alone, so I went into Event Viweer and realized that the application is experiencing S...
asked by 10.05.2017 / 02:10
3
answers

Build string with special characters

I'm building PDF's, and I need to print a string with special characters. For this I am constructing the string as follows (using iTextSharp ): PdfPCell teste = new PdfPCell(new Phrase("<O meu texto> '\u20ac'", fontetexto)); Now...
asked by 28.02.2014 / 16:05
2
answers

How to put buttons / titles with different design / style in C #? [closed]

In C # is there any way to put eg the buttons with a different design, or the title with a different style? I want to get my program fancy.     
asked by 10.03.2014 / 15:12
2
answers

Convert HTML as an image

I have string with the page's HTML, is there any way to save it as an image? Render the entire page as an image, and if possible, store it in MemoryStream .     
asked by 15.03.2017 / 19:03
2
answers

Convert String Value to Hexadecimal without changing format

I'm using the following code in a Class. public Int16 Endereco = 0x7302; byte[] Data = BitConverter.GetBytes(Endereco); Array.Reverse(Data); [...] I would like to receive the value for the Endereco variable of a String...
asked by 31.01.2017 / 12:25
1
answer

How to transform a string into HTML C #

I'm using a component and need to load it with HTML snippet that comes in a variable. For that I created this JQuery: $(document).ready(function(){ $('.mentions-kinder').html('@HttpUtility.HtmlDecode(Model.FormulaRecover)'); }); But eve...
asked by 18.03.2017 / 23:26
2
answers

Deserialize Json string [] to string []

I have the following JSON : {"TicketID":["116","114","112","108","107","104","102"]} When I try to deserialize to string[] I get the error:    Server Error in Application '/'.       No constructor without parameters   was...
asked by 22.12.2017 / 19:14
2
answers

How to convert to base64 in C #?

I'm using WebForms. It has a certain part of this application where I send, through Ajax, a base64 string, which is the code of an image. I'm used to using PHP and I use the base64_encode and base64_decode functions to do the ba...
asked by 02.03.2018 / 17:32
3
answers

Put date in American format with substring

How to put the string 22012018 which is a date in the American format to save to the database? The code below returns me the value:    2018-22-01 That is, YEAR-DAY-MONTH The right one would be MONDAY-DAY EstFData = Path.GetFileNam...
asked by 16.03.2018 / 17:37