Groups | Blog | Home


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# > december 2005 > threads for monday december 5

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

Control string and format specifiers
Posted by Udi at 12/5/2005 11:52:20 PM
Hi, I tried looking for it in the documentation but with no luck. What's the equivalent C control strings in C# for the following: "%3d" ? (space padding) "%-3d" ? (left alignment) "%+3d" ? (adding +/- sign) "% 3d" ? (adding a space in case of positive vaklue) (E.g - for zero padding ...more >>


Use of cookies and the privacy.
Posted by Johan Goris at 12/5/2005 10:31:23 PM
I have made a website (big part copied) and it works with cookies like : Response.Cookies["ASPNETCommerce_FullName"].Value = blabla ... This works fine when the browser ,internet option , pravacy is set to low. But it will not work with the more common settings like "medium." What do I hav...more >>

ExecuteReader
Posted by Roy Gourgi at 12/5/2005 9:52:21 PM
Hi, Is there a way to get the number of rows that the ExecuteReader has fetched without iterating through with the Read(). I tried RecordsAffected but that returns -1 all the time. HasRows only tells you that there is 1 or more rows, but it does not tell you how many. TIA Roy ...more >>

Running app accepting commands
Posted by Franck Diastein at 12/5/2005 9:30:47 PM
Hi, I'm designing an application, and I would like to be able to receive external commands... I would like a behavior like eMule, when you click on an ed2k link, the link is added to eMule, even if this app is running... How can I handle this behavior in my app ? TIA...more >>

Parameter list
Posted by Roy Gourgi at 12/5/2005 9:09:18 PM
Hi, Is there a way to add a parameter list with only one statement as opposed to having one statement for each parameter. For example if I have 20 parameters (@p1, @p2 .... @p20) that I want to add to my parameter collection, could I do it all in one statement more or less? TIA Roy ...more >>

Console App
Posted by Ken Kast at 12/5/2005 9:02:12 PM
Is there any way programmatically to have a console app start in a minimized window? ...more >>

better way of using XML
Posted by Sharon at 12/5/2005 8:58:19 PM
hi all I have a small application assembled from C# winForm client side (few of them) C# webService at the server side I'm using xml file to transfer the GUI information from client to server For Example in the client window there are 3 text box's and one button Text boxes ar...more >>

doing cleanup in Dispose() when implementing IDisposable
Posted by Narshe at 12/5/2005 7:31:28 PM
If I implement IDisposable in a custom class, how do I let the GC know that the custom class objects aren't being used anymore, and are ready for cleanup? Do I just set them equal to null? Do I need to call GC.Collect() after? Is IDisposable only meant for objects that already implement it l...more >>



current date minus 2 year
Posted by Arjen at 12/5/2005 7:18:52 PM
Hi, How can I calculate the date 2 years ago? I get a problem with datetime minus int (year). Can someone help? Thanks! ...more >>

Is it possible to programatically get the <summary> text of a class, property or method?
Posted by Benny Raymond at 12/5/2005 7:03:07 PM
I'm currently working on giving my plugins space in my settings.xml file, actually, that's now working - however I would like to display each of the plugin's "setting" property summaries in the details section of the datagrid that I am using to update their values. I was wondering if there ...more >>

.net 1.0 vs 2.0
Posted by Hayden Kirk at 12/5/2005 7:02:00 PM
I was just wondering if there is a comparason somewhere that shows the changes from 1.0 to 2.0 in c# Thanks...more >>

Geometrics forms...
Posted by Steven at 12/5/2005 6:55:55 PM
Hi, I have to draw a geometric form quite complex, like a car for example. Then, i need to know which part of the car the user has clicked on. In vb6 i would have used the "shapes" component to draw the car and then use a mathemtical formula to test if the user is in or out of the car. I...more >>

Jobs Momentum Technologies Contact ASAP
Posted by Ritu at 12/5/2005 6:17:03 PM
SENIOR SOFTWARE ENGINEERS - C# Role & Responsibilities: As part of a team, will be developing and unit testing application software. Conceptual understanding of the entire system under development, its business usage, technical architecture, performance and functionality related i...more >>

Adding same method twice to delegate
Posted by Bruce Wood at 12/5/2005 4:51:19 PM
Maybe I'm going nuts, but I was so sure that adding the same method more than once to a delegate would result in only one entry on the delegate's call list: this.UpdateEnd += new EventHandler(UpdateStockCode); this.UpdateEnd += new EventHandler(UpdateStockCode); if (this.UpdateEnd != null) ...more >>

Drawing tables / rendering data with GDI+
Posted by brianbasquille NO[at]SPAM gmail.com at 12/5/2005 4:47:44 PM
Hello all, Haven't been here in a while but undertaking a project where i'm branching out the (presumingly abandoned) open-source OpenHTPC (www.openhtpc.org) with additional Personal Video Recorder functionality to it - meaning recording from TV / browsing TV listings etc. Am just working ...more >>

Variable precision in numeric format string
Posted by mdeaver2003 NO[at]SPAM yahoo.com at 12/5/2005 4:43:32 PM
I'm trying to output a double using a precision that varies, governed by the value of a precision variable. In C I can do it like this: double pi = 3.14159; int prec = 4; printf( "%.*f", prec, pi ); // 3.1416 The * in "%.*f" says to use the value of the next argument (must ...more >>

webdav from .net
Posted by Søren Reinke at 12/5/2005 3:49:35 PM
Hi there I am trying to talk to a CMS system using webdav (it is webdav enablet) I have been googling for som examples on how to talk to a webdav server from ..net but found nothing usefull. Could anyone here please help me somehow ? An example, a webpage with good description and exam...more >>

C# Certification
Posted by javachallenge NO[at]SPAM gmail.com at 12/5/2005 3:44:38 PM
Hi there, I am thinking about the possibility of getting certified (till reaching the MCSD.NET). A few questions for you experts: 1) I was thinking to start with the Web Exam (c#). What do you think about this choice? 2) I have both Kalani's guide and Microsoft's guide. Which one would you u...more >>

API Documentation
Posted by Patrick McGovern at 12/5/2005 3:31:48 PM
I can't seem to find any guidance around this...is there a way to generate API documention for my classes using VS2005? -- Pat McGovern 215-416-6490 ...more >>

Inheritance of a singleton class
Posted by Marcel Hug at 12/5/2005 3:29:40 PM
Hallo NG ! I Have a little question about inheritance of a singleton class. In my application i have a Database-Connection Lib, in which I would ¨like to connect different databases of the same project (thats why it is in a lib). For the database A I created a singleton class AProxy and for the...more >>

Question on "is" operator and casting
Posted by JimM at 12/5/2005 3:16:02 PM
I am trying to create a method in VS 2003 that validates an object argument is of the proper type and within a range of values. I am trying to use a Type to define the casting and object type for the validation. But I get and error of "The type or namespace name 't' could not be found (a...more >>

ConfigurationManager question
Posted by la_dev at 12/5/2005 3:10:30 PM
ok, here's my question. I have a class ConfigServer that has the following method: public string FindByKey(string key) { try { return ConfigurationManager.AppSettings[key].ToString(); } catch (Exception ex) { return ex.Message; } } I also have a config file named...more >>

Problem accessing uploaded file.
Posted by Nick Z. at 12/5/2005 3:03:32 PM
When using SmtpClient and sending a message with an attached file using SendAsync(...), if I add File.Delete(pathToAttachedFile) in the SendCompleted event handler I get a file in use exception. Is there a way to overcome this problem? Thanks, Nick Z....more >>

SqlDataSource UpdateParemeters
Posted by Cognizance at 12/5/2005 3:00:22 PM
Hey gang, I'm in the process of fixing an application a former programmer slap together. We found the database design went against company standards, so our DBA went through to fix her up. Now I'm working on the task of fixing the UI code to interact properly with the new changes. However, ...more >>

Event = null;
Posted by Bruce Wood at 12/5/2005 2:39:29 PM
I need to remove all handlers from a particular event. I am doing this in the class where the event is defined. I have this vague memory that I can say: this.MyEvent = null; and this will clear all delegates from the event, but I'm not sure, and I can't find the relevant documentation. ...more >>

Problem With Appearance of Controls in VS2005
Posted by joey.powell NO[at]SPAM topscene.com at 12/5/2005 2:28:56 PM
This is going to sound REALLY simple....but... I have tried in vain for a long time now to make this work. I have a VS2005 (native) windows forms app with a form that contains a tab control with several tab pages inside it. Unfortunately, it also needs a trackbar control within one of the ta...more >>

How to package references into DLL?
Posted by Brett Romero at 12/5/2005 2:01:57 PM
If I create a DLL (my.dll) that references other DLLs, how do I make sure other developers only need my.dll and not all of the other DLLs it references? Is there a way to compile the references into my.dll and just distribute one DLL? Thanks, Brett ...more >>

DataType for BLOB
Posted by C Glenn at 12/5/2005 1:56:18 PM
What DataType should I use for a field that is BLOB SUBTYPE TEXT on the backend? I've tried String and Char. I'm getting a runtime error telling me that the SourceColumn is a Char[]. Thanks....more >>

Retrieve session var from .net page and use in VBScript
Posted by Frank at 12/5/2005 1:39:21 PM
Can I do this? I add a session var in C# and ultimatly want to pass it into a vbscript client side activeX control. This is what I have so far but get " Object Required:'name2' " error. Can anyone suggest a btter way of passing a session var into a vbscript function? <%@ Page language...more >>

Image to byte[]??
Posted by perspolis at 12/5/2005 1:25:32 PM
Hi all I want to convert an Image to byte[]. I used TypeDescriptor to get a convertor.. it sometimes works and sometimes gives me "GDI+ error".. how can I convert image to bye[] ?? thanks ...more >>

Possible: SelectSingleNode, but omit child nodes in result?
Posted by KJ at 12/5/2005 1:22:06 PM
I'd like to do as the message subject states: only get the specified node, omittting the children in the result. Is this possible? Perhaps a special XPath predicate is needed? ...more >>

selecting only one item in checkboxlist
Posted by adiweb at 12/5/2005 12:52:02 PM
I would like to use a radiobuttonlist in a windows form control but I know this is not possible because radiobuttonlists are only available in web forms. I am trying to use a checkboxlist instead and I am encountering problems. I do not want multiple checks. Any help is highly appreciated...more >>

Changing hook (WH_CALLWNDPROC) arguments
Posted by blueturtle NO[at]SPAM walla.co.il at 12/5/2005 12:38:00 PM
Hi, I've implemented a hook (WH_CALLWNDPRO), using the sample posted at MSDN magazine. ( see url: http://msdn.microsoft.com/msdnmag/issues/02/10/CuttingEdge/ ) I succeed in intercepting the relevant messages, however if I try to change the parameter to the original message, it doesn't wo...more >>

Time difference
Posted by Vivek Sharma at 12/5/2005 12:16:03 PM
Hi, I need to calculate the time difference between today 2pm and tomorrow 2 am. How do I calculate? Thanks Vivek ...more >>

Nested Repeaters
Posted by Peter Kirk at 12/5/2005 11:39:51 AM
Hi in nested repeaters, how do I access data in the "outer" repeater from the "inner" repeater? For example, I have an ArrayList of RegionMenuItem objects. These objects contain a Region object, and an ArrayList of Region objects. I want to display this hierarchy, and in the inner ArrayLi...more >>

Serialize Arrays
Posted by Peter at 12/5/2005 11:13:19 AM
I have large arrays or Array type I am planning to Serialize and save = the serialized data into Access database as memo field. My question is: Is it safe to save this data in that format, will I be = able to read this serialized data back from the database with the next = version of .NET (.NE...more >>

VS 2005 bug
Posted by Sharon at 12/5/2005 10:42:49 AM
This is not the group for this question, but maybe one of you had this problem. My VS 2005 decided not to search anymore. When i click ctrl-f / h the main window looses focus, but the search window does not open. This is true to all search and replace options. Tried repair and remove / instal...more >>

Thread.Resume is Obsolete? How are we supposed to wake up Sleeping Threads now?
Posted by Benny Raymond at 12/5/2005 10:30:51 AM
I have a thread that sleeps for 5 minutes once it's finished running a method and then it repeats itself if it's supposed to (bool = true). Prior to 2.0 I was able to resume the thread after marking the bool to false which would cause the thread to finish what it was doing and complete, or t...more >>

socket questions
Posted by coloradowebdev at 12/5/2005 10:17:03 AM
i am working on basically a proxy server that handles requests via remoting from clients and executes transactions against a third-party server via TCP. the remoting site works like a champ. my problem is executing the transactions against the remote server and returning the response to th...more >>

Simple math program.
Posted by Eric Anderson at 12/5/2005 10:16:46 AM
Would someone be kind and explain why and how this works. It comes up = with the correct answer, but I dont understand how it does. Wouldn't = Console.WriteLine("5+4=3D{0}",5+4); wouldn't it come up as 5+4=3D1 = instead of 5+4=3D9? Sorry guys im new to all of this but im learning. = Thanks for ...more >>

LostFocus doesn't appear on EventsList ( Prop. window )
Posted by Piotrekk at 12/5/2005 9:40:55 AM
Hi I need to use catch an event LostFocus, but its not visible in Evens list in Properties Window of Form1. Should i do it manually? How then? Tnanks PK ...more >>

Application goes down with out any wornin.
Posted by TPI at 12/5/2005 9:36:09 AM
I wrote application wich i working on IntPtr. Whole thing is using Marshal.ReadInt32 and Marshal.WriteInt32. And sometimes the application shuts down with out any wornings and exceptions. With out worninigs and exceptions I do not know where to look up. I need help with this problem. ...more >>

Adjusting minimum size of Open File Dialog
Posted by MLM450 NO[at]SPAM hotmail.com at 12/5/2005 8:58:19 AM
I have extended the open file dialog as described in the MSDN article "Extend the Common Dialog Boxes Using Windows Forms 1.x". I now need to change the minimum height of the dialog. How do I do it? I tried intercepting the WM_SIZING message, but it never gets this message. I tried enforcing h...more >>

Solution for storing a lot of web app configuration ?
Posted by hendry.johan NO[at]SPAM gmail.com at 12/5/2005 8:22:08 AM
Hi, I'm currently developing an HR system which involves storing a lot of configurations per module, such as payroll module, absence/shift module, training module, etc. total: around 100 configuration items. Configurations here, ranging from a simple key to value pair, a key to multiple val...more >>

mdb file still locked after closing the OleDbconnection.
Posted by Sagaert Johan at 12/5/2005 8:21:17 AM
Hi I have a problem with an mdb file still being locked after i closed the OleDBConnection. (can't rename or delete the file) Is there anything that still has some open filehandle to the mdb ? I noticed when i wait a few seconds ( loop containing Application.Doevents() ) after i calle...more >>

CollectionBase Strong Type
Posted by Don D at 12/5/2005 7:59:12 AM
I have a Strongly Typed collection ex: public class MyClassCollection : CollectionBase { .... implemention .... } public class MyClass {} Is there a way using reflection to get the type the StronglyTyped collection "MyClassCollection" expects? Thanks, -- Don DenUyl Diamond Syst...more >>

Moving window
Posted by Piotrekk at 12/5/2005 7:41:39 AM
Hi. I wanna move window, by clicking its body ( not the strip ). Which event should i catch. I tried with mousedown, but then i only can update position of window, once. My task is to change it in real mode ( until mousebutton is up). Can anyone help? PK ...more >>

Accessing HTML embeded objects with Internet Explorer ActiveX...
Posted by Dominique at 12/5/2005 7:33:26 AM
Hi all, I'm using .NET v1.1 and the scenario I have is as follows... I have IE as an ActiveX control embedded in may C# App. I generate a HTML file dynamically and within the HTML file I embed a Flash, powerpoint presentation or movie file similar to ... <object id="globalnav-object" cla...more >>

Strange Exception in default Hashtable constructor
Posted by Nick Vaughan at 12/5/2005 7:32:50 AM
While running some long term tests on our Broadcast SDK one of our thread dropped out because an exception had been thrown: Exception: System.ArgumentOutOfRangeException Message: Load factor needs to be between 0.1 and 1. Parameter name: loadFactor Source: mscorlib at System.Collections.H...more >>

Triggering event on change in process memory?
Posted by anguish at 12/5/2005 7:23:36 AM
I'm using ReadProcessMemory from kernel32.dll to read specific bytes from the process memory of a program. While the solution I have now (which updates the memory content at regular intervals) works, I can help thinking that it's a waste of resources. It also possible to miss changes if the inte...more >>

coloring rows in a datagridView
Posted by Wilfried Mestdagh at 12/5/2005 7:01:02 AM
Hello, I wants to set the background color of rows in a datagridView based on the value of a particular cell. Someone knows how to do this ? -- rgds, Wilfried http://www.mestdagh.biz...more >>

Classes constructor
Posted by Giojo at 12/5/2005 6:27:03 AM
Hello guys! I've a strange situation.. I have to fill a list with all classes defined in a particular namespace.. I have to add all class defined in that namespace (there are many classes..) So instead to make list.Add(new class1()); list.Add(new class2()); .... Is it possible to write fo...more >>

dataset/database update
Posted by Marie-Christine Bechara at 12/5/2005 5:58:35 AM
i have a webservice that returns a dataset holding all categories. i want to enter these rows in the database by calling the data adapter's update method. i'm doing the following but no update to my database is made. why is that? Code: this.dsetMustaqbal = currentIssueWS.GetCateg...more >>

Good Book for learning C# Web Development
Posted by yonthebeach NO[at]SPAM googlemail.com at 12/5/2005 5:40:49 AM
Hi, has someone a good book for learning c# web development. it should cover the beginners to experienced developers. thanks yavuz bogazci ...more >>

Unexpected behaviour reflection & params
Posted by papa.coen NO[at]SPAM gmail.com at 12/5/2005 3:29:27 AM
Consider the following method: TOTAL(string v, params Object[] c) Called with the following values : A, {B, {C, {D,E},F} or (as a 'structured' array layout) : A, [0] B [1] ----- [0] C ----- [1] ------ [0] D ------ [1] E ----- [2] F When this met...more >>

Encapsulate a method...
Posted by Thorbjørn Jørgensen at 12/5/2005 3:27:14 AM
Hi How can I encapsulate a specific method from a specific object? I have some different object with different methods, and I would like that the object could put a reference to one of its methods into a common arraylist. A control element should then at a later time, go through the arraylist...more >>

TreeView - Reloading the treeView and expanding the last selected
Posted by James L at 12/5/2005 2:30:04 AM
Hi, I have a treeview that has to be refreshed due to data changes. Is it possible to select the last node that they were viewing when the tree view was been populated once again? I have tried getting the selected node and then expanding it in the refreshed tree view using expand() but i...more >>

InvalidOperationException
Posted by Curious at 12/5/2005 12:19:01 AM
Hi, I am trying to use the following code to send data over a Message Queue. The following error is being given: "An unhandled exception of type 'System.InvalidOperationException' occurred in system.xml.dll Additional information: There was an error generating the XML document." Can so...more >>


DevelopmentNow Blog