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# > june 2004 > threads for tuesday june 29

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

References in C#
Posted by Sauli V at 6/29/2004 11:14:41 PM
I've got a form code from which I call ExcelObject class to perform writing to Excel and saving the sheet. The process is too slow and I'd like to update my form's status bar's panel with number of records processed. My question is since the form and ExcelObject are functionally separate (encap...more >>

Textbox ID in C#
Posted by wallacewhlee NO[at]SPAM yahoo.com.hk at 6/29/2004 11:04:28 PM
I've a vendor provided executable that runs under WinCE .NET 4.2 and requires two input parameters: 1. window handle of a dialog 2. ID of a textbox The program will perform a barcode scanning and send the result to the specified textbox. The program works fine in eVC++ 4.0 with the following...more >>

[Q] drawing box around text in a label
Posted by stuie_norris NO[at]SPAM yahoo.com.au at 6/29/2004 11:00:21 PM
Dear Readers, I am attempting to draw box around some text using unicode on multiline label. The label is forty characters wide and 12 lines deep. I have been trying to draw a box around text (centered in the label) on this label. My font on this label is Courier new - hence fixed width ch...more >>

Creating control panel applet using CSharp
Posted by rajani at 6/29/2004 10:33:16 PM
How to create control panel applet in CSharp. I know that a dll renamed as .cpl with cplapplet function exported has to be created which is not possible using csharp. Any help is appreciated. Thanks in advance...more >>

Process.RedirectStandardInput Question
Posted by Matt Osborne at 6/29/2004 10:20:48 PM
Hello all. I have an application that i am writing to automate an older system. The system is based on a 16-bit DOS application. It apears to me that I am unable to redirect input and output to and from the application. Does anybody know if i am missing something simple? Thanks ...more >>

VS 2005 Express Beta1 - pb with NUnit
Posted by Joannes Vermorel at 6/29/2004 9:36:18 PM
Hi, I just give a try at VS2005 Beta1 (for C#). I have try to import a simple C# project (MathNet.Numerics, http://nmath.sourceforge.net). The conversion from VS7.1 to VS8 went without any problem. But when I tried to run the NUnit tests, I got the exception "System.BadImageFormatException: Th...more >>

How to retrieve Custom Attributes from the Type
Posted by Paul at 6/29/2004 9:17:58 PM
Hi! I have a problem: I've declared some classes and decorated them with my Custom Attributes. (say ClassA and ClassB) Now I have some Type member (in fact this is FieldInfo.FieldType) which is eq. typeof (ClassB). And when I call GetCustomAttributes() for this Type I never gets the attrib...more >>

Escaping problem using Regular Expression
Posted by Henry at 6/29/2004 9:05:33 PM
I have this simple code, string escaped = Regex.Escape( @"`~!@#$%^&*()_=+[]{}\|;:',<.>/?" + "\"" ); string input = @"a&+[b`${c}a'?sd:r]" + "\"" + @"@(-d)\e"; Regex re = new Regex( string.Format(@"([{0}]+)", escaped), RegexOptions.CultureInvariant ); string s = re.Replace( input, "" ); It d...more >>



using Image class from console application
Posted by Volly at 6/29/2004 8:05:34 PM
Helo ! I want write console application and I want to reuse my old class, but inside it is used Image class (and System.Drawing.Imaging namespace). I can't complile it. The error is: The type or namespace name 'Drawing' does not exist in the class or namespace 'System' (are you missing a...more >>

Express Version Kills Current Version
Posted by Lloyd Sheen at 6/29/2004 8:01:57 PM
Never mind what they tell you. Just installed 2.0 beta and no more 1.1. Tried to run simple ASP app and doesn't work anymore. Ran aspnet_regiss -i but to no avail. So anyone who tells you they run side by side needs to be put in the stocks with the spammers. No I can only hope that a syste...more >>

Passing parameter to MenuItem.Click handler
Posted by Valerie Hough at 6/29/2004 7:55:33 PM
I would like to have a number of items on my C# menu and I would like them all to invoke the same handler, but with each passing different data (say some integer) that will be based on which menu item was clicked. I can derive a class from EventArgs, but how do I associate a new instance of t...more >>

transactions for file manipulations
Posted by Travis at 6/29/2004 6:14:00 PM
Hi All, I was wondering the .NET framework supports transactions for I/O operations. I am renaming, deleting, and moving multiple files and would like to rollback the entire process if I encounter an exception. Thanks ...more >>

Windows service and AppDomain.UnhandledException
Posted by Kimmo Laine at 6/29/2004 5:28:16 PM
Hi, does the AppDomain.UnhandledException also work when you use it in Windows Service - i was unable to get the handler called when i generated an exception. thx Kimmo Laine ...more >>

Need to populate first 2000 records
Posted by Karunakararao at 6/29/2004 5:22:27 PM
Hi All i have 40,000 records. populate the total records in Datagrid . it's taken time I need to populate the first 2000 records After the need to populate next 2000 records. how can i do it using datagrid. inC#.Net .. Advance Thank u Venu. ...more >>

Loading a DLL explicitly?
Posted by Michi Henning at 6/29/2004 5:13:06 PM
I've been looking at the doc to find the answer to this but didn't get very far. Assembly.LoadFile() seems to be close, but not quite the right thing... I have a DLL containing code written in C. In my C# code, I want to check whether the DLL exists and, if so, load it. Otherwise, if the DLL ...more >>

General Control(s) question
Posted by Doug at 6/29/2004 4:47:04 PM
HI, I have a user control where checkboxes are added to it dynamically from the database. I want to be able "tell" the parent form what has been checked and what hasn't. I know I have to iterate through the controls on the form, check to see if the control's name has part of a substring t...more >>

System.Windows.Forms.Message Properties values
Posted by Sean at 6/29/2004 4:42:03 PM
Hi, I would like to know all the available values for Message.Msg, Message.LParam, Message.WParam. Where can I find all the values? (complete information) In the .NET documentation, it says that //Constant value was found in the "windows.h" header file. But where is this windows.h? Tha...more >>

C# regular expression replace help ??
Posted by ycmahesh NO[at]SPAM hotmail.com at 6/29/2004 4:38:42 PM
Hello, I need help in replacing one string pattern with another. Ex: I have a financial security expression like log(T 3.25 6/24/2004)/sqrt(T 4.5 6/19/2002) Here "T 3.25 6/24/2004" is a variable on which I need to perform log and then divide the result with 3.980. While parsing such ex...more >>

ComboBox Upper Case
Posted by PL at 6/29/2004 4:33:26 PM
I'm looking for a property of the ComboBox component who give the possibility to put all the data capture in upper case... Something similar to : Me.textbox.CharacterCasing Have an idea? Thanks! PL ...more >>

HTML doc save dialog
Posted by joseph.inglis at 6/29/2004 4:30:43 PM
I have a web browser object on a form which I have set to edit mode and use the UCOMIConnectionPointContainer interface to hook in and catch events. All working sweetly. Except there are instances where i rewrite the Document.Content and the first keypress results in a default window...more >>

RSACryptoServiceProvider
Posted by Marco Moioli at 6/29/2004 4:28:36 PM
Hi everybody: Does anyone know how can I create an instance of RSACryptoServiceProvider using the information contained in an X509Certificate class object? (How do I extract the Modulus and Exponent from the key contained in X509Certificate?) Thanks in advance, Marco ...more >>

Window Flashing !!!
Posted by Paul Loveless at 6/29/2004 4:15:18 PM
Hi all. I've noticed in my dot net program when the main program window is maximized, and I close an open form (well technically I hide it) that I have displayed in the main window, that the main window will occasionally flash momentarily, displaying another open program. It is like windows xp is...more >>

local paramater versus several "gets"
Posted by DapperDanH NO[at]SPAM nospam.nospam at 6/29/2004 4:12:09 PM
Hello, I am new to object oriented programming and .net. I have a question concerning using singletons. Lets say I have the following: public class Engine { public static readonly Engine Instance = new Engine();//singleton private Device device; public Device Device {...more >>

About DataGrid control in C#
Posted by allen zhang at 6/29/2004 4:07:11 PM
I had written an application with Microsoft VS.NET2003, I wanna use NavigateTo method of DataGrid control,but when I did it, I find it always shows some rows in the header of Datagrid control, so I don't how to remove it? Anybody can help me to address this issue. Thank for your the advanced...more >>

Automatic build process + automatic NuNit (2 in 1 solution)
Posted by gicio NO[at]SPAM gmx.de at 6/29/2004 3:56:33 PM
Hi! Can someone tell me can I use MsBuild with NuNit today? Or is MsBuild only available for MSDN subscriptions ? Or what do you for an automatic build process + automatic NuNit testing. I looking for a 2 in 1 solution (build + NuNit) gicio ...more >>

How to overload greater than operator
Posted by John Mark Howell at 6/29/2004 3:36:33 PM
BlankDoes anyone know how to overload the greater than (>) operator? I = know that it is probably not in accordance to the framework design = patterns, but it would make my code much cleaner. --=20 John Mark Howell...more >>

MSCOMM32.OCX exception
Posted by Mohammed Abdel-Razzak at 6/29/2004 2:56:01 PM
Dear sirs I`ve got the file MSCOMM32.OCX from visual basic 6 and used it in C# I`ve includedit in the references and also used it in the project "using MSCommLib;" I also have written the following declaration in the constructor MSCommLib.MSCommClass msCom = new MSCommLib.MSCommClass(); ...more >>

bulk insert in C# (?)
Posted by Daniel P. at 6/29/2004 2:53:35 PM
How can I use ADO.NET to insert lots of records in a very fast way? Thanks! ...more >>

String variable strange behavior
Posted by Tamir Khason at 6/29/2004 2:36:46 PM
I have some string in variable str_tmp = "C:\TMP\" I want to display it in textbox (@-quoted), so I'm using tbx.Text = @str_tmp; but for some strange reason this does not work. it processes escape sequence. What is the problem??? -- Tamir Khason Who am I at http://www.khason...more >>

How to view component designer?
Posted by Hyun Chang Lee at 6/29/2004 2:36:06 PM
I have created a 'smart device appication" project. (C#) and added a component class. I expected the component designer shows, but I couldn't see. And there is no menu item like 'view designer' in the context menu in the solution explorer. In a windows application project, VS showed me the...more >>

creating directory with asp.net
Posted by Arvind P Rangan at 6/29/2004 2:29:06 PM
Hi, I have tried creating folders through ASP.Net with Directory.Create(path) But it gives me error mscorlib Access to the path "C:\WINNT\system32" is denied. at System.IO.__Error.WinIOError(Int32 errorCode, String str) at System.IO.Directory.InternalCreateDirectory(String fullPath, Strin...more >>

Threading in System.IO.Ports
Posted by Alex Moskalyuk at 6/29/2004 2:07:46 PM
I downloaded the Visual C# express, which includes the .NET Framework 2.0. The following exception is generated: {"Illegal cross-thread operation: Control 'textBox1' accessed from a thread other than the thread it was created on."} on the following code: namespace WindowsApplication1 ...more >>

Error HRESULT 0x800A03EC (EXCEL)
Posted by e-lores at 6/29/2004 1:52:53 PM
I need to print an excel doc to PDF. I'm doing next until now 1.- First I print the file to PostScript format using 'Acrobat Distiller' printer Dim wbook As Excel.Workbook wbook = appExcel.Workbooks.Open(fileExcel) wbook.PrintOut(fisrtPage, lastPage, , , "Acrobat Distiller", True, filePs)...more >>

Control location problem on a form ( C# )
Posted by Mike at 6/29/2004 1:35:02 PM
Hi! I posted this question in browser_ctl group as well but got no results. I have a form with embedded WebBrowser. Upon clicking on a link in the embedded webbrowser that calls JavaScript's window.open() call where I pass different width, height, top, left and other parameters, I open a new fo...more >>

Referencing assemblies and .config files.
Posted by Mark Broadbent at 6/29/2004 1:30:18 PM
Hi guys, just going through remoting at the moment and a couple of questions relating to .net in general has surfaced. Firstly I have seen in the designer that for the namespace and many of its associated classes of System.Runtime.Remoting are available, but certain ones are not. A reference to ...more >>

suppressing console window appearance when application is started with Application.Run() ?
Posted by Bill Woodruff at 6/29/2004 1:29:12 PM
I know, it's a weird question, but I am experimenting with a multi-form app where I need to override Dispose calls and want to start the app this way. thanks, Bill Woodruff dotScience Chiang Mai, Thailand ...more >>

mouseover event in axWebbrowser kills navigation functions
Posted by Mitch at 6/29/2004 12:37:19 PM
I am hosting a web browser ctl in a container that implements the IDocHostUIHandler interface. I'm using this to control the context menu.This works fine. Then, I added a mouseover event to the document in the documentComplete event handler. When I add this event handler, I loose all other ...more >>

Calling a COM+ component over ASP
Posted by Patrick Ruhnow at 6/29/2004 10:49:35 AM
Hi, i have a COM+ component written in C#. I try to call the component over ASP. No problem so far until I've got a array in the parameters of the COM+ method. C#: public byte[] ProcessPdfDocument(string reportPath, string identifier, string boType, string userName, bool storeDocument, str...more >>

*.aspx -> *.html
Posted by Aurimas Norkevicius at 6/29/2004 10:48:21 AM
I need to rename asp.net application filenames to have *.html file name extensions not *.aspx. It is easy to do. Bu how to configure Visual Studio .NET 2003 to process *.html files the same as it does with *.aspx Thanx Aurimas Norkevicius ...more >>

Renaming Public Properties of Inherited Class
Posted by Earl Teigrob at 6/29/2004 10:45:35 AM
Is there a way to rename the public properties of a inherited class? I am inheriting an asp.net control (class) and am adding addtional functionality. (in this case, up to 3 borders on an imagebutton control) I would like to change the name of the BorderColor property to InnerBorderColor because ...more >>

ANN: SQL Server 2005 Express Technical Preview
Posted by Thomas Scheidegger [MVP] at 6/29/2004 10:40:37 AM
SQL Server 2005 Express Technical Preview http://www.microsoft.com/downloads/details.aspx?familyid=2ccf2ab6-bfd9-4ac8-b31d-ddbad7d532a2 Download: http://download.microsoft.com/download/c/f/8/cf872b5a-509b-44ce-b5ac-e693f7aec971/SQLEXPR.EXE Web: http://msdn.microsoft.com/sql/ex...more >>

NEW: Visual C# Express Edition
Posted by clintonG at 6/29/2004 10:38:18 AM
Visual C# 2005 Express Edition [1] is a simple, lightweight, integrated development environment designed for beginning programmers and non-professional developers interested in building Windows Forms, class libraries, and console-based applications. Visual C# 2005 Express Edition includes many o...more >>

NEW: Visual C# Express Edition
Posted by clintonG at 6/29/2004 10:36:47 AM
Visual C# 2005 Express Edition [1] is a simple, lightweight, integrated development environment designed for beginning programmers and non-professional developers interested in building Windows Forms, class libraries, and console-based applications. Visual C# 2005 Express Edition includes many o...more >>

UBound - DataSet Less - DataGrid
Posted by rawCoder at 6/29/2004 9:58:51 AM
Hi There, I simply want a DataGrid in .NET which acts .. well like the old VB6 grid .... where you fill and access elements directly ... not being dependant on some data source or DataSet to be more precise. IOW need a perfectly UnBound DataGrid elements of which can be added/accessed/modif...more >>

newbie: XmlTextWriter + xsd
Posted by Jeff at 6/29/2004 9:43:28 AM
Hello! IDE: VS 2003 .Net OS: XP Pro I'm experimenting with C# for the purpose to learn it... I've made a test program that create a simple xml-file using XmlTextWriter. Now I want to extend that logic so the xml-file references a xsd-file... I know that if XmlTextWriter begin to write da...more >>

ANN: .NET Framework 2.0 Beta 1
Posted by Thomas Scheidegger [MVP] at 6/29/2004 9:40:20 AM
..NET Framework Version 2.0 Redistributable Package Beta 1 (x86) http://www.microsoft.com/downloads/details.aspx?familyid=f1232c37-0fee-4aa6-aa89-b6dcefc0873b Download (at your own risk): http://download.microsoft.com/download/9/6/6/9666067a-660f-48e0-a755-a83a81036b67/dotnetfx.exe ...more >>

XHTML problematic, in xml used w/ .net
Posted by Jason Shohet at 6/29/2004 9:40:03 AM
I have an xml file (that is updated through infopath), which populates various .net controls. One of the elements in my xml file contains XHTML tags: And the xml text reader object that .NET provides, cannot read elements of an xml file that contain xhtml. The reader does not return the text, ...more >>

UserControls Vanished
Posted by putman at 6/29/2004 9:38:54 AM
I am sure that this has come up here before, but the Search is not working for me for this newsgroup. I am working on a Windows Forms project where I have created a number of usercontrols that I am using on multiple forms. After editing one of the controls, when I rebuilt the project all...more >>

How to...
Posted by Jacek Jurkowski at 6/29/2004 9:13:22 AM
Make Vs.net installer to remove previous application version automatically and do not require to remove first by control panel Add/Remove? ...more >>

ASP.Net Editing Textbox
Posted by Martin Hazell at 6/29/2004 8:52:43 AM
For various reasons, I have had to produce a quick (!) page to edit one column of data in a database with ASP.net. With this being my first foray into ASP.net, I apoligise for any basic erros I have made. The main problem is when setting up an ASP.net datagrid, which I can edit the single value ...more >>

Strongly-typed CopyTo() implementation
Posted by pdavis68 NO[at]SPAM hotmail.com at 6/29/2004 8:05:40 AM
I have a collectiond derived from NameObjectCollectionBase. FxCop is complaining that I need to implement a strongly typed CopyTo(MyObjectType, int) How do I do this? I can't seem to find any implementations of CopyTo() that don't rely on Array.Copy or some other internal .NET method. Unfortun...more >>

Clustering support in C#?
Posted by Peter Steele at 6/29/2004 7:51:31 AM
I've seen some sample code in VB for working with Microsoft's clustering facilities, for example Dim objCluster as Cluster Set objCluster = New Cluster What's the appropriate "using xyz" to make these structures available in a C# application? ...more >>

How to remove the close box, but still keep the max and min box in
Posted by www at 6/29/2004 7:12:01 AM
MyForm.ControlBox = false; MyForm.MaximizeBox = true; MyForm.MinimizeBox = true; This is not working very well. The form shows without the whole controlbox (max, min, and close box), until you double click the form to maximize it. Then the form will show both the maximize and minimize box. ...more >>

unsafe code in c#
Posted by gobusk NO[at]SPAM yahoo.co-dot-in.no-spam.invalid at 6/29/2004 7:02:13 AM
Hi all, i have created a unmanaged VC++ dll and then created a wrapper class for it . i have included this wrapper class in my c# by using add reference .The function takes ushort* as the input .i.e. i am should pass a string as an input to the function Function Prototype is this: void WCCon...more >>

using WriteFileEX from C#
Posted by tom NO[at]SPAM vandeplas.com at 6/29/2004 6:40:01 AM
I'm trying to implement a class that writes blocks of data asynchronously to disk. Each block is an array of ulongs. I tried to use the standard beginwrite functions, but apparently they only support byte arrays. Due to the nature of my problem (huge amounts of data) it would be very cpu unfriendly ...more >>

DialogResult
Posted by Beeeeeeeeeeeeves at 6/29/2004 6:40:01 AM
Something tells me that there is a single-method way of accomplishing this. When you click the button that is designated as the cancel button, the form automatically acts as if it has been dismissed, but for the OK, you have to put in its click handler: private void btnOK_Click(object sender, Sys...more >>

Accessing a remote database through Web Services
Posted by GeRmIc at 6/29/2004 6:13:01 AM
Hi, I would like to access a database through web services (not ODBC). Any help would be greatly appreciated. I am totally blank on this aspect! Thanks...more >>

referring to control
Posted by chxant NO[at]SPAM yahoo.com at 6/29/2004 5:42:06 AM
Hi, I want to use a parameter in a control name. Something like this: i=1; (CheckBox + i).ID="test"; Is this possible? Thanx....more >>

StreamReader poor performance
Posted by oafyuf NO[at]SPAM hotmail.com at 6/29/2004 4:17:48 AM
Hi, I'm having performanbce issues with StreamReader and was wondering what I could do to improve it... The following takes around 3 seconds to process! The content of the response is: "<?xml version="1.0" ?><ERROR>ORA-01403: no data found</ERROR>" HttpWebRequest req = (HttpWebRequest)W...more >>

Class name notation
Posted by gaetan NO[at]SPAM xeberon.net at 6/29/2004 3:59:34 AM
Hello I have a tiny problem about naming convention. When i read msdn, they says how to give a name to the internet (IThing), and to the class (Thing)... but i like abstract classes to factorize methods used in many inherited class... So i don't really know how to name them since i didn't find ...more >>

Garbage Collector!!!! is it required
Posted by breathedotnet at 6/29/2004 2:56:01 AM
C++ had a delete operator for every new one created. .Net says i would do that job but why do we need some backend unreliable process to do it when u cud have done it. It is just a overhead -- Do not mistake that i am crazy bout .net it is just that it is filled with so many bugs that it ends u...more >>

Few questions about printing and creating a setup disc
Posted by Gidi at 6/29/2004 2:12:01 AM
hello, i'm writing a windows application in c# and i have few questions: 1. where can i read or see examples about printing documents which i'll create in my forms. i want to print tables and insert data (each time different data). 2. when i'll finish my program (soon i hope...) i need to cre...more >>

Mixing text and binary data in the same file.
Posted by Kai Bohli at 6/29/2004 1:41:14 AM
Hi all ! I've come across a huge problem (for me at least). I'm trying to send some initial graphics to a labelprinter. To do this, I load the graphics from resource and send it directly to the printerport along with "printer instructions". The problem is that the printer instruction have...more >>

Hey Jon Skeet
Posted by Michael C at 6/29/2004 12:09:01 AM
You know an awful lot about C#. Have you written a book I can go buy? If not, you should write one and reserve me the first copy. Thanks! Michael C. ...more >>


DevelopmentNow Blog