Questions tagged as 'c#'

1
answer

Failed to consume WS SOAP from VS2015 with C #

Dear Inside VS 2015 with C # I created a dll project in which I make a reference to a WS from one of our suppliers, after that I created a unit testing project where I call the service without further ado with its constructor ServiceHotelC...
asked by 06.07.2017 / 23:06
2
answers

Export flat file with special characters in C #

I have a query from SQL , I show it in a GridView in a web page ( ASP.NET ) and from there I export it to a flat file delimited with C # and I have problems with accents and special characters. For example, the word MUÑOZ , that th...
asked by 07.07.2017 / 00:49
1
answer

Assign values to the select

I have Brand, Blend, Flavor and Drink classes. Flavor has a Mark and a Blend. Drink consists of a Taste and other fields: public class Brand{ public int BrandId{ get; set; } public string Name{ get; set; } public ICollection<Flavor>...
asked by 05.07.2017 / 20:28
2
answers

Open asp: visible panel = true from a link in a different file

Greetings. I have 3 panels with visible=false and in .cs the method that shows one or the other according to the button that is pressed, but all this is within the same file products.aspx/.cs . What happens if I want to execu...
asked by 06.07.2017 / 19:30
1
answer

Save Dataset to table sql server in window form c #

good afternoon I'm making a datatable saved in a sql server table but I get the following error: this is my code: DataSet result; dataGridView1.DataSource = result.Tables[cboSheet.SelectedIndex]; //string valor = data...
asked by 30.08.2017 / 05:32
2
answers

Ask if you want to enter another data in c # (do ... while) [closed]

Ask the user from the console, when you finish entering data, ask if you want to enter another data, when answering that "si" repeats the cycle.     
asked by 20.06.2017 / 19:55
1
answer

Assign a counter as Id to an HTML tag

My question is the following, in my project of ASP.NET , I have in a view, the foreach of razor with which I print my values of the model, and a div is created for each iteration, what I need is that this div have an id au...
asked by 20.06.2017 / 20:41
1
answer

Create HTML table with c # from a datatable

Good afternoon everyone. What I need is to create an HTML table from c #, the data I need I have in a datatable, this in order to send an email from a class and in the body must go a table. Searching the web I could see that it can be achi...
asked by 03.06.2017 / 19:35
3
answers

Controller in MVC for the same Model but different role

Good morning, I am studying and I do not have much idea of how to do the following: I have products as an entity. In the MVC model I have its Controller and its ProductViewModels. Well I have used this for the Admin, this create modifies and...
asked by 20.07.2017 / 08:01
2
answers

Error in SQLite: "attempt to write to readonly database"

All the queries work well for me but when I try to do a insert in SQLite I get the following error:    attempt to write to readonly database     
asked by 04.07.2017 / 20:47