Archived Months
June 2003
July 2003
August 2003
September 2003
October 2003
November 2003
December 2003
January 2004
February 2004
March 2004
April 2004
May 2004
June 2004
July 2004
August 2004
September 2004
October 2004
November 2004
December 2004
January 2005
February 2005
March 2005
April 2005
May 2005
June 2005
July 2005
August 2005
September 2005
October 2005
November 2005
December 2005
January 2006
February 2006
March 2006
April 2006
May 2006
June 2006
July 2006
August 2006
September 2006
October 2006
November 2006
December 2006
January 2007
February 2007
March 2007
April 2007
May 2007
June 2007
July 2007
August 2007
September 2007
October 2007
November 2007
December 2007
January 2008
February 2008
March 2008
April 2008
all groups > c# > march 2007 > threads for wednesday march 14

Filter by Day: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31

Process.Start throws Access Denied Win32Exception
Posted by jk at 3/14/2007 11:48:00 PM
I am using System.Diagnostics.Process class to open a word document by call ing Process.Start("test.doc"). I am using C# as programming language. On some of the computers on running this code i get "Access is Denied" Win32Exception. What do i do to not generate this exception ? Any help hig...more >>


How to Integrate Word in Windows Application - C#
Posted by venkat at 3/14/2007 11:38:51 PM
Hi Every body I am using DSOFramer Control To host a Word Document .I am successfull to the document But One Problem i am facing 1) i want to find whether the document has been modified or not for external event like button click. 2) i want to supress the open dialog when i CTRL+Save When...more >>

Generic methods..
Posted by Ram at 3/14/2007 9:27:12 PM
Hi All, I am new to this Generics. I started with a Generic method which doesn't return any value. It worked well. Then I tried to write a generic method which will sum up the given values and return the result. This is the piece of code. private T Add<T>(T a, T b) { T c = a + b;...more >>

what encoding does system.xml.xmldocument.save(string path) use to save the xml document if there is no <?xml... in the front of the xml document?
Posted by Daniel at 3/14/2007 9:13:34 PM
what encoding does system.xml.xmldocument.save(string path) use to save the xml document if there is no <?xml... in the front of the xml document? ...more >>

Fast image processing in C#
Posted by Michael A. Covington at 3/14/2007 8:27:37 PM
Any thoughts about how to implement image processing algorithms to run fast in C#? Using GetPixel to access every pixel from a Bitmap seems to be rather time-consuming. ...more >>

DateTime.Now.ToUniversal() daylight saving
Posted by FJY at 3/14/2007 7:29:11 PM
ello, I have been using the DateTime.Now.ToUniversal() that works great until the recent daylight saving change. The server on which the application runs was patched to use the correct DST, but somehow the DateTime.Now.ToUniversal returns 1 hour more. For example, server time is 5 PM EDT, t...more >>

Lock on directory
Posted by VJ at 3/14/2007 6:03:36 PM
I want to put a lock on my App's data directory (and all subdirectories below) when my application launches, so you can't delete through explorer or any other program. How is that possible. VJ ...more >>

Case sensitivity problem in using the Contains method in ResultPropertyValueCollection
Posted by Chris Noble at 3/14/2007 6:02:42 PM
I need to check whether a particular user is already a member of an Active Directory Security Group. The following code extract works but only if the user distinguished name is exactly the same as that returned from Active Directory. For example using 'cn=' in the userdn string instead of '...more >>



VB to C#
Posted by Dave at 3/14/2007 5:26:08 PM
Could someone convert this VB code to C#: WithEvents myExp As Exp thank you -- L. A. Jones -- L. A. Jones...more >>

Simple Syntax question (i think)
Posted by Ben Daniel at 3/14/2007 4:44:23 PM
Basically what I want to know is how to return a class type (not an instantiation of a class but a class itself). For (a trivial) example, let's say I have a base class Animal and derived classes Dog, Cat & Mouse. I want a function that I can pass a food type as a string and get back the class...more >>

Outputting generic list to array
Posted by MarkAurit at 3/14/2007 4:23:08 PM
I need to output a Generic List to an array, but Ive been unable to. The list looks like: List<Employee> emp = new List<Employee>(); When I use ToArray() with it: string[] empArray = emp.ToArray(); I get the error message: Cannot implicitly convert type 'NgItIts.AD2Service.Ad2Employee[]' t...more >>

wmp.dll self-registration failed
Posted by masterej NO[at]SPAM gmail.com at 3/14/2007 4:20:47 PM
Developers, I am unable to import the WMP control into a vs.net c# app. First, the WMP library does not appear in the COM objects list automatically. When I try to import wmp.dll from the system32 folder, a "self-registration failed" message appears. Has anyone seen this problem before? I...more >>

Registry Changes not being picked up
Posted by Rymfax at 3/14/2007 4:10:05 PM
Hello, I was hoping someone could help me with a problem I'm having. I've got a C# app that uses several DLL Imports from setupapi.dll and others (Thanks again for the Help on those Willy). One import in particular is SetupDiBuildDriverInfoList(), which builds a list of potential drivers for a ...more >>

VS2005 - ConnectionString - DesignTime - Change at Runtime
Posted by Michael Moreno at 3/14/2007 3:43:25 PM
Hi, We have an app that is made of many exes (WinForms and Win32 app). All those exes share and read their DB connection string from the registry. This guarantees that all the exes use the same DB. With .Net the connection string is in the app.config file as soon as you use the design t...more >>

Filtering of BindingSource
Posted by Arlyn_L at 3/14/2007 3:19:03 PM
I have a DataTable with four columns of type Float (r1, r2, r3, and r4) connected through a BindingSource to a DataGridView. I need to filter the displayed rows as" ABS(r1-r2)>c1 OR ABS(r3-r4) > c1 where ABS is an absolute value. Is there a simple way to accomplish this while retainin...more >>

Help with form controls
Posted by Max at 3/14/2007 3:16:51 PM
Hello, I have multiple text box controls on a form, and they are named txt_Test1, txt_Test2, txt_Test3, etc. I would like to have a loop that will populate all of these controls with the text: "ABC". When I run the following: for (int i = 1; i <= TESTNUM; i++) { ((TextBox)this.Cont...more >>

ArrayLists and AddRange
Posted by t f at 3/14/2007 3:06:07 PM
Hi I have some code which does basically the following: void A() { ArrayList al1 = new ArrayList(); al1.AddRange(GetSomeNames()); //do something with al1... } ArrayList GetSomeNames() { ArrayList al2 = new ArrayList(); foreach (string s in some array) { ...more >>

Mutual exclusion for read/write - but no sync/lock for concurrent reads
Posted by illegal.prime NO[at]SPAM gmail.com at 3/14/2007 2:00:45 PM
So I have a container of objects that I don't want to iterate across when I'm modifying it. I.E. I lock on adds and deletes to the container - so that my traversals of it don't result in concurrency issues. However, what do I need to do to allow multiple threads to traverse the container wit...more >>

Shell_NotifyIcon P/Invoke
Posted by Ed Courtenay at 3/14/2007 1:50:22 PM
I need to be able to set the icon on a Notification Icon Balloon Tip (a balloon tip raised from the system tray), and I've had limited success so far. I've extended the standard NotifyIcon component (well, read disassembled using Lutz Roeder's fantastic tool and rebuilt); I've added a new ...more >>

get path to all user's documents folder
Posted by Dennis C. Drumm at 3/14/2007 1:27:02 PM
How do I programmatically get the path for the windows shared documents folder which is also the all user's document folder. Thanks, Dennis ...more >>

Owner and base
Posted by MarkJ at 3/14/2007 1:25:43 PM
him im kinda new to c-sharp... to reference up the class chain, how do i reference the super class (parent) example class mybase { protected int abc=0 } classs myclass:mybase { } class another:myclass { public another() { // how would i reference up the inherit int efg ...more >>

Trolling
Posted by Simon Tamman at 3/14/2007 1:24:26 PM
Way off topic, I know but I was wondering. I haven't visited these groups for over a year now and have just returned. When I last left I didn't note the trolling as anywhere near as bad as i've seen it in the past couple of days. My question is: a) Has the trolling got worse recently? b) H...more >>

Creating Event to Monitor a Value
Posted by randy1200 at 3/14/2007 1:23:05 PM
I have an integer value from a 3rd party control that looks something like this: MyControl.theValue I need a way to detect when the value changes. My first thought is to use an event. I could use a suggestion on how to wire the value change to an event handler function. Any thoughts? ...more >>

Is there a extension in ajax that i can use to mouseover oand copy results?
Posted by Herman Walker at 3/14/2007 1:17:13 PM
I am creating single line table columns dynamacially in and ajax UpdatePanel with text results. The results really contains a bulk of data which i put in a tooltip. The problem is that when i mouseover the column, the tooltip shows but only for 5 seconds, not long enough and you can't copy and pas...more >>

linked list with hashtable storage
Posted by Larry at 3/14/2007 1:03:15 PM
has anyone implemented a linked list with a hash table storing the data values? has anyone implemented an array with a hash table storing the data values? any examples? *** Sent via Developersdex http://www.developersdex.com ***...more >>

override GetHashCode
Posted by Andrew Robinson at 3/14/2007 11:40:50 AM
I have a class that has three properties: two of type int and one of type string. Is this the best method when overriding the GetHashCode() ? I am guessing not... any thing better? public override int GetHashCode() { string hash = craneCounterweightID.ToString() + ":" + trailerID.To...more >>

Formatted strings
Posted by Wynn Rostek at 3/14/2007 10:42:58 AM
In C# is there any way to do formatted printing like there is in C? In C, I would do sprintf(string, "%4.2f",floatvalue) to print a float value with two decimal places. I have looked around a bit, but have not run across anything like this in C#, maybe I am just missing something. Many than...more >>

Assigning Default value to Enum Variable
Posted by Lucky at 3/14/2007 8:59:57 AM
Hi guys, i was working with Enum and one Question strike, i thought it would be good idea to ask more experience guys around. the scenerio is like this : [System.ComponentModel.DefaultValue(check.None)] public enum check { No, None, yes, why ...more >>

BusyBox Revisited
Posted by jez123456 at 3/14/2007 8:43:52 AM
Hi again experts. Still having problems with the backgroundworker etc. Here is my test simulation. Form1 has a start button BusyBox has a ‘Please Wait…’ label Form2 has no controls When start is clicked, display the BusyBox with a delay. The BusyBox should also display a progres...more >>

using sql to lock, select, then update
Posted by Steve Richter at 3/14/2007 8:29:40 AM
what is the standard way of using sql in C# to increment a counter column in a shared control table? ( example: the next order number ) I would like to sql select a row in a table and lock it. Then run code that assigns the new value to a column in the row. Then sql update the column in the ro...more >>

I have a string, and I want let the first character capitalize. How to do it?
Posted by fAnSKyer/C# newbie at 3/14/2007 8:05:13 AM
Sorry for this stupid question. I am using c way s[0] = s[0] -'a' +'A' but I can't compile it. Thanks for your kind help Best wishes ...more >>

Native menu in .NET 2.0?
Posted by Sin Jeong-hun at 3/14/2007 7:47:04 AM
Can't .NET 2.0 application have a native Windows menu bar like the one on the top of the Notepad? ...more >>

Possible to set font for mail sent from app?
Posted by Josh Nikle at 3/14/2007 7:38:30 AM
i'm sending out a text-based mail from my app, and i'd like to put a table of sorts in it. i've formated my output to form rows and columns, and it looks great...in courier. can i force the mail to display in a fixed width font in the mail client, or am i just out of luck there? does anyone h...more >>

Why HTTPChannel is good over TCPChannel.
Posted by archana at 3/14/2007 7:16:55 AM
Hi all, I am confuse at selecting httpchannel and tcpchannel. I read on MSDN that ' HttpChannel is a good channel to start with because in some scenarios it can be used through firewalls without opening a port; Can anyone tell what exactly it means?. As for communication there has to be por...more >>

Time zone
Posted by Sehboo at 3/14/2007 6:52:45 AM
We have a c# application (with about 100 forms, and 300+ tables on sql server). We have several customers who use that application but everybody gets the copy of the database. Structure of the database is same, but with different data. All the databases reside on the same server/same instan...more >>

How to retrieve the border colour of a TextBox?
Posted by Dan Soendergaard at 3/14/2007 6:43:18 AM
Hi, I'm writing my own control and I would like it to integrate nicely into the rest of my application, which uses the standard controls primarely. I therefore wanted my control to use the same border colour as the rest of the controls, ex the TextBox control. After trying all the colours in ...more >>

Comments on this C# Article Wanted
Posted by Reporter at 3/14/2007 5:55:32 AM
Your comments and feedback will be appreciated. This article is about the files in a simple newly created C# Express Windows Project: http://ezinearticles.com/?Visual-C-Express---File-Types-(5th-In-A-Series)&id=483933 ...more >>

C# project after VS.NET 2005 SP1
Posted by uupi_duu NO[at]SPAM yahoo.com at 3/14/2007 5:51:52 AM
Hello, Has VS.Net 2005 SP1 changed C# WebApp's project files? Can't open it anymore without installing SP1. Anyone know what is behind this? Cheers, ...more >>

ListBox and Save Changes...
Posted by Diogo Alves - Software Developer at 3/14/2007 5:39:30 AM
Greetings to you all I have a listbox with some data loaded from the database... When I select each record, it will fill a form that I have in the same window... What I wanted is that when I change something on the form, the var bNeedSave = true and if I change the record without saving...more >>

OnMove for a UserControl
Posted by Joachim at 3/14/2007 3:31:32 AM
How can I get an OnMove message for a UserControl?...more >>

move contents of inbox folder to another folder
Posted by Mike P at 3/14/2007 3:21:13 AM
I am trying to move the contents of the inbox folder into a folder for archiving. I have found a few examples on MSDN (eg http://msdn2.microsoft.com/en-us/library/bb206765.aspx), but I don't appear to have access to all the objects that are being used in this example. Has anybody successfully ...more >>

Label printing in c#
Posted by Jlo at 3/14/2007 1:06:10 AM
Hi Gurus, I have a win forms appl in c#. I need to print out labels. What is the best way to do it. I dont want to write the labels to an RTF document and format it by using complicated Drawing functions. http://office.microsoft.com/en-us/templates/TC011832781033.aspx?CategoryID=CT10146767...more >>

Save the state of a SplitContainer
Posted by newscorrespondent NO[at]SPAM charter.net at 3/14/2007 12:20:18 AM
I want to save the state of a splitcontainer when an application ends. I also save the form state. The SplitContainer does not seem to have a well defined place to put intiialization and termination code. I have tried to use my first splitter moved event to set the splitter position but I am...more >>


DevelopmentNow Blog