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# > january 2005 > threads for friday january 21

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

Visualizing tool for C# code? Like UML.
Posted by Gustaf Liljegren at 1/21/2005 10:57:15 PM
I've been working on a home project in SharpDevelop for a while now, and it's getting hard to overview now. It would help if I had a tool in which I could feed the whole C# combine/solution file (linked with all other project files) and get out nice illustration of all the classes, and their...more >>

Comparing 2 objects
Posted by scott at 1/21/2005 10:40:11 PM
hi all, in c++ i could overload an == opperator and then using a template class i could compare the 2 classes using the overloaded opperators and you did not have to tell the template what class you were dealign wtih. in c# iv got a class that has overloaded opperators. later on i them come to ...more >>

release objects
Posted by mamin at 1/21/2005 9:31:32 PM
In my code I'm creating a file and then I need to delete it.But while deleting, it's appear system error that some process is using my file and it's impossible to delete it.I was trying to release all objects using this file but without any result.Is there any method to release all objects using ...more >>

Variable in a label name?
Posted by Tinus at 1/21/2005 7:41:58 PM
Hello, I want to do the following: I have 10 labels on my form, called Label0 to Label9. Now I want to change the Text property of all the labels at once, e.g.: for (int i = 0; i < 10; i++) { Label(i).Text = "Hello, this is label: "+i.ToString(); } Now, ofcourse this won't work....more >>

Newbie object design questions
Posted by CDX at 1/21/2005 7:27:09 PM
ok, so I'm new to C#, but have some experience with objects. I'd be real grateful to anyone with some help on the things below. So I've got some objects I've created that calculate P&L numbers and some other objects that know how to summarize those numbers up. What I'm having conceptual p...more >>

regex guid tester
Posted by Greg Merideth at 1/21/2005 6:08:24 PM
I came up with this to test strings passed into a checking method to see if the guid being passed in (regular 128 bit windows registry GUID) is valid. So far it seems to handle most errors thrown at it but today during a test, a bracket "}" passed through the method as a valid guid so I w...more >>

Day number question
Posted by Zach at 1/21/2005 4:50:57 PM
Is there a built in method to estabisch the day number? Could you please give an example? ...more >>

C# to Java Interoperability
Posted by Larry at 1/21/2005 4:39:40 PM
What are some people doing to provide interoperability between C# and Java (on Windows)? What kind of samples are there available? I want my C# code to call a Java Class (on Windows). *** Sent via Developersdex http://www.developersdex.com *** Don't just participate in USENET...get re...more >>



System.Globalization.DaylightTime not working
Posted by Mike at 1/21/2005 3:44:59 PM
Hoping someone can help. System.Globalization.DaylightTime dt = TimeZone.CurrentTimeZone.GetDaylightChanges(2005); DateTime sd = dt.Start; DateTime ed = dt.End; When I run this piece of code, sd and ed both = '1/1/1' Thanks in advance, Mike ...more >>

Abstract Class versus Private Constructor
Posted by Andrew Robinson at 1/21/2005 2:54:41 PM
I need to create a shared static field for use within a number of different classes. Which one should I be using or are they all really the same thing? public class Widget { private Widget() {} public static string DataField = string.Empty; } versus public abstract class Widget...more >>

Equivalent of GetPrivateProfileString equivalent in C#?
Posted by Germic at 1/21/2005 2:40:08 PM
Does C# has an equivalent of the 'C' GetPrivateProfileString? or is the only way to get similar features to read from an INI file is to do a DllImport on Kernel32.dll? Thanks ...more >>

checking for number
Posted by Servé La at 1/21/2005 2:24:00 PM
Is there a standard method to test if a string has a double value in it without using an exception? The only method I find is using Double.Parse(str), but this throws an exception which is essentially just another goto in your code preventing structured programming :) ...more >>

CustomPropertyDescriptor AND BrowsableAttribute problem
Posted by Polo at 1/21/2005 2:14:31 PM
Hi, I have a Custom ExpandableTypeConverter (that show the property of a object readonly) Some properties of this sub object have the Browsable(false) attribute but in the PropertyGrid these properties are showed. public class Test { //.... [TypeConverter(typeof(ReadOnlyExpan...more >>

How do you make one dotnet exe talk to another dornet.exe like a dotnet dll?
Posted by GG at 1/21/2005 1:49:53 PM
Currently we have clientMail.dll in dot net. All the dot net exes use it to send e-mail. However, the above will not work with mcafee 8 unless adding into the exceptions all the apps exe. I would like only to make a clientMail.dll to exe so I can only add one exception to the list I can add ...more >>

Writing html files
Posted by guy at 1/21/2005 1:11:51 PM
Does .NET have a class or set of functions that facilitate the creating and writing of html files? I have been creating files in streams and constructing html strings and writing them out but it seems that a class could facilitate this better. Thanks ...more >>

Custom formatter creation
Posted by Nadav at 1/21/2005 1:11:04 PM
Hi, I am trying to create a custom formatter ( such as the binary formatter ), I can't figure out where do I bind the input Data Stream with the SerializationInfo object info how should i create the association? I couldn't find any sample explaining how to create custom formatters... Any po...more >>

Which operation would cost more?
Posted by at 1/21/2005 12:47:03 PM
Consider the following: I have a socket server that converts the incoming data to a= string. Each reception of data is to be stored in a new row of= a dataset. Is it cheaper (in the sense of system resources) to store= everything into a single string, pass the string back to my= main(...more >>

Single Application Instance Forcing, and subsequent message sending
Posted by Jonathan Rea at 1/21/2005 12:19:59 PM
Hi, I have found the code below to detect if a process is already running. This seems to work well, but then how do you sent the main program class in process 1 messages about the command parameter info of process 2. Thanks, Jon private static Process RunningInstance() { Process ...more >>

object calling outside method
Posted by Pujo Aji at 1/21/2005 12:17:40 PM
I have a problem with an object calling outside method: Forexample in the main part I have an object and the object will do = something time independent, and after it is finished working it should = call outside function. How can I do that? public static void Main() { mycls m =3D ...more >>

ArrayList.indexOf(self-defined class)
Posted by paulyip at 1/21/2005 12:15:43 PM
I've create a private class and an arrayList of it. I found that I can't us indexOf the check whether they are the same. Is it true that they are in different location in the memory, that I have use a for loop to compare the value of them (i.e. add an method CompareVenueID() in class and loo...more >>

DropDownList
Posted by Mike D at 1/21/2005 11:34:13 AM
I've databound the dropdownlist. How do I prevent it from selecting the first item in the list during page load. ...more >>

C# practice projects
Posted by Jon Smith via DotNetMonster.com at 1/21/2005 11:30:40 AM
Hi all, I've recently completed studying two C# books. I'm now looking to keep my knowledge of C# sharp (excuse the pun) by doing practice projects. Can anyone tell me where I might find C# projects to do? Is there a web site that publishes them? Any help would be greatly appreciated. Regar...more >>

Starting a windows app from a service
Posted by Steve Long at 1/21/2005 11:21:16 AM
Hello, I hope this question isn't too fundamental. I have a feeling it is. I'm trying to start a winform app from a windows service written in C#. I created a class and used it from a windowsforms application and all was well. But when I try to use the class in the OnStart method of a windows s...more >>

Process.WaitForExit doesn't apply
Posted by Pujo Aji at 1/21/2005 11:10:09 AM
Hello, I have a program that run notepad like this: ProcessStartInfo myP = new ProcessStartInfo(); myP.FileName = "notepad.exe"; using(Process myp = new Process()){ myp.StartInfo = myP; try{ myp.Start(); myp.WaitForExit(); Console.WriteLine("alles guttes");...more >>

accessing mySQL from asp.net
Posted by Phil Townsend at 1/21/2005 11:00:29 AM
Are there class libraries available for accessing MySQL DBs from .net? Coming from a SQL Server/MS shop this is a little new to me. Any other resources would be helpful as well... thanks! *** Sent via Developersdex http://www.developersdex.com *** Don't just participate in USENET...get rew...more >>

how to force Thread.Abort() to Abort ?
Posted by Andy Fish at 1/21/2005 10:39:06 AM
Hi, I am using COM interop to invoke MS word from my .net app. If word pops up a dialog box, my thread obviously hangs until the dialog is answered. Here's the problem: because the app is running on a server, there is nobody there to answer the dialog, so I have another thread that calls A...more >>

Namespaces - Please explain this
Posted by GingerDeafMan at 1/21/2005 9:45:11 AM
Hi, This is ok: using System.Windows.Forms; private System.Windows.Form Form1; (the private declaration is in a class, of course) As is: using System.Windows.Forms; private Form Form1; But the compiler does not like this: using System.Windows; private Forms.Form Form1; Why...more >>

destructor behaviour
Posted by Servé La at 1/21/2005 9:39:52 AM
What are the advantages and disadvantages of opening and closing database connection in a web application in the following examples? 1: using(SqlConnection connection = new SqlConnection()) {} 2: SqlConnection connection = null; try { connection = new SqlConnection(); } finally { ...more >>

Multiple referenced dlls
Posted by Jan at 1/21/2005 8:51:02 AM
We have a VB dll that invokes a C# dll. The C# dll references 3 other dlls - one is a .NET dll, the other two are win32 COM dlls. I have a script that invokes the VB dll which in turn successfully invokes the C# dll on my development machine. Next, I tried deploying to a stage server, b...more >>

Thread with timeout, pls help
Posted by Dan Pavel at 1/21/2005 8:00:07 AM
Hi, I am kind of new in programming and I have a problem. I am getting some values through SNMP and when I don't get an answer from remote host, my refresh function keeps waiting. I cannot modify the function because is from a .dll. I need some timeout thread who can stop after 2 seconds if ...more >>

Cast From Abstract to decendant
Posted by tal_mcmahon at 1/21/2005 7:58:18 AM
hi all, if I have a class: CODE public abstract class Person { public string firstname; public string lastname; Person(string fname,string lname) { firstname=fname; lastname=lname; } } and I use it like this: CODE public class Employee : Person { public string ID...more >>

Running SQL Script from in a program.
Posted by Rich III at 1/21/2005 7:05:05 AM
Hi C# users; I am trying to run an SQL Script on an Access database. I can do it directly, but, what I would like to do is build a dll that I can call and give it the databasename and the SQLScript filename and have it return an integer for success or failure. Example: int ExecuteSqlScri...more >>

Send a file straight to printer?
Posted by trint at 1/21/2005 6:43:58 AM
How can I send files straight to a printer from my c#.net app? I also must include the margin's, trays and the stapler. Thanks, Trint ...more >>

converting c# to COM
Posted by woodworker at 1/21/2005 6:13:03 AM
I have to create a COM dll from c# to use within old code. Every time I build I get a new guid. I have tried to use the [Guid(...)] phrase before a class or interface, but the compiler won't build due to the following messages: Syntax error, ']' expected (shown after "[Guid" and before "(" ...more >>

frame at bottom left corner
Posted by Stijn Goris at 1/21/2005 4:59:08 AM
hi all, I want to show a frame at the bottom left corner. Some knows how I can do this? I know this.StartPosition = FormStartPosition.Manual but have no ideaa on how to alter the Manual parameters. Best regards Stijn...more >>

Smart Client
Posted by VishwasTrivedi NO[at]SPAM gmail.com at 1/21/2005 4:08:11 AM
Hi i have one central data base(sql server), all the information is stored on this server. i want to create Offline Smart Client so that my users can work offline. if possible please send me some example ot url thanks...more >>

listBox row colors...
Posted by trint at 1/21/2005 3:49:13 AM
Can I make my rows in listBox1 alternate colors (I'm wanting to group data)? If so, how? If not, what type of box can I use to do this? Thanks, Trint ...more >>

How to wrap a text in datagrid on web page?
Posted by PB at 1/21/2005 3:03:04 AM
How to wrap a single continous word like 'HHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHH' in dataGrid on a web page....more >>

How to check a table is created in db?
Posted by zjut at 1/21/2005 2:25:04 AM
In c#, Microsoft sql 2000, the name of db is "tc",and i want to check the table "csharp" is exist or not . if it isnot exist, create it.! ====================================== SqlCommand cmd = new SqlCommand(); connection.open(); sSQL = "...." // how to write it. cmd.CommandText = sSQL; cm...more >>

How to generate an eight digit random number?
Posted by Henry at 1/21/2005 12:37:02 AM
Hi, How can I generate an eight digit random? Can I use the staff name to generate it? May I ask is there any sample c# code to see? Thanks ...more >>


DevelopmentNow Blog