Questions tagged as 'c#'

1
answer

Web Installation

I am developing a website in .net c # mvc. currently the web works well, but before putting it in Real I wanted to do an installation test so I have registered a web in the IIS and I have copied the content of all the web that I currently have....
asked by 26.01.2018 / 13:00
2
answers

How to make the tag br / be recognized in html when it is returned from a database?

I am working in C # with MVC and I am saving text in SQL server but I need to do line breaks so I chose to include the <br/> tag to perform the jumps, from a view I made the insertion in the data base and another view I show that da...
asked by 25.11.2017 / 01:10
1
answer

Show certain data in a column

I have my next table called LIST with two columns: Id, and Name, in the Name column I have 4 data: Notes, Agenda, Authorization and Membership. public IQueryable Listar1() { return from titus1 in Contexto.LISTA...
asked by 25.11.2017 / 16:41
2
answers

SQL Network Interfaces, error: 26 when wanting to run a query from a WEB page

Greetings. I have been investigating the following error that appears to me when running a web page that I am programming in VS2013    Server error in the application '/'.       Error related to the network or specific to the instance whil...
asked by 28.11.2017 / 00:02
1
answer

Problem with keys in EF mvc5 asp .net

I have defined the keys in each of those entities with the attribute [key] as you can see in the photo, apart from that the namespace is imported "using System.ComponentModel.DataAnnotations;" and when creating controllers this happens....
asked by 23.11.2017 / 21:43
1
answer

Save file and path? [closed]

I have my following code: public class UsrConexion { public string cadenaconexion; protected string sql; protected int resultado; protected SqlConnection cnn; protected SqlCommand comandosql; protected string mensaje; protected string sql1;...
asked by 23.11.2017 / 22:07
1
answer

Roles and Permits MVC 5

Good morning I am working on a project with MVC 5 with Entity Framework, as you know the tables for the registration of users and roles are generated automatically is very easy with entity framework, well what I want to do is the customizatio...
asked by 01.12.2017 / 16:17
2
answers

Check the new value of a variable in an action

I have the following piece of code from a unit test: [Test] public void ValidCancel_ReturnsSuccess() { // TODO: Rewrite this action to really check the cancel bool cancel; var message = new MessageHubCancellableGenericMessa...
asked by 30.11.2017 / 18:14
2
answers

ASP.NET MVC Web form: 404 error

Working with ASP.NET Core 1.1 Visual Studio 2017 - EntityFramework 1.0.0, Microsoft .Net Framework 4.7.02046, SQL Server 2012 LocalDB C # I am making my first experience with these tools. I follow the example ContosoUniversity developed in the M...
asked by 20.11.2017 / 23:31
1
answer

Add header (usernametoken) to web reference C #

Good evening, Add a web service as web reference, and I need to create the header with the authentication (Password and username), I do it when I add a Service Reference, but with a web reference no. Can someone help me, please?. I have re...
asked by 18.11.2017 / 02:09