.net

Using Japanese characters in WPF/XAML

I want to display Japanese chars in my WPF application: <Window x:Class="WpfApplication1.Window1" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Height="300" Width="300"> <Grid> <TextBlock Text="はい" FontSize="30" /> </Grid> </Window> ...

dotnetopenauth: where are the web samples

I downloaded dotnetopenauth last week and I have seen people mention the samples, but all I see is a desktop sample. Where would I find a web/asp.net sample? Sad, I don't know if I should post another question, but I really meant the linq2twitter web samples. ...

Enable Proxy Authentication for normal windows application.

my company's internet works on proxy server with Authentication(i.e. Browser prompts with window for username/password everytime i tried to access any web page). Now i have some windows application which tries to access internet(like WebPI/Visual Studio 2008 for rss feeds), but as they are unable to popup the the authentication window, ...

What's the maximum length of a type name in .NET

Possible Duplicate: What is the maximum length of a C#/CLI identifier? When generating dynamic assemblies and types, what is length restriction on the type name? ...

.net - how to connect windows service with systray application

I have a windows service that do something periodically. on user account runs systray application (written in C#) that communicate with windows service (thru .net remoting) and shows a status and some option to users. Everything works well beside that systray app uses 20-30MB of RAM ! it have to work in terminal environment, when 50 use...

Ignore records marked as deleted in navigation properties in EF 4.0

Hi, I have added a column 'IsDeleted' to every entity in my Entity Framework 4.0 model and implemented an Interface for it. How can i accomplish that the entities with 'IsDeleted' set to 'true' are ignored by all Objectsets and Navigationproperties in my model? Filtering the result using LinQ does not work i think, because the result ca...

Does anybody have offline documentation for the GPS.NET library?

I'm considering using the GPS.NET library in our CF.NET project, but I haven't been able to find any real documentation for it. The company that developed this SDK used to publish the documentation on their website, but the website is long gone and the only part of that information that can be found (http://web.archive.org/web/20080327...

question about working with System.Drawing.Graphics

hi all. i have a System.Drawing.Point[] filled with some System.Drawing.Point's. so when i want to draw this points as a polygon in a System.Windows.Form instance , the final drawn polygon is not all in the screen or sometimes is very small (in screen shown as 2-3 pixel). i wonder if there is some Library that using that i can just send ...

NOT IN statement for Visual Studio's Query Builder for TableAdapter

Hi I want to realize a query with the Visual Studio 2008 build in Query Builder for a TableAdapter similar like following (MSSQL 2008): select * from [MyDB].[dbo].[MyView] where UNIQUE_ID NOT IN ('MyUniqueID1','MyUniqueID2') How do I have to set the Filter in my query in order to call it with the myTableAdapter.GetDataExceptUniqueIds...

Is there any configuration for the garbage collector?

As I understand it, the garbage collector adjusts isself as the application runs, the threshhold used for example, when objects on the managed heaps are collected is adjusted (according to MSDN) over time. If an application crashes, does the runtime remember it's previous garbage collection 'settings' or any other settings? ...

When is it useful to define your own delegates instead of using the generics?

I've been going through some old code, where I came across some custom defined delegates, which are used thus: private delegate void ListenDelegate(UdpClient listener, bool multicast); private void ListenOn(UdpClient listener, bool multicast) { new ListenDelegate(_ListenLoop).BeginInvoke(listener, multicast, null, nu...

What is the best way to reset Ninject's IKernel container in an MVC app?

Basically in my Global.asax code I have the following IKernel property for Ninject setup like this (Also taking advantage of Microsoft.Practices.ServiceLocation). This Container is automatically called upon once it seems on the CreateKernel() override: protected override IKernel CreateKernel() { return Container; ...

How to find out the current overflow-checking context?

Is there a way to do this in C#? So for example, if your method is called and you want to know if the caller had put the method call inside a checked block? ...

Any ideas on a WCF Interceptor for a REST WebGet request to change the Url/Querystring parameters

Does any one know of a way I can intercept a REST Get request inside WCF, so for example I could change the value of any of the querystring parameters. So I need to have some code run, prior to WCF Evaluating the UriTemplate of the WebGet attribute and be able to edit it, before returning the value which it will use to continue processi...

CPU usage extremely high on TS deployment

Hi, Our application is written in .NET (framework 3.5). We are experiencing problems with the applications performance when deployed in a terminal services environment. The client is using a TS farm. They have 4GB ram and a decent xeon processor. When the application is opened in this environment, it sits at 25% CPU usage even when id...

How to replace string of digits with a padded version of that string in regular expression substitution?

I've got a string of digits that is either 4 or 5 digits long and it needs to be padded with "0" till it's 6 digits long. Is this possible? I'm using .Net framework. ...

Separate Datasource for Gridview Footer

I need to able to display the results from a seperate query in the footer of a gridview. What is the best way to go about this? I did some google searches and what I found pretty much revolves using the original datasource and doing something like addition to display the information in the footer. However I really need to be able to d...

Why does my listview keep drawing in LargeIcon View ??

I have a inherited Listview which standard has to be in Tile Mode. When using this control, the DrawItem gives e.bounds which are clearly bounds of largeIcon view ?? When debugging to check the view it is actually set to, it says it's in Tile view ?? Yet e.DrawText draws LargeIcon view ?? ......... Edit: ................. This seems on...

On Windows Mobile while on a phone call how do you play an mp3 file so that the other party can hear it?

I'd like to be able to pre-record a message in a wav or mp3 file, then make a phone call and play this message to the other party when they receive the call. Is that possible? ...

Experiences with IKVM.NET

Is IKVM.NET a good way to use Java Code or Java Libs in .NET applications? Has anybody experiences with this tool? Are there alternatives? Are there possibilities to call Java functions/code in COM-based applications like Visual Basic 6 or Classical ASP? ...