Questions tagged as 'c#'

1
answer

Upload Image from DataGrid to Image

The variable x is associated with an image (blob field) that I uploaded to a Datagrid from a MySQL database. DataRowView selectedRecord = (DataRowView)dataGridImagem.SelectedItem; var x= selectedRecord.Row.ItemArray[2]; How can I now procee...
asked by 14.12.2016 / 22:02
1
answer

Error when disconnecting from PostgreSQL

I'm trying to make a C # application with PostgreSQL SGDB, but whenever I close the connection it gives the following error:    Object reference not set to an instance of an object. I'm using mono.security and npgsql2 but I...
asked by 12.12.2016 / 16:03
1
answer

Apply CSS Style to Razor elements eg EditorFor

How do I apply a style to all EditorFor of my View ? Example field : @Html.EditorFor(model => model.Photo, new {htmlAttributes = new {@class = "form-control"}}) I tried to do this but did not: <style> Html.Ed...
asked by 14.12.2016 / 23:31
1
answer

When testing my web C # ASP.NET locally in Fiddler it returns me a 404 error

I'm creating a stock control system with android application integration, the connection is being made through a Web Service API. However I can not test the methods that exist in it to see the results returned, I'm using Fiddler but every time I...
asked by 01.12.2016 / 21:05
1
answer

Control 'ContentPlaceHolder1_Name' of type 'TextBox' should be inserted in a format tag with runat = server

I'm doing a job for college, an application web forms in Asp.net C #. I'm having a problem and so far everything was fine, but out of the blue is giving this error. I looked for some related things, and this piece ended up "showing" my web page,...
asked by 27.11.2016 / 21:13
1
answer

Wait with AlertDialog ()

Good! My problem is with AlertDialog asynchronous Xamarin.Android . I have a class with a method that I set an alert with some fields ... With the data from these fields, I mount an object to make my CRUD . The problem is when...
asked by 21.11.2016 / 20:20
1
answer

Creating a DropdownList [closed]

I'm using asp.net-mvc-5, and wanted to know how to create a DropdownList without being in this pattern here: <div id="conteudoEscolha"> @Html.DropDownList("", null, htmlAttributes: new { @class = "form-control", id =...
asked by 21.11.2016 / 18:17
2
answers

Implementing ProgressBar

//cria conexao com o DB OleDbConnection aConnection = new OleDbConnection(@"Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\Users\Casa\Desktop\Inventario.mdb"); //comando SQL OleDbCommand aCommand = new OleDbCommand("INS...
asked by 13.02.2017 / 17:23
2
answers

Error: 'ExecuteReader: Connection property has not been initialized.'

I need to access a database where I put the data myself, the insert part is working, but now I need to "get" the data again when I click the button, so it does not matter what way I do it you always get this error message:    System.InvalidOp...
asked by 22.01.2017 / 17:30
1
answer

C # ASP.NET Method Get with parameter returning 404

Good afternoon guys, I'd like to know if anyone can help me. My Web Service has a Get method that returns the entire List of Products, however I would like to create a method that returns a Product according to a code passed to it. At the moment...
asked by 03.12.2016 / 20:50