.net

ASP.NET MVC/jQuery: Inplace Editing

Hello, I want to do inplace editing where I have regular text (coming from a Model) with an edit button next to it. When the edit button is clicked, I want a editable textbox to appear where the regular text was, and then commit a change via AJAX. I already solved how to commit, but I don't know how to place the editing control accurate...

Deploying C# (.NET 2.0) application as a portable application?

Hello there, Is it possible to deploy a .NET 2.0 application as a portable executable? So that my program can be ran in a Flash Disk without the .NET Framework 2.0 installed in the target machine. Or maybe is it possible to distribute my program with the required .NET DLLs, so that no framework installation is necessary? I know that th...

Listing and terminating processes in .Net

How can I list and terminate existing processes in .Net application? Target applications are 1) .Net applications, 2) they are instances of the same executable 3) they have unique Ids but I don't know how to get this information from them, 4) they are spawned externally (i.e. I do not have handles to them as I don't create them). I want...

overlaping images using GDI+ (C#)

Hi all, I'm trying to write a webApplication that holds two png images- big one and smaller one, I need to use the bigger one as a base and place the smaller one on it in a specific posiotion, the smaller one has transparent areas so it adds information to the base picture. I'm using GDI+ with C#, but I managed only to upload one pictur...

What is your favorite date and time format in a file name?

This is a somewhat subjective question, and not very important in the big scheme of things, but something that yet annoys me regularly. There seems to be no self-evident way to put a timestamp in a file name. Objective issue is that timestamps in file names should be sortable. But .NET sortable date formats like "s" ("yyyy-MM-ddTHH:mm:...

How do I get the current published version in a .NET application?

I want to be able to display the current version of a .NET application that I have deployed using the publish wizard. There is a nice option to automatically update the version number every time I publish my application. I found another question(Automatically update version number) that had this to get the current version. Assembly.Ge...

Is there Anyone who Successfully Implement UI Test Automation Regime using Microsoft UI Automation?

I am looking for an Automated UI test framework/ software tool. In the past I have been using TestComplete, and although it's a good piece of software, but the concept of GUI test automation was deemed to be sufficiently difficult that I wrote a few posts to complain about it. One of the problems with third party test automation tool i...

Does a WCF self hosted service handle more or less load than the IIS hosted option?

Does the hosting option affects the amount of requests a WCF service can handle? ...

Disable expanding after doubleclick

Hi, Is there any way I can disable expanding TreeNode after doubleclick?? Thanks ...

Getting extra HEX bytes when concatenating data files.

I'm concatenating data files, but the problem is that I'm seeing some extra bytes where the files are joined. The new file has extra bytes. I had thought this was maybe a problem with encoding. Here are the methods that I've tried to use to concatenate the files. The first example I'm getting extra 0xA0 0x00 bytes. Dim inputfiles(...

How to SELECT a dropdown list item by value programatically

How to SELECT a drop down list item by value programatically in C#.NET? See PIC ...

Which .NET class parses a multiple HTTP cookies string into a CookieCollection or CookieContainer?

I am sure it already exists somewhere, just can't find it. ...

From VB6 to VS 2008 (C# or VB)

I've been developing solely for the web for more than 6/7 years now, and before that I developed for about a year on Visual Basic 6 (I was pretty comfortable with it at the time) and for one or two months on C# (I forgot most of what I had learn though). The thing is I've some ideas for some small desktop applications, I thought of deve...

Winform toolStrip Status Label shows nothing: is this a bug ?

Have an instruction like this: this.toolStripStatusLabel1.Text = this.toolStripStatusLabel1.Text + "; OS=" + System.Environment.OSVersion.ToString(); If I concatenate OS with something that is more than 10 characters text is blank instead of being truncated. Is this a Bug ? ...

Is there a way to poll a socket in C# only when something is available for reading?

I'm wondering whether there is a way to poll a socket in c# when only one of the conditions (data is available for reading) is satisfied, I'm aware of the socket.Poll method but this can return true if any number of the 3 conditions specified returns true as specified here: MSDN: Socket.Poll ...

PictureBox question

Using C#.Net On my form i have a button that opens a dialog which allows a customer to select a picture, when the ok button is clicked the picture should be visible in the ultrapicture box control on the form..Not sure how to achieve this or if its simple a property to be set, any ideas ? ...

Limiting .NET Class to single object instance on computer boundary => "inter-process singleton"

I want to have one object of some .NET class used by multiple processes on same computer. Having Application domains, it is not easily possible to move across that boundary, but memory-mapped files in .NET 4.0 should ease that task in some way. Until .NET 4.0 comes in final release... Is it possible to make some kind of "inter-process ...

Resolving the metadata token of a generic type parameter

Is there any way the .NET 4.0 (or earlier) reflection API to resolve a generic type parameter? See the two lines after my ArgumentException comment for my current attempt. [TestMethod] public void TestGenericParameterTokenResolution() { Type genericParameter = typeof(List<>).GetGenericArguments()[0]; Assert.IsTrue(genericParamet...

Using jEditable with ASP.NET MVC (POSTing)

Hello, I understand that with jEditable (http://www.appelsiini.net/projects/jeditable) you can do in-place editing and POST the changed information to a URL. My ASP.NET MVC view is displaying a bunch of Model information which I'd like to make in-place editable. Currently, I have two views - one text representation and one edit view in...

What makes instance members thread-unsafe vs public static?

So we've all seen the Threading notification on MSDN for many available generic objects: "Public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe." My question is, what is it about being an instance variable vs a public static makes it unsafe? ...