Questions tagged as 'c#'

1
answer

How to capture an Object in the route (Route) of the PUT in a controller?

is that I have a PUT and I want to capture the value of the field that I am going to update, but in the database in SQL_Variant , so to do it I have to send an object when sending it to the database , this is my PUT [HttpPut("{empid}/{co...
asked by 24.10.2018 / 18:52
1
answer

How to send an alert ("") from asp.net, sending a string + a variable

In what way you should send a message type alert, from an asp.net form. Currently I used this: if (user._contraseña.Equals(claveI)) { ClientScript.RegisterStartupScript(this.GetType(), "alert", "aler...
asked by 11.11.2018 / 01:24
1
answer

Help with a transaction with dapper

Hi, I'm doing a transaction using dapper, but the detail is that when the error is marked. I reverse the changes with the rollback, but when I try a second execution. it tells me that the conectionString is empty. using (var cn = VariablesGl...
asked by 31.07.2018 / 21:29
1
answer

C # MVC versions in VisualStudio

I am currently working with VisualStudio 2017, C # and have worked with ASP templates 4.5.2 as shown in the image: I am a web programmer and I do not have much knowledge about these Microsoft tools, I have become accustomed to working with...
asked by 31.07.2018 / 16:14
1
answer

how to display the files of a folder on a website

Currently I have a very simple console app that shows me the names of the files that are inside a specific folder. public void archivoCarpeta() { string carpeta = ConfigurationManager.AppSettings["carpetaDescarga"]; DirectoryInfo dir =...
asked by 29.08.2018 / 03:22
1
answer

Modify from DataGridView connected to SQL in C #

Good morning, I am developing an application using Windows Forms within C #, it is a record of workers in a store, the users are entered from a form inside the application and they are shown in the following module in a DataGridView which is...
asked by 23.08.2018 / 16:39
1
answer

I do not update with Update

I am trying to modify a password based on a textbox. Pass the code but do not update the database. string conexion = "Data Source=(LocalDB)\MSSQLLocalDB;AttachDbFilename=|DataDirectory|\Resources\Atreus_bbdd.mdf;Integrated Secu...
asked by 14.08.2018 / 08:48
1
answer

Execute a stored procedure with Entity FrameWork?

I am trying to execute an SP that does not return a result (it does not generate any complex type or entity), but this does not appear as a function in the context of the EF, I need some step or in what way I can execute it, this SP It has input...
asked by 03.08.2018 / 18:08
1
answer

Failed to perform Web Scraping to the src attribute in img

I'm trying to learn to do Web Scraping, I've already managed to get all the data except one, the src attribute of an image (img), the funny thing is that if I get the alt. A fragment of the example website: <li> <a href="/ve...
asked by 26.07.2018 / 02:08
1
answer

why do I get this error in visual studio C #?

hello I see this error and I do not know what I forgot to install in visual study so that I would appear     
asked by 04.09.2018 / 08:57