.net

How to create a directory using StreamWriter?

Is it possible to create a directory using StreamWriter? ...

.NET projects build automation with NAnt/MSBuild + SVN

Hi everyone, for quite a while now, I've been trying to figure out how to setup an automated build process at our shop. I've read many posts and guides on this matter and none of them really fits my specifics needs. My SVN repository is laid out as follows \projects \projectA (a product) \tags \1.0.0.1 \...

Memory management - should I worry about resizing a temporary array of long-lived objects within a state machine?

Garbage collection in .NET leads many to believe that lightweight objects can be treated as temporary. This seems especially true of arrays that hold object references to objects that are instantiated outside of the context of the array initialization. Consequently, it would seem that it should not really matter if a new array is in...

What are the latest and greatest books for .Net development?

One I would definitely recommend is: Architecting Applications For The Enterprise by Dino Esposito Anybody else read any good ones lately? ...

SFTP Libraries for .NET

Can anyone recommend a good SFTP library to use? Right now I'm looking at products such as SecureBlackbox, IPWorks SSH, WodSFTP, and Rebex SFTP. However, I have never used any SFTP library before so I'm not sure what I'm looking for. If anyone has used these before, is there any reason why I should go with product "X" over "Y"? Thank...

Linking to a static lib that links to a static lib

I have a (managed/unmanaged C++) winforms app that links to a static library. That library links to another static library. When I do a Rebuild on the Winforms project, Visual Studio 2005 attempts to rebuild the references static library, but does not rebuild deeper than one level. This causes me to have to manually rebuild the leaf proj...

How can i create a Gridview to make Ajax calls to webservice .

I Have a Gridview . I wanted to display data from Webservice via Ajax calls in ASP.net Please ,let me know the solution for this. Thanks in Advance. ...

.NET Garbage Collector - Terminal Services

Is there one Garbage Collector for an entire system one instance of a garbage collector for each user that is logged in one garbage collector for each running .NET application Or is it none of the above (please explain)? ...

See All Files Changed in Multiple Changesets in VSTS

Does anyone know how get a listing of all files changed in multiple changesets in Visual Studio Team System 2005? I basically want to see a listing of all files changed from the start of a development effort till the end. ...

.NET Optimized Int32

While reading through the 70-536 training kit, it states: The runtime optimizes the performance of 32-bit integer types (Int32), so use those types for counters and other frequently accessed integral variables. Does this only apply in a 32 bit environment? Does Int64 take over in a 64 bit environment, or is Int32 still th...

Started Process from .NET but RedirectedStandardOutput doesn't support UTF-8

I am trying to call php's HTML purifier from .NET using this code: Process myProcess = new Process(); myProcess.StartInfo.FileName = "C:\Path\to\php.exe"; myProcess.StartInfo.Arguments = "C:\Path\to\purify.php"; myProcess.StartInfo.UseShellExecute = false; myProcess.StartInfo.RedirectStandardOutput = true; myPro...

Identify scanner(s) attached to the computer?

The application I'm working on is using a scanner, which may belong to one of a few types. I need to identify the attached scanner(s), give an option to select a default scanner from those attached and also change this selection whenever required. So far I came up with this solution: ManagementObjectSearcher search = new System.Managem...

Web service array size limit

My web method kept faulting and investigations eventually revealed the following: The formatter threw an exception while trying to deserialize the message: Error in deserializing body of request message for operation 'SendFirmware'. The maximum array length quota (16384) has been exceeded while reading XML data. This quot...

Does anyone know a better alternative to MS Excel's Solver?

My company has to crunch a lot of data and part of the process involves running the solver and plotting a graph through resulting data points. Obviously there is a lot of copy and paste involved and the whole process is shaky, error prone and all round cluster-fudge. I was wondering if there was an alternative to the solver that can be u...

Help with streams (.net)

I have a stream object, and I want to create and output xml using some kind of xml stream, based on data in my input stream. I haven't done much work with streams, so I am trying to learn how to do this as efficiently as possible. The idea is that I do not want to load the entire input stream in memory, then create the entire output st...

WIA.DeviceManager.DeviceInfos.Count = 0. Why?

I'm trying to identify the scanners attached to the computer. One of the possible solutions is to use WIA (Windows Image Acquisition Automation Library). These were my actions so far: Download wiaaut.dll Copy it to system32 Register it with "regsvr32 wiaaut.dll" (successfully) Add reference to my project in Visual Studio.NET Check tha...

What is the difference between an Interop and a RCW (Runtime Callable Wrapper)?

Is it just terminology? ...

How to loop through all the properties of a class?

I have a class. Public Class Foo Private _Name As String Public Property Name() As String Get Return _Name End Get Set(ByVal value As String) _Name = value End Set End Property Private _Age As String Public Property Age() As String Get Retur...

How to filter or find properties based on attributes

I have a class as follows Public Class Foo Private _Name As String <ShowInDisplay()> _ Public Property Name() As String Get Return _Name End Get Set(ByVal value As String) _Name = value End Set End Property Private _Age As String Public Property Age() As St...

How to copy value from class X to class Y with the same property name in c#?

Suppose I have two classes: public class Student { public int Id {get; set;} public string Name {get; set;} public IList<Course> Courses{ get; set;} } public class StudentDTO { public int Id {get; set;} public string Name {get; set;} public IList<CourseDTO> Courses{ get; set;} } I would like to copy value from...