.net

How to uninstall a language pack for the .NET Framework on Windows Server 2008?

How to uninstall a language pack for the .NET Framework on Windows Server 2008? Currently the german langpack is active but it is not listed in programs and features. I already switched to the english language pack but it did not help. ...

Need idea for implementing Yahoo Signup form's Name field in asp.net

I want to do the same functionality for first name Field and Surname field in the registration page of yahoo. When i clicks on textbox. Default text dissapears. And when i loses the focus from same textbox the default text appears again. Here is the yahoo registration page. How can i do this. I want to do xactly same functionality. Can y...

Entity Framework ObjectContext in windows/WPF/Silverlight application

We are writing a WPF application using Entity framework (Silverlight with RIA services to be precise). We're using a shared ObjectContext through the application so that we can benefit from sharing data across the modules. The problem is - if user during his work opens let's say historical sales, it gets loaded to the ObjectContext and ...

.Net Bitmap class constructor (int, int) and (int, int, PixelFormat) throws ArgumentException on perfectly good arguments

I have some code that does something like this (Irrelevant bits snipped): void foo(Bitmap bmp1, Bitmap bmp2) { Bitmap bmp3; if(something) bmp3 = new Bitmap(bmp1.Width, bmp1.Height + bmp2.Height); else bmp3 = new Bitmap(bmp1.Width, 18000); (more stuff here that runs fine) } Anywho most of the time this r...

Is there a fiber api in .net?

Out of more curiosity than anything I've been looking for a set of C#/.net classes to support fibers/co-routines (the win32 version) and haven't had any luck. Does anybody know of such a beast? ...

.NET - Dictionary locking vs. ConcurrentDictionary

Hello, I couldn't find enough information on ConcurrentDictionary types, so I thought I'd ask about it here. Currently, I use a Dictionary to hold all users that is accessed constantly by multiple threads (from a thread pool, so no exact amount of threads), and it has synchronized access. I recently found out that there was a set of t...

Can I kill this process?

Possible Duplicate: Activity Monitor Problems in SQL Server 2005 I have some processes running on my database server that are taking up enourmous amount of CPU. When I view the detail about the process I get: set transaction isolation level read committed The other details include: Status: Sleeping Open Transactions: 0 Com...

How to have an exception define its own message in C#?

I want to define a custom exception that has two special properties: Field and FieldValue, and I want the message to be built from those two values in the exception constructor. Unfortunately the Message is read only. This is what I have, but it still requires the message to be passed. public class FieldFormatException: Format...

How do I Check previous data in LINQ?

I have a collection of data that checks if there is a change in a particular field to get the sum for another column. Total = Details.Where(s=>s.indicator != *prior indicator before this...).Sum(s => s.amount); ...

Sharepoint Task stored in non sharepoint Database

I am looking at creating an application that will be a SharePoint application. I want to store the tasks in my own database but still have them show up in the Calendar is this possible? ...

How can I use WebKit.NET or GeckoFX in a .NET WinForms application with dynamically loaded assemblies?

Hi, I'm working on a .NET WinForms application that loads forms and other UI elements from separate assemblies at runtime. This works well. However, one of the assemblies I'm loading has a form that uses either GeckoFX or WebKit.NET to embed a web browser control. When I try to load that assembly with Assembly.CreateInstance() I'm ge...

.NET Framework on Android

Is anyone aware of any projects out there to port a version of the .NET framework to the Android platform, kind of like Mono.Touch? ...

how can i change WebBrowser from Ie to mozilla.

Hello I am working on C#.net application with System.Windows.Forms.WebBrowser; and IE is not responding properly so i want to change to mozilla so please tell me that how can i change this. ...

Determinate when an object not used by any other threads without lock?

Hi I implementing a high performance thread safe component, using no lock statements, only volatile and Interlocked are used for performance reasons. I have volatile reference-type member in a class, that contains thread safe instance. This instance is thread safe only for a couple of operations, and not for another. Because of that an...

Using SynchronizationContext for sending events back to the UI for WinForms or WPF.

I'm using a SynchronizationContext to marshal events back to the UI thread from my DLL that does a lot of multi-threaded background tasks. I know the singleton pattern isn't a favorite, but I'm using it for now to store a reference of the UI's SynchronizationContext when you create foo's parent object. public class Foo { public event ...

How can I programmatically retrieve a loaded project in Visual Studio 2008?

I want to create an hour counter to monitor my development time on a project. I want the time to increase whenever a certain project is active in Visual Studio 2008. Can I progammatically find out which *.csproj file is currently active in VS2008? ...

.net xml serialization, possible to apply some formatting?

I use a lot of XML serialization in one app I am busy with. .Net by default just shoves everything on 1 line. Is it not possible to get some formatting order during the serialization. Would like to have it neater, because at times people have to open these xml files up and read them. I guess what would be awesome is to have correct i...

How do I close or "uninitialize" Castle ActiveRecord?

I'm running some unit tests using Castle ActiveRecord that interact with a database. I have a procedure to drop the database (if it exists), then re-create it, before I interact with it in each test. If I run one test, this works fine. If I run multiple tests, the second one fails because it can't drop the database. Is there some way...

Snk file & Delay Signing

I am working with a set of delay signed assemblies which I am able to install and load from GAC after skipping verification (sn -Vr * ... Since Delaysigning as a process requires only the public key file sn -k keys.snk (both Public & Private keys) sn -p keys.snk pkey.snk (only public key) Add pkey.snk to project properties and chec...

Are .NET WSE client stubs thread-safe?

Are client stubs generated from WSDL by .NET WSE thread-safe? Of course, "thread-safe" isn't necessary a rigorously defined term, so I'm at least interested in the following: Are different instances of the same stub class accessible concurrently by different threads, with the same effective behavior as single-threaded execution? Is a ...