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# > april 2007 > threads for friday april 6

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

ContentLength trouble!
Posted by woof.rana NO[at]SPAM hotmail.com at 4/6/2007 9:28:06 PM
Hi, I've been struggling with this POST problem for more than three hours now, and don't see any light. Below is the troublesome code snippet: System.Net.HttpWebRequest req = HttpWebRequest)System.Net.WebRequest.Create(URI); byte[] bytes = System.Text.Encoding.ASCII.GetBytes(Parameters);...more >>


Reading network socket stream, slow connection
Posted by Sir Psycho at 4/6/2007 9:18:38 PM
Hi, For some reason, when i step over this code, it returns the full byte stream im expecting from the server, however when I let it run with no intervention, it only seems to grab a small chunk on the stream. What am I doing wrong? There is more code than this, but this is the problem code...more >>

C# ACCESS database help
Posted by Jason at 4/6/2007 6:16:53 PM
I've got a simple database that I need to create, and then I'll probably use something like a data grid to display to users. It won't be anything major, a few tables, maybe one relation, then just display, add, and delete. Since I've never delt with anything that involves a DB, I have been l...more >>

any preformance tips ?
Posted by colin at 4/6/2007 3:08:25 PM
Hi, I have several gigabytes of CSV files - coma seperated variables (in text) I find the converting to numbers is a bit slow, to double or int seems about the same, using split seems to take longer than substring, seems no alternative to parse/tryparse. although I havnt tested to see wich is ...more >>

Formula calculation
Posted by VJ at 4/6/2007 2:46:48 PM
We have a form where there is a like 10-15 fields and it performs a length formula calucation each time field value changes. Using validate event is not a option as validate wont fire on Menu click and other events on toolbar click. Right now we have it Value changed i.e entered into control (...more >>

Network Communication & File Locking
Posted by Davidhere40 NO[at]SPAM gmail.com at 4/6/2007 2:17:13 PM
I'm trying to lock a text file, read its contents, make the text file empty, then unlock it. I haven't been successful at it yet. The following code is what I've tried, with no success, because the file stays locked even after the function finishes. FileStream fs = new FileStream(fullPath, Fi...more >>

is .NET different on XP Home and XP Pro?
Posted by Jim Hurley at 4/6/2007 2:01:30 PM
I have an application that runs fine on XP Pro machines but usually doesn't work on XP Home. It doesn't crash or report any missing objects, it just doesn't communicate well. Not sure what the exact problem is because some parts work and some don't. No errors, just doesn't work. the progra...more >>

Remote Custom Types
Posted by rkozlin at 4/6/2007 1:20:01 PM
Is it possible to remotely host custom types? Some background... We have an application that uses custom user controls as 'templates' for entering certain kinds of data. The application is designed to get a list of the possible user controls / templates from the database. The user contro...more >>



DisconnectedContext was detected - WebBrowser.Document.Write
Posted by Zytan at 4/6/2007 1:08:50 PM
Make a WebBrowser control, and make a bunch of timers / threads that continually call WebBrowser.Document.Write. Eventually, this happens: DisconnectedContext was detected Message: Context 0x1a1530' is disconnected. Releasing the interfaces from the current context (context 0x1a13c0).This ma...more >>

Strings and Escape Characters
Posted by Rahvyn at 4/6/2007 1:04:00 PM
I am storing a printer name in the registry. If its a networked printer, it stores as so: \\server\printername. When I pull that value in code, and throw it in a string, I get \\\\server\\printername. I get why this is happening, but I have a legacy dll that I need to pass that value in...more >>

Panel w/ border help
Posted by Nathan Laff at 4/6/2007 12:18:54 PM
I've got a custom Panel that draws a colored border for me. Works great, however a new problem I've run into is this. I have the custom panel, then I want to put another panel (just a Windows.Forms.Panel) inside it, and dock it to the top. When i do this, the docked panel paints over the bo...more >>

volatile structures
Posted by titan nyquist at 4/6/2007 11:07:15 AM
Can you make volatile structures in C#? I have a static class, to have "global" variables. This allows the whole program to see them. I make them "volatile" to avoid multi- threading accessing issues. That works. THE PROBLEM: In that static class, I want to combine some variables insi...more >>

Are a Static method's variables staic too?
Posted by mark at 4/6/2007 10:26:07 AM
Consider this a continuation of 2/27/2007 thread by Zytan entitled"Subject: Does C# have static local variables like C++?" In C++: void mysub() { static double x; blah; blah; } In C++ the variable x retained its value for subsequent entries into the method That bein...more >>

int is out of scope???
Posted by PJ6 at 4/6/2007 10:21:38 AM
(VS2003) ? int.Parse("2.0") error: identifier 'int' out of scope ? "foo".IndexOf("o") error: expression '"foo".IndexOf' out of scope For the love of god, why is int and other basic stuff out of scope in my Command window when I'm debugging? VB doesn't do this, is this a C# thing? Pau...more >>

Easy(?) one about Label.Text
Posted by cashdeskmac at 4/6/2007 10:18:02 AM
Hi, I have a Label on a Windows form (Version 1.1.4322) and while I iterate recursively through a method I want to show the name of the current file being copied to another directory. The Label is not visible until the backup begins, at which point I resize the form to show the Label an...more >>

Convert hex to double in 2.0?
Posted by Byron at 4/6/2007 9:30:06 AM
How do you convert a hex string into a double using C# in framework v2.0? I've seen this question answered before, but apparently something has changed in 2.0 that negates the old solution that I've seen. The code: DoubleVariable = Double.Parse(HexString, NumberStyles.AllowHexSpecifier); ...more >>

how to set the carret to the end of a text box (or automatic scroll)
Posted by timor.super NO[at]SPAM gmail.com at 4/6/2007 5:54:55 AM
Hi group, i'm setting a (long) string in my textbox textBox1.Text += s + Environment.NewLine; but if the text is longuer than the visible capacity of the textbox, I can't see the end of my text (that is the most important), even if the scrollbar is set. I would like to see automatica...more >>

How do I create an xml file and execute in c#...
Posted by trint at 4/6/2007 5:13:23 AM
UPS Rates & Service is an xml method of requesting rates on shipping out boxes from the "checkout" point of online shopping cart software. Well, I have gotten my c# project all the way to the point of having all this information stored in variables ready to place in UPS Rates & Service xml. How...more >>

Merge word applications
Posted by madhu27 at 4/6/2007 5:06:56 AM
Hi.. I have two word applications in byte arrays. I need to mege them and combine into one document and prompt the user to save the merged document. madhu ...more >>

Const in referenced assembly becomes literal in compiled code
Posted by Sledgehammer777 at 4/6/2007 5:03:12 AM
I have an issue that I'd like some oone to explain to me. In a C# DLL I have a several const strings defined as such: namespace ns { public class strings { public const string string1 = "XYZ"; public const string string2 = "ABC"; } }...more >>

How to create 2 dimensional dynamic array (vb.net or c#)
Posted by singleb NO[at]SPAM gmail.com at 4/6/2007 4:36:25 AM
I've tryed to something lik this and got "Object reference not set to an instance of an object." Dim myarr(,) As String myarr(0, 0) = "aaaa" myarr(0, 1) = "bbbb" myarr(1, 0) = "cccc" myarr(1, 1) = "dddd" Thanks. ...more >>

Working with database in C# Pocket PC
Posted by Sheikko at 4/6/2007 4:00:51 AM
Working with database in C# Pocket PC Hi all, I want to develop an application that work with DB on pocket PC. I have added the DB to the project from Menu->Data->Add New Data Source. I want to insert some Rows in a table of this Db. I know that I can create a connection and insert values wi...more >>

Global Assembly Cache
Posted by a.mustaq NO[at]SPAM gmail.com at 4/6/2007 3:25:31 AM
Hi All, What is aphysical path of GAC. ...more >>

Garbage Collection
Posted by a.mustaq NO[at]SPAM gmail.com at 4/6/2007 3:24:02 AM
Hi All, When an object is not is used for a long time, it will be removed by Garbage Collector. How can we avoid the Garbage Collector not to remove the object though it has not been used for a long time. ...more >>

Can I abandon the lock on .SyncRoot and lock a collection directly? Less available memory in 2.0?
Posted by DC at 4/6/2007 3:17:58 AM
Hi, I am porting an app from Framework 1.1 to 2.0 and I am now using Dictionary objects instead of Hashtables. There are some lock (theHashtable.SyncRoot) statements in the 1.1 code and I replaced those by lock (theDictionary) statements. I did not note a difference, but I wanted to ...more >>

Accessing base class in User Control
Posted by chakris at 4/6/2007 2:02:01 AM
Hi All, Iam developing a web application using VS 2005 asp.net 2.0 with C#. I have my base class in "App_Code" folder and i have another folder called "Users" where i have developed a user control called users.ascx. Now in my Users base class i have some properties like FirstName,LastName a...more >>

login into normal web pages through c#.net
Posted by apondu at 4/6/2007 1:56:03 AM
Hi, I work on C#.Net. I am working on some application which as a requirements of downloading files and extracting data form web pages, and i have a probelm in doing so sometime i am required to log into the site to get the data form those sites. I wanted to knw how can i log into those we...more >>

login into normal web pages through c#.net
Posted by apondu at 4/6/2007 1:53:36 AM
Hi, I work on C#.Net. I am working on some application which as a requirements of downloading files and extracting data form web pages, and i have a probelm in doing so sometime i am required to log into the site to get the data form those sites. I wanted to knw how can i log into those we...more >>

Interfaces
Posted by a.mustaq NO[at]SPAM gmail.com at 4/6/2007 1:33:29 AM
Hi All, Is it compalsory to impliment all the methods defined in the interface by the derived class. ...more >>

Abstract Classes
Posted by a.mustaq NO[at]SPAM gmail.com at 4/6/2007 1:29:53 AM
Hi All, By using Virtual and Ovverride specifiers we can change the functionality of the methods in the derived classes, then why we go for Abstract classes. ...more >>

there are 2 control A and B
Posted by somequestion at 4/6/2007 12:46:36 AM
보낸 사람: "somequestion" <somequestion@gmail.com> 제목: userControl and WindowForm 날짜: 2007년 4월 5일 목요일 오후 11:31 now ...there are 2 control A and B A is Form control and B is UserControl A : Form {} B: UserControl {} i'd like to make inherit both userCont...more >>

user control
Posted by RobcPettit NO[at]SPAM yahoo.co.uk at 4/6/2007 12:23:21 AM
Hi, I hope I dont make a mess of this question, as Im new to c# my terminology is a bit of, here goes. Ive started to make a windows application and Ive added a usercontrol from another program, which had already been layed out, and Im trying to understand the workings of this user control. I t...more >>

ZeroMemory
Posted by muriwai at 4/6/2007 12:00:00 AM
Hi, I need an equivalent of ZeroMemory in c# 2.0. The below does not compile because it cannot convert 0 to T. I plan to use the method for numeric Ts only. public static void Zero<T>( T[] o, int offset, int length ) { for( int i = 0; i < length; i++ ) { o[ offset + i ] = ...more >>


DevelopmentNow Blog