What is the right way to avoid errors on INSERT and UPDATES with a SqlDataAdapter/SqlCommandbuilder when the SQL Statement used to SELECT has a computed column as one of the return fields?
I get the error now that "The column Amount cannot be modified because it is either a computed column or is the result of a UNION operator".
UPDATE:...
I've noticed that the Delegate class has a Target property, that (presumably) returns the instance the delegate method will execute on. I want to do something like this:
void PossiblyExecuteDelegate(Action<int> method)
{
if (method.Target == null)
{
// delegate instance target is null
// do something
}
...
I'm trying to format a currency (Swiss Frank -- de-CH) with a symbol (CHF) that is different that what the default .Net culture is (SFr.). The problem is that the NumberFormat for the culture is ReadOnly.
Is there a simple way to solve this problem using CultureInfo and NumberFormat? Is there some way I can override the CurrencySymbol?
...
I need to make asynchronous calls to .NET web services from java since synchronous calls are too slow. I know in .NET this is easily done since the stub (proxy) class created by wsdl.exe also generates methods for asynchronous calls(BeginMethod()/EndMethod()). I created the service stub using eclipse Ganymede but no asynchronous method...
The problem is that I need to know if it's version 3.5 SP 1, Environment.Version() only returns 2.0.50727.3053.
I found this solution but I think it will take much more time than it's worth, so I'm looking for a simpler one. Any suggestions?
Thanks in advance
...
Hi,
In my settings file, I would like to have one setting that is of the type List(of Myclass).... I can't find anything on the net that does this. Is it possible?
...
I'm a lead developer in a small development shop exclusively using Microsoft based solutions. We're currently implemently small to medium sized solutions using .NET 3.5 and SQL Server 2008 as a base. We also currently use Team Server simply for source control.
We have a larger project on the horizon and would like to start putting more ...
I have an application in C# .net which has a MainForm and a few classes.
One of these classes receives incoming data messages from a network.
I need to get these message's text appended into a multi-line textbox on the MainForm.
I can send the message to a method in the MainForm by making the method static, but then the static method can...
How do you group your class members inside the class? When you add a new method to a class, do you add them to where it should be alphabetically for instance?
Do you use regions? I use them along with the groups created by Visual Studio's interface implementation stub generator, like:
#region IEnumerable
...
#endregion
I use region...
I need to know if there are any tools to figure out the interface to a TCP client. My Company has purchased a 3rd party tool and we really like the Server side and most of the client side.
I would like to see if I can figure out the calls that the client side makes to the server so I can create the client side functionality we want.
I...
When I try to (re)publish my clickonce app, I am getting this:
Failed to copy file 'E:*path*\default.htm' to '\*path*\default.htm'. Unable to add 'default.htm' to the Web site. The file 'default.htm' already exists in this Web site.
There are three files with the same error message - default.htm, setup.exe and my app's .application fi...
Is there a way to reference a namespace globally across the whole solution?
So instead of having these lines in every code file:
using System;
using MyNamespace;
having to declare them only once, and every code file would use them.
Btw I am using Visual Studio.
...
This is probably unrealistic, but would it be possible to enable a component to be notified of all first chance exceptions occuring in its process?
We have some third-party (contracted by us) components which fail to do anything but eat excepitions and the politics of the business relationship make the whole ordeal a royal pain.
We als...
I work for a tech company that does more prototyping than product shipment. I just got asked what's the difference between C# and F#, why did MS create F# and what scenarios would it be better than C#.
I've been using the language for a while now and I love it so I could easily go on about the great features of F# however I lack the ex...
I'm trying to write an XSLT that will transform an XML document that I have to a CSV file. Here's a sample of the XML:
<?xml version="1.0" encoding="utf-8"?>
<Import>
<Users>
<User ID="user_1" EmailAddress="[email protected]">
<Contact FirstName="John" LastName="Doe" />
<Address Street1="808 El...
I've been writing .NET software for years but have started to dabble a bit in Java. While the syntax is similar the methodology is often different so I'm asking for a bit of help in these concept translations.
Properties
I know that properties are simply abstracted get_/set_ methods - the same in C#. But, what are the commonly accepted...
I have written a chart that displays financial data. Performance was good while I was drawing less than 10.000 points displayed as a connected line using PathGeometry together with PathFigure and LineSegments. But now I need to display up to 100.000 points at the same time (without scrolling) and it's already very slow with 50.000 points...
I am using the Array.Contains method on a string array. How can I make that case-insensitive?
...
I’m doing maintenance on an asp.net web app that uses remoting to call a remote server object to order a credit report. The call “works on my machine” but throws an exception “could not load file or assembly ‘choicepointClue’” when run from the production server (which is running the 64 bit version of the .net framework).
I resolved the...
Hello,
My program draws text on its panel,but if I'd like to remove the text I have to repaint.
How do I call(raise) the paint event by hand?
...