.net

How To Add A SyndicationElementExtension To A SyndicationItem

Using the .NET System.ServiceModel.Syndication classes... I would like to add a new SyndicationElementExtension to a SyndicationItem that will export the following XML: <media:thumbnail url="http://www.foo.com/keyframe.jpg" width="75" height="50" time="12:05:01.123" /> Something along the lines of: syndicationItem.ElementExtensions....

What is the best way to debug performance problems?

I'm writing a plug-in for another program in C#.NET, and am having performance issues where commands take a lot longer then I would. The plug-in reacts to events in the host program, and also depends on utility methods of the the host program SDK. My plug-in has a lot of recursive functions because I'm doing a lot of reading and writing ...

Random Access by Position of Key/Value Pairs in .NET (C#)

I am currently developing a program that uses C#'s Dictionary container (specifically, SortedDictionary). This container works very well for my purposes except for one specific case because I want random access. Specifically, I am generating a random position using a pseudorandom number generator and I need to be able to access that va...

What initializes the security context in forms authentication?

If FormsAuthenticationModule detects forms authentication ticket in the request, it automatically creates security context by initializing HttpContext.Current.User property. This happens during Application.AuthenticateRequest event. Assuming we log in user via CreateUserWizard control, then by the time CreatUserWizard's ContinueButtonCl...

Is there anyway to assign an index to a control in the WinForms or WPF designer?

I remember VB5 (and all the horrors in it), but one thing I liked about it was that I could set an index on a control in the properties window in the designer. Are there any way to do something like this in WinForms, the WPF designer or XAML ? ...

Added ( to CreateUserWizard control ) additional wizard steps after CreateUserWizardStep and CompleteWizardStep, but they don't get displayed

Hello, I'd like to add ( to CreateUserWizard control ) additional wizard steps after CreateUserWizardStep and CompleteWizardStep, but when clicking on ContinueButton in CompleteWizardStep, instead of being forwarded to next wizard step, nothing happens! What am i doing wrong? thanx EDIT: <asp:CreateUserWizard ID="CreateU...

.NET Framework support for multicore hardware

I've been tasked to write a high performance, high availability service that will run on a multicore box. Do I need to make use of Task Parellel Library to really leverage a multicore server or will the service automagically run faster if I throw more hardware (cores) at it? Does the .NET framework provide the magic for me under the co...

Sparse Multidimensional Array or Matrix Libraries in .NET

Hi, I have a need for a sparse matrix in up to 4 dimensions in a .NET application. The size of the matrix (if represented as a .NET Array) would potentially top 400MB. The array is likely to be very sparse, and I need to be able to instantiate and dispose it very quickly (although that's not a no go). I'm therefore after a sparse array...

How can I implement a formula factory?

First the requirements: By management requirements, I can't use open source code. I need the users to define their own formulas for a project. My users don't know how to code. The formulas need to be saved somehow, and being read later. I need to debug the formulas written, so I need to be able to see and understand them. The formulas ...

Is there a way to get entity id-field's name by reflection or whatever?

Hi I am trying to get the ID field name (property name) of an entity, is it possible? User user= new User(); //User is an Entity string idField = ??????? //user.UserId ...

Parallel Extensions Equivalent in Java

I have some experience using parallel extensions in .Net development, but I was looking at doing some work in Java that would benefit from an easy to use parallelism library. Does the JVM offer any comparable tools to parallel-extensions? ...

Buttons Enabled Property not Working Properly

Hi all, I am creating an Windows Application. I have two buttons. I have written the following code snippet. frmRb obj = new frmrb(); private void btnPd_Click(object sender, EventArgs e) { btnCancel.Enabled = true; obj.btnRtn.Enabled = true; } private void btnCancel_Click(object sender, Ev...

How to extract Vista file tags?

Vista introduced tags for the files. But how to extract these tags, let's say in .NET? ...

Why MDI parent form reset the Z indice of child forms when it is focused?

This is a WinForm application question in .net. It is about MDI form. I have an MDI form (ParentForm), in which I can create many instance forms of ChildForm. I create two ChildForm, named, cf1 and cf2 one by one. So, cf1 will have a Z index lower than cf2 and cf2 will be on top of cf1. Then I switch to some other form, meaning ParentF...

libevent, windows and .NET programming

I experiment with a lot of open source software and I've noticed a fair amount of server type applications in the open source world use libevent to facilitate event-based processing rather than spawn multiple threads to handle requests. I also do a lot of .NET programming (it's my core job function), and I'm interested in learning how l...

How can I check that a WCF host is available before I use a channel from a client?

I am creating a windows service that starts a number of slave processes. In each of these slave process I start listening on a named pipe for message from the master process. I currently have the situation where the master process calls a slave via a named pipe before the slave is fully started and starts listening on the named pipe. ...

Drawing a line in Winforms

Hi, I am having trouble drawing a line within a group box in a simple windows form. here is my code: ==================================================================================== public partial class Form1 : Form { public Form1() { InitializeComponent(); } ...

Trying to read in some command line arguments for a console application

Hi folks, i've got a pretty simple .NET console application. I wish to pass in some command line arguments ... nothing tough there. Now, the kicker is, i usually have a LIST of items i wish to pass in, for one argument. In this case, a list of files. I'm not sure of the best way to do this. eg. myapp.exe files=aaa.txt,bbb.txt,ccc.txt ...

Return value of process

How can I get the return value of a process? Basically I'm ShellExecute()ing a .NET process from a DLL (in C++). The process does its task, but now I want to know whether it succeeded or failed. How to do that in WinAPI or MFC? ...

C# - How to pupulate a .net DataGridView programmatically?

I need to populate a .net DataGridView from a collection physically (without data binding) in C#. That is, I should use foreach loops and iterate through the collection while creating a row for each object and a cell for each property. I have created the columns in design mode. Now I need to create rows dynamically. How to do that? ...