Tagged Questions

C# is a multi-paradigm programming language encompassing strong typing, imperative, declarative, functional, generic, object-oriented (class-based), and component-oriented programming disciplines.

learn more… | top users | synonyms (5) | c# jobs

0
votes
0answers
4 views

Could not load file or assembly 'Newtonsoft.Json

Could not load file or assembly 'Newtonsoft.Json, Version=4.5.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed' or one of its dependencies. The located assembly's manifest definition does not ...
0
votes
0answers
7 views

Multiline text in cell label affecting ScrollToRow positioning

I have a table view that should scroll directly to the most current date section on ViewDidLoad(). When the cell has a single line of text the ScrollToRow works perfectly: But when I add additional ...
0
votes
2answers
27 views

Non-virtual, non-abstract method causing “c# virtual or abstract members cannot be private”

Error 1 'Interface.myDerivedClass.myMethod()': virtual or abstract members cannot be private c:\users\igmfun\documents\visual studio 2012\Projects\Interface\Interface\Program.cs 16 Making a ...
0
votes
0answers
9 views

selecting multiple rows using Shift key + down or up arrow keys in asp.net gridview

Over the internet, I am not able to find any solutions or anyone come across this situation at all in asp.net gridview. I have already implemented the functionality of using Shift key and then left ...
0
votes
0answers
9 views

Image Resizer usage in ASP.NET

I made a NuGet installation to use ImageResizer API's. But whatever I do, It didn't get start.. 1)I made NuGet installation 2)in my .aspx web page I put .ashx?width=30px&height=15px at the end of ...
0
votes
2answers
29 views

List isn't outputting correctly

I have a list which I am reading data into. I checked how to output a list but what is working for others isn't working for me. I noticed none of the examples I seen every used a class in a list tho ...
0
votes
2answers
22 views

How to delete the file after 30 seconds/ or delete the file once after the job is completed

I am working on a C# project and i need the file to deleted after 30 seconds. So once the file sent to the machine i need the software to count till 30 seconds and at same time show a splash form and ...
0
votes
0answers
6 views

awesomium web scraping certain parts

I asked this earlier but I wanted to rephrase the question. I am trying to make a scraper for my project. I would like to have it display a certain part of a link. The only part of the link that ...
0
votes
1answer
13 views

Can someone help me with my WCF Generic?.. it doesn't work

I have a solution (XYZ) with 4 projects (XYZ.Domain, XYZ.Data, XYZ.Service and XYZ.Client). I need to run the WCF web service. This is my code: namespace XYZ.Domain { [DataContract] public ...
0
votes
0answers
3 views

SQL Server 2012 EncryptByCert Partial File

I have a small conundrum that I need help with. I have a file sharing application that requires encryption of the file that is stored. Its stored in SQL Server 2012 and we're using the EncryptByCert ...
0
votes
0answers
20 views

C# razor input var to controller search sql

I am doing what should be a basic programming item but I seem to be missing something on how MVC works. I have a web page that gets inventory items from a database and displays them. I added a ...
0
votes
0answers
13 views

Implementing a Generic Repository for my web application, is hard to achive

I am reading the following tutorial about creating Generic Repository Link in asp.net mvc & EF, to perform CRUD operations, as follow:- using System; using System.Collections.Generic; using ...
0
votes
2answers
16 views

Insert Into query get an exception.

I have a problem with this code that perform an insert query (the problem is that when it try to execute the query an exception is thrown): _strSQL = "INSERT INTO Cpe ( DateAdded, [Cpe] "; ...
0
votes
0answers
5 views

Run Time Error When Saving to Updated DataGrid

I'm trying to create an Entity Framework with WPF. I bind a DataGrid to one of the EF objects. Everything displays and is fine until I add try to save changes made in the DataGrid. Then I get a ...
0
votes
0answers
6 views

Upload Multiple Large Files via FTP with Progress Bar using ASP.NET C#

I need to upload large files (>2GB) to a web server, and ASP.NET has a 2GB file upload limit. So what i would like to know is, if its possible to upload files using FTP as i do with HTTP. In other ...
0
votes
0answers
4 views

How to verify an HttpWebResponse in clearing a given cookie

I'm writing a test where I want to make a specific request and then validate the response. The step I'm missing is to verify that a specific cookie is being cleared. Set-Cookie MyCookie=; it looks ...
0
votes
0answers
6 views

Import Image Editor for Dev Express XAF

I am evaluating the Dev Express eXpress App framework v14.1 and want to write a property editor to import an image into my database image field using the File Open Dialog box. There is an example of ...
0
votes
1answer
6 views

CurrentPlatformEnlightenmentProvider can't be cast to IPlatformEnlightenmentProvider during await on Rx Observable

In a library that I've written I've got a function which creates an Rx ReplaySubject and pushes some things to it from a task, returning the subject as an IObservable for others to watch (it's just ...
-1
votes
0answers
2 views

Insert table into Outlook Email

I quite often send out email notifications using Vbscript using the Outlook.Application object. Up to now I have just needed to display data and used HTML in the Outlook body to make it look pretty. ...
0
votes
0answers
5 views

Player controls desktop to touch devices, & Tagging in unity 3d c# script?

at-last i found a solution for android controls or if you are converting your desktop game to android or any other platform. But unfortunately its incomplete. using UnityEngine; using ...
0
votes
1answer
6 views

Load string resource for textblock x:Uid in code behind

I have a string resource that I'm using to set as the x:uid for a textblock <data name="Expected.Text" xml:space="preserve"> <value>Expected Text</value> </data> ...
0
votes
1answer
16 views

Adding Click Handler On UserControl Breaks Click On Children

I have a user control that I'm trying to make draggable. The whole control should be draggable except when you click on buttons or text boxes. I'm handling the mousedown, mouseup and mousemove ...
0
votes
1answer
31 views

how to convert a string into integer representation and change it back

I was wondering if there were any good methods to change a string into an integer representation and then be able to change the integer representation back to a string? There are a lot of ways to ...
0
votes
0answers
14 views

Access Local .aspx Page in Visual Studio GUI C#

I currently have a .aspx file created in my solution that provides help for a GUI application saved in the same solution. I want to be able to have the user click on a help box and have this local ...
0
votes
1answer
10 views

TestStack/White dos not return any window of an application

I want know can i use TestStack to doing an automate process on an application. so i wrote a simple code to count all windows of the target application. First i tested it on a sample application ...
0
votes
1answer
9 views

How do I create a custom (flat) collection which includes grouping?

I am trying to roll my own data virtualization container for a large collection. I've been all over the web and found many helpful examples of how to implement virtualization, but in all of the ...
0
votes
3answers
34 views

Why can't I add this entry to my dictionary?

I am attempting to make an application which gets and inputted URL via textbox, retrieves the HtmlCode of that website when a button is clicked and stores both in a dictionary which is then displayed ...
0
votes
0answers
31 views

MVVM - Why no converters?

I am working with .NET and am trying to follow the MVVM design pattern. However, I am puzzled at the number of posts recommending against the use of Converters for what I want to do. It seems a common ...
0
votes
0answers
13 views

Awesomium: Return HTML Source Without Javascript

I would like to grab the HTML source in a string without using Javascript. Does anyone know of a way to accomplish this? My problem spurs from the motivation to grab HTML source before a Javascript ...
-1
votes
2answers
21 views

How i do Required If validation by function in MVC5

if email exist by function check i want display error how i do it? [RequiredIf(BL.datafuncs.checkIfExist(email) == true, ErrorMessage = "email already exist")] public string email { get; set; } ...
-3
votes
0answers
21 views

How do I set username and password for SmartIrc4net

I want to connect to an irc channel that has user accounts and password. I was looking at the examples https://github.com/meebey/SmartIrc4net/blob/master/examples/test/Test.cs and the documentation ...
0
votes
0answers
5 views

How do i take a photo with the correct rotation, aspect ratio in Windows Phone 8.1? (using MediaCapture)

Can any of you provide an actual working sample of how to take and save a photo using the MediaCapture element. I've tried looking for an actual solution in MSDN but none of those explanations or code ...
0
votes
2answers
32 views

Initial Value of DateTimePicker wrong

I'm probably missing something obvious but I can't see it..... I have a DateTimePicker control (Winforms) to display just the Time HH:mm:ss of the DateTime. The properties are as follows Checked = ...
0
votes
0answers
6 views

WPF DataGrid RowEditEnding Event to call Update

I am using WPF . . . datagrid bound to a database via the VisualStudio IDE drag and drop, and found a way to have my datagrid update and add to the database in real time using the RowEditEnding event ...
1
vote
0answers
11 views

How to fall back from a custom MvcRouteHandler to next one in Route Table

I have a custom MvcRouteHandler which checks database if a Url exists and pairs it with some controller action and Id. However if this route handler can not find a matching pair in database, I'd like ...
0
votes
0answers
17 views

Avoiding HttpRequest fail

I'm building an online game in c# winform, which is the client. It sends requests to the server which is a PHP web application, then handles the response. It would work fine, but somehow, maybe ...
0
votes
1answer
39 views

How to process IEnumerable in batches?

A lot of time my lists are too big tor process and i have to break them up into batches to process. Is there a way to encapsulate this in a method or an extension. I seem to have to write this ...
-1
votes
2answers
45 views

Calling a method and continuing in c#

If I have the following: public string DoSomethingQuick() { DoSomethingThatTakes10Minutes(); return "Process Started"; } public void DoSomethingThatTakes10Minutes() { /// code to do something ...
0
votes
0answers
10 views

Get JavaScript values from a webpages code

I am trying to use jint to access the value of certain javascript variables inside code that I have scraped from a webpage with CsQuery. My code looks like: var dom = ...
0
votes
1answer
15 views

Extract Data from Excel File and Store in SQL Database

I am looking for advice on the best way to parse a Microsoft Excel File and update/store the data in a given MS-SQL Database. I using ASP .NET MVC so I plan on having a page/view take in an Excel ...
0
votes
0answers
2 views

Visual Studio Unit Test Plugin to External Process

I am working with a team to write a few Computer Aided Design (CAD) plugins. One of our CAD systems has its plugins run as out-of-process executables and one has them run as in-process .dlls. For ...
0
votes
0answers
9 views

TwoWay Collection Binding Sync/Lock

What is the best way to synchronize 2 sets of data via Binding? Target = Custom Setters - raises custom events whenever something changed Source = ObservableCollection - raises events whenever ...
0
votes
2answers
15 views

Reading xml string and populating list collection

I need to read the xml string and assign the values to list collection. I need to read the question node and assign it to the list collection variable. Similarly read the answer and assign it to list ...
0
votes
0answers
4 views

Using GoogleWebAuthorizationBroker and issue with CancellationToken.None

I am trying this code in a C# project: m_Credential = GoogleWebAuthorizationBroker.AuthorizeAsync(Secrets, m_Scopes, "user", CancellationToken.None, ...
0
votes
0answers
7 views

RowEditEnded event fired before save

I have a list of items in a RadGridView element. The element has a RowEditEnded eventhandler attached to it so that whenever a row in the grid is finished editing, the handler gets fired. There's a ...
0
votes
1answer
7 views

How can I set AllowAutoRedirect per request? Sharing HttpClient in multithreaded environment

I'm little confused about HttpClient. At the moment I'm using single instance of this class in my whole application. However it seems, that it doesn't allow me to set, for example AllowAutoRedirect ...
0
votes
0answers
15 views

Why do I get a constant return instead of scope_identity?

I've used Entity Framework many times in the past, and called stored procedures that return SCOPE_IDENTITY() with no problems. However, sometimes (as is currently the case), these stored procedures ...
-2
votes
0answers
33 views

Convert Form Class to Byte Array

I'm trying to convert my form class to byte array to load it on runtime by casting it again back into form class, but since form class has no fixed size i'm getting an error. Is there any way to do ...
0
votes
0answers
8 views

Intellisense XML Documentation for multiple variable declaration.

I have recently started adding the xml documentation to my code. I am trying to add it to code were I declare multiple variables in one line. Example: /// <summary> Integer1 ...
0
votes
1answer
32 views

Convert Dictionary<object, string> to Dictionary<string, string>

I have a dictionary of <object, string> that I know for a fact can be converted to <string, string>. Rather than loop over the 1st dictionary to build up the second one, are there Convert ...