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# > february 2005 > threads for friday february 11

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

Emergency:
Posted by Shawn Zheng at 2/11/2005 11:57:44 PM
Please help: How do I send Email in ASP.NET? SmtpMail.Send give error of "could not access CDO.Message". what CDO is? Shawn ...more >>


Question about value types
Posted by Zach at 2/11/2005 10:16:03 PM
When it is being said that, "value types are created on the stack [no problem with that] or inline [what is being said here?] as part of an object". If a value type is created in an object, and that object is being called, the value type in that object, is still created on the stack, I would say...more >>

CustomAttribute: problem again!
Posted by julien at 2/11/2005 10:03:16 PM
Hello, I'm sorry to send another message about the custom assemblies. The examples I find online don't help to find out what is wrong in my file. In a dll: [assembly:AssemblyDependencies( "ee","1.0.0.0","aa", "1.0.0.0")] This custom attribute: [AttributeUsage(AttributeTargets.Assembly)] ...more >>

C# Jobs on the web?
Posted by Keith Smith at 2/11/2005 10:01:34 PM
How can I get some C# projects (jobs) through the web? ...more >>

Crystal Reports again
Posted by Alberto at 2/11/2005 8:42:47 PM
When the user print a report from the crystal reports preview, the report it's full of strange characters but if we export it to word or pdf and then we print it, we can read it fine. Why? Thank you ...more >>

Is there any .net aware website besides IIS?
Posted by Karl at 2/11/2005 8:11:03 PM
Hi all, I installed the VS .NET on my home computer which has XP Home. It does not have IIS. But I want to practise asp.net which requires a web server. Is there any third party .NET aware server available? Thanks, ...more >>

Grouping data on the fly at crystal report
Posted by Jonathan Woods at 2/11/2005 7:03:26 PM
Hi there, How do i handle grouping same level of data at run time? or any idea? user can view data according to their selection group on the windows form. for example: In customer table, (Group by City) or (Group by Country) ----------- The following code does not compile... FieldDefini...more >>

Convert Dec06 to Dec 2006
Posted by Joe at 2/11/2005 5:42:34 PM
I can't seem to get this to work. Everything I try always seems to convert it to Dec 06 2005. I tried using DateTimeFormatInfo and setting YearMonth = "MMYY" and then doing DateTime.Parse(mydate, cultureinfo) ...more >>



Need Input from Threading Guru
Posted by Phillip N Rounds at 2/11/2005 4:03:22 PM
I'm cursed by being a linear thinker. Anyway, I have an application (service) where I can't decide on the appropriate way to implement threading. I have a timer which periodically initiates Process A Process A does something, then has to call N instances of Process B, where N varies from ...more >>

Killing the processes.
Posted by Saurabh Sharma at 2/11/2005 3:59:56 PM
Hi I have made a Windows Form and in it few calculations and processos are running. When i close the form the process continues to run until that particular function in finished. I cant use Environment.Exit 0 as they and in the subform and i want to load the main form when i close that. Plea...more >>

Easy Friday Question
Posted by Mike D at 2/11/2005 3:49:43 PM
I have a login webform page built in C#. How do I set the cursor into the username Text Box when the page is first loaded. This way the user doesn't have to mouse click into the field and then start typing. Thanks Mike ...more >>

registering assembly upon deployment
Posted by Nikhil Patel at 2/11/2005 3:31:56 PM
Hi all, I am creating a setup and deployment project for a signed assembly and need to register it when it is installed. How can set it to register when it is installed? Thanks. ...more >>

net send using c#
Posted by SenthilVel at 2/11/2005 3:15:40 PM
how to send message using net send in c#?? ...more >>

Displaying a form as top, and modal, but without ShowDialog
Posted by Paul Aspinall at 2/11/2005 3:15:26 PM
Can anyone advise how to display a form on top, and modal, without using ShowDialog?? Thanks ...more >>

Sealed classes and constructors / deconstructors
Posted by Mark Rae at 2/11/2005 3:15:20 PM
Hi, Since sealed classes can't be instantiated with the new keyword e.g. CClass objClass = new CClass(), does this mean that they don't have constructors / deconstructors or, if they do, that the code inside the constructor / desconstructor will never run? Mark ...more >>

User GUID
Posted by Jeff Johnson at 2/11/2005 3:15:02 PM
I'm making the move from classic ASP to .NET. I've got a getUserGUID method that I've rewritten in C#. I used to use includes to access this function. I've created a new class with this method, but I keep getting an "The type or namespace name 'Request' could not be found" error. Here'...more >>

How can I create dinamic columns in Crystal Reports....
Posted by Sergiu Cojocaru at 2/11/2005 3:02:18 PM
Ia have a query that returns a variable number of columns. How can I create these columns in Crystal? ...more >>

Color of a single row of a data grid
Posted by Saurabh Sharma at 2/11/2005 3:01:35 PM
Hi I want to change the color of the single row of a data grid. Can some body tell me how it can be done Regards Saurabh Sharma ...more >>

folderbrowse
Posted by laimis at 2/11/2005 3:01:33 PM
Ok guys, this is driving me CRAZY!!! You all probably know a control called FolderBrowserDialog that is available in windows forms. Well, I placed it in the form and everything was working fine during testing. Couple days of development later, when I click a button to invoke a dialog, it ...more >>

How to get the Character value when using KeyPress?
Posted by Keith Smith at 2/11/2005 3:01:30 PM
How can I get the character value of a KeyPress? I tried this... MessageBox.Show(e.KeyChar.ToString()); ....but it only gives me the actual character itself. For example, if the user presses "Enter" I need the value of 13 returned to me. Keep in mind that this is a KeyPress and not a Ke...more >>

Overriding private interface property?
Posted by Joel at 2/11/2005 2:53:17 PM
Why does this work: using System; namespace ConsoleApplication1 { class Class1 { [STAThread] static void Main(string[] args) { DerivedClass d=new DerivedClass(); d.MyProp=10; Console.WriteLine(d.MyProp.ToString()); } } public class DerivedClass : BaseClass,...more >>

generating database script
Posted by Ollie Riches at 2/11/2005 2:26:04 PM
Is it possible to generate the t-sql script for a database schema and the data from .Net(C#) at all? Cheers Ollie Riches ...more >>

what am I doing wrong with my Process.Start?
Posted by Mark Reed at 2/11/2005 2:07:38 PM
I am trying to have a button that brings up the cmd prompt and then does a DIR listing. I am using: private void button2_Click(object sender, System.EventArgs e) { System.Diagnostics.Process.Start("cmd.exe","dir"); } It does everything except the dir. *** Sent via Develope...more >>

Help with Custom Control
Posted by Keith Smith at 2/11/2005 1:54:55 PM
When making a new custom control, is there a way to work from a "template" of another control? Instead of adding a control to the UserControl.cs? ...more >>

Check permissions where the files are excuted
Posted by Mikael Syska at 2/11/2005 1:41:44 PM
Hi, Any one got a Example where I can test if i'm allow to run my program and print a message to the user if there are incifient permissions on the path were its executed? So I dont get a .NET error when its on a UNC path! but so I can make my own errors and try to guess what wrong, and g...more >>

Bug in the framework?
Posted by Wayne at 2/11/2005 1:35:49 PM
Running V1.1 with latest SP (1 right?), on Windows XP. I have the following in a web service: [WebMethod()] public Double Factorial(int n ) { double n1 = 1; double result = 1; while (n1 <= n) { result = result * n1; n1 = n1 + 1; } System.Threading.Thread.Sleep(10000); ...more >>

How to run a console application without showing the console screen?
Posted by Tee at 2/11/2005 1:04:19 PM
Hi, I am using System.Diagnostics.Process to start a console application, but I don't want the user to see a "black" screen when the console application is running, how can I hide it? Thanks, Tee ...more >>

TcpClient close() method socket leak
Posted by Daniel at 2/11/2005 1:03:58 PM
TcpClient close() method socket leak when i use TcpClient to open a connection, send data and close the TcpClient with myTcpClientInstance.Close(); it takes 60 seconds for the actual socket on the client machine to close per my network app the computer fills up w/ thousands of these [System...more >>

richTextBox access from a function
Posted by Dave at 2/11/2005 1:01:13 PM
I have a button on a form that calls a function. The function does some stuff and then I want it to write the results to a richTextBox. The problem is the code; richTextBox1.Text += "Results"; Gives me the error, 'Form1.righTextBox1' denotes a field where a class was expected. How do...more >>

Writing a C++ DLL in C#
Posted by Dan Diephouse at 2/11/2005 12:58:21 PM
We are looking at a print driver by SoftCopy which allows can print to images. The neat thing about it is that it has hooks which you can tie into. It defines the hooks in C++ code though and I remail pretty ignorant about using MS VC++. They define a skeletal DLL like so: (http://www....more >>

How to search word in a richtextbox?
Posted by chrisben at 2/11/2005 12:51:02 PM
Hi, Is there a quick easy way to search a text for words in richtextbox? I would like to make it work as a word document, as the having Find, Find Next by right click the richtextbox. THe words will be highlighted and the focus wil move to that part of ricktextbox after each search. Any...more >>

List of SQL-Server Databases
Posted by Matthew Smith at 2/11/2005 12:43:25 PM
Is it possible to get a list of SQL-Server databases if I know the server, using C#? I want to provide a drop-down list of them. Or is there a mechanism for selecting a database?...more >>

Redim Preserve Array
Posted by LP at 2/11/2005 12:29:09 PM
Hello, What is C# equivalent of rediming an array and preserving exciting elements. VB.NET syntax looks something like this: ReDim Preserve myArray(5) Thank you ...more >>

C# 2.0: Showing Nullable Types in PropertyGrid
Posted by Riko Eksteen at 2/11/2005 11:51:34 AM
I would like to display nullable types in the propertygrid control. This usally requires a TypeConverter being implented for the specific type. For example, a BooleanConverter class will allow a True-False dropdown list to be displayed in the propertygrid. Beta 1 of C# 2.0 doesn't have type...more >>

How do you get path and filename from a SaveFileDialog ?
Posted by rkuleta NO[at]SPAM hotmail-dot-com.no-spam.invalid at 2/11/2005 11:42:32 AM
I want to get the file name and path from a SaveFileDialog (for a 'save as' operation) after the user has saved the information under a new file name (and presumably under a new path) ? I want to display the new file name and path in the Form.text Title. So how do I go about getting the info ?...more >>

e.Handled=true?
Posted by Keith Smith at 2/11/2005 11:35:54 AM
Should I always include e.Handled=true at the end of my event handler? ...more >>

returning Datagrid selection to the caller form
Posted by ALI-R at 2/11/2005 11:32:06 AM
Hi All, My datagrid is now bound and working, Now I have two other issues: 1)My datagrid is in another form and I need to return the value of a coulmn which user has selected to the caller form (in a textbox),I know how the get the value of an specific coulmn in the selected row ,but I do...more >>

Locking a Windows machine using C# .NET framework
Posted by Simon Mercer at 2/11/2005 11:21:55 AM
Hi, Just wondered if there is any code based way of locking the operating system, the same way as when doing ctrl + alt + del and selecting lock computer. I have created a screensaver in c# and when it activates I want the computer to lock at the same time. Any pointers/ideas? Thanks,...more >>

Making/using icon as custom cursor
Posted by Douglas Curran at 2/11/2005 11:13:04 AM
How can I use my image as the current cursor? I know I can do this System.Windows.Forms.Cursor.Current = System.Windows.Forms.Cursors.WaitCursor; But I want to make my graphic the cursor, not one of the standard ones....more >>

Saving to files - XML - C#
Posted by Kenny ODell at 2/11/2005 11:03:03 AM
I am fairly new to the C# world, and I am seeking a little guidance about saving user information. Consider the following: I have several windows which contain settings for an embedded target. The user will either load the settings from a file (which is why I am writing this question), or...more >>

Standard XP Icons
Posted by Frank Rizzo at 2/11/2005 11:02:20 AM
I realize this may have been asked a million times, but I can't find the answer. Where can I get standard windows xp icons (like new, open, save, etc...). I'd like to get them in 16x16, 24x24 and 32x32 sizes. Thanks...more >>

NumericUpDown
Posted by Hrvoje Voda at 2/11/2005 10:39:48 AM
I have a numericUpDown control and I would like to limit the amount of numbers entered after decimal place. Control has by default for decimal places value 2, but I can write as many numbers as I want. I don't want to do that. Hrcko ...more >>

Invoke Method
Posted by Mantorok at 2/11/2005 10:29:49 AM
Hi I have a second thread running and I want to invoke a method in a class on the 1st thread, how can I do this without using a form? Thanks Kev ...more >>

setting a breakpoint in a WinForms event handler... and then getting caught in the event loop.
Posted by Hazz at 2/11/2005 10:17:45 AM
What is the triggering action that raises the event which causes my breakpoint to be reached, repeatedly, but does not allow my form to ever remain visible. I set a breakpoint on the line Graphics.. below. Just curious to help my 'system level' understanding. thx. -hazz private voi...more >>

Advice: XML file as database or table
Posted by Arjen at 2/11/2005 10:07:00 AM
Hello, If I choose to use a database then I need to use multiple tables. With a XML file I can select "my objects" as once. I think that there will be around 10.000 records (objects). I want to select my objects on different (selection criteria) ways (on attributes). And I want to add, u...more >>

Discovering Whose Logged On To Remote System?
Posted by John Puopolo at 2/11/2005 9:23:31 AM
All: I am writing a "net send" like application. The application runs on each person's PC, waiting for messages. Let's suppose "Joe" is logged in to 2 PCs, A and B. I would like to enter acommand (from my PC) like: sendto joe hello I would then like a window to pop up on PC A and PC B ...more >>

Repetivie Try/Catch Blocks
Posted by Steve Murphy at 2/11/2005 9:23:30 AM
I have a couple of standard Try/Catch blocks that I use repeatedly. Is there anyway to wrap these blocks into a method call? Or does C# have anything like a C++ macro? Thanks, Steve Murphy ...more >>

Help with DirectX 9 in a picturebox
Posted by chapmjw NO[at]SPAM mindspring.com at 2/11/2005 9:03:05 AM
I'm looking for an C# example of a form with a picture box that Directx can draw to. My program plots the flight of a golf ball and I need to do it realtime. I would like to keep as a child window on the form because there are 15 or so parameters that can be changed just above it. Could you p...more >>

Queue Email Message
Posted by Sun at 2/11/2005 7:57:03 AM
If the email server goes down, I won't be able to send messages using SmtpMail. I'll get a "Could not Access CDO.Message ..." error. Is there a way to queue the message so that it can be sent out when the system is back running? When we use Outlook, the message is queued when the system is ...more >>

Creating tables during runtime
Posted by Newbie at 2/11/2005 7:39:03 AM
Hello! I'm trying to figure out how to do the following: I need to show a table (perhaps using DataGrids, repeaters or others) for each salesperson in the sales dept. But the no. of tables to be shown is to be determined during runtime. It's possible that some salespersons have no sale...more >>

Check Files
Posted by jez123456 at 2/11/2005 5:35:02 AM
Hi, I need to check that 4 access database files exist and they are not in use before I can process them. For example say my files are: C:\test\data1.mdb C:\test\data2.mdb C:\test\data3.mdb C:\test\data4.mdb I can use if (File.Exists(dbName)) on each one but is there a more generic w...more >>

How to use a C API in C#
Posted by Thorsten moeller at 2/11/2005 5:25:03 AM
Hi, is it possible to use a API coded in C from C#?? If yes, is there a general HowTo on this Topic somewhere around?? Thanks for any Hint!! Thorsten...more >>

Is COM considered 'unsafe' code
Posted by Elidel at 2/11/2005 5:06:36 AM
Is the use of a COM object in a c# program considered 'unsafe' code ? Does the method that calls the COM object need the 'unsafe' keyword ? Is code that calls a COM object considered unmanaged? Is 'unsafe' code the same as unmanaged code ?...more >>

Binding a Drawing.Color value to a datagrid. Please help :-(
Posted by SimonH at 2/11/2005 3:48:00 AM
Hi everyone, If anyone can help me with this I would be really really greatful. I have a custom object that I can't change. Two of the properties (hair colour and eye colour) are of type Drawing.Color Unfortunately I cant change the class implementation to make these properties more fri...more >>

C# FAQ
Posted by Satish at 2/11/2005 3:29:08 AM
HI I would like to know C# interview questions.can anyone help me. Satish...more >>

Owner Draw
Posted by Keith Smith at 2/11/2005 3:25:13 AM
Does anyone know of a good tutorial on how to use OwnerDraw? I have found a coulple on Google, but they were CRAP. ...more >>

Configuration
Posted by Kai Huener at 2/11/2005 2:35:49 AM
Hello, I have a problem to add a config File to a windows forms application. The File (UploadClient.exe.config) is in the same folder as the CodeFiles (namespace is UploadClient), but when I try to get some data from the appSettings for exmple, it does not work. Are there any additional set...more >>

Using a C# Collection through Interop with VB6
Posted by Benjamin Piorczig at 2/11/2005 1:49:04 AM
Hello list memebers, I'd like to use a C# Collection with from within Visual Basic 6. I have derived a my ComInterface class from IList and implemented those Members. Everything seems to work fine at this point. But when i try to itterate through the collection from within Visual Basic i g...more >>

How to: Use "custom validation" control to validate Calendar Contr
Posted by charliewest at 2/11/2005 1:33:02 AM
Is it possible to use the custom validation control to validate a calendar control via client-side script (in jscript)? I'm familiar with custom validation and client side script, and i am aware that the custom control cannot be wired automatically to the calendar control, but i cannot seem...more >>

Creation of XML
Posted by Jesper at 2/11/2005 1:01:06 AM
Hi, I would like to insert a child xml element under its parent node in a XmlDocument. I can't figure out how to do this. Is XmlWriter the only option here. brgds Jesper....more >>


DevelopmentNow Blog