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

Do tooltip captions have reserved charcters?
Posted by steve bull at 6/21/2005 9:40:58 PM
When I try to create a tooltip caption "Red & Green" I have a problem it displays as "Red Green". Why does it ignore the &? Are there other characters that are ignored too? Can I get a list from somewhere? Thanks, Steve...more >>


Strange Bug with the order of objects in a collection
Posted by Robert W. at 6/21/2005 9:21:02 PM
I've come across a problem that I just cannot explain. I'm hoping that someone has seen it before. I have the following [basic] data structure: Questions (collection) Question (object) Choices (collection) Choice (object) I populate Questions[0].Choices with...more >>

Long Generic Instantiations
Posted by Jasper Kent at 6/21/2005 7:38:45 PM
I'm trying to do the equivalent of using typedefs with templates in C++ to avoid long instantiation names. I can do this okay: using BigDictionary = System.Collections.Generic.Dictionary<int, System.Collections.Generic.Dictionary<int, string>>; class MyClass { private BigDictionar...more >>

Initialising a Windows service
Posted by Mark Rae at 6/21/2005 6:48:50 PM
Hi, I'm looking for advice concerning what to do if a Windows service does not find a "viable" working environment at startup. E.g. I have a Windows service which does the following: 1) connects to a remote FTP site and looks for certain files which it downloads to a fileserver if it fi...more >>

Reset a foreach loop.
Posted by Ken Varn at 6/21/2005 4:44:09 PM
Is there any way to reset a foreach loop to re-iterate through the collection as if it were starting from the beginning? Namely, if I delete an item out of a collection, I want to be able to reset the loop. -- ----------------------------------- Ken Varn Senior Software Engineer Diebold I...more >>

Saving a G4 COmpressed TIF Image
Posted by JSheble at 6/21/2005 4:42:35 PM
I need to save a bitmap object as a G4 Compressed TIF file... any help would be tremendously appreciated... ...more >>

ListView
Posted by Mythran at 6/21/2005 4:38:42 PM
Quick question, I don't have the time to dig in and look for the answer so quick post should hopefully do the trick, if y'all don't mind :) In a ListView...I can set it so the first column of the selected row can be edited...anyway I can get the rest to be in edit-mode? Not all at once, or ...more >>

C# telnet problem
Posted by mnsindhu74 NO[at]SPAM yahoo.com at 6/21/2005 4:28:19 PM
I want to implement telnet client in C#. I am able to connect to the telnet server in windows XP and do the negotiations. I also get the login prompt.After I send the username I get password prompt. the problem starts with the password prompt. After I send the password the server returns three ...more >>



Threaded Cross-Class Winform Manipulation
Posted by i at 6/21/2005 3:29:21 PM
Hi, I'm trying to get a seperate class, initialized by a form class, to manipulate certain objects on the form (ex: add to a listbox). The manipulation will occur via a thread that is not the normal WinForm GUI thread. How would I go about doing this? I have this code for cross-thread...more >>

Message box show problem
Posted by Grimsley at 6/21/2005 3:20:02 PM
We are have a problem where we go to show a message box and there is no text on the message box. Has anyone had or heard of this problem before?...more >>

Response.Redirect() and Frames
Posted by David P. Donahue at 6/21/2005 2:47:16 PM
I have a page that's viewed within an Iframe. This page has some code behind it, including a reference to another class in the project which, depending on certain conditions, may perform a Response.Redirect(). However, the redirect only occurs within the Iframe. Is there a way to get it to...more >>

Bitwise Operation...What am I doing wrong here
Posted by xanthviper NO[at]SPAM xanthviper.com at 6/21/2005 12:44:36 PM
Hey, I'm trying to do what I think is pretty basic here, but I am missing something. Hopefully someone can point me in the right direction. Essentially I have an enumeration set up as the following: public enum DocumentFlags { Enabled = 1, Accepted = 2, Denied = 4, Deleted ...more >>

Referencing other forms
Posted by Christopher Weaver at 6/21/2005 12:33:08 PM
This is a broad question. I am developing a multiform Windows applications. There is only one database involved. I would like to establish one connection object and a few DataAdapters and DataSets that I can use in several of the windows. How and where do I instantiate these objects so I ...more >>

FileSystemWatcher.
Posted by Peter Kirk at 6/21/2005 12:23:36 PM
Hi I am trying to use FileSystemWatcher to watch for changes in a directory. The problem I am exepriencing is a double firing of an OnChanged event when a file is opened, edited, and saved. Why is the event fired twice? Here is my code: static void Main(string[] args) { FileSystemWatc...more >>

Newbie on Inheritance, Base classes and derived classes
Posted by aaj at 6/21/2005 12:12:58 PM
Hi all I'm new to OOP and just getting to grips with inheritance. Could anyone tell me if my understanding so far is correct.....? If I have a base class, and then some derived classes with extra functionality e.g. Base Class : Watch Method SetTime Derived Class : DigitalWatch Metho...more >>

Registry Access, easy question hopefully
Posted by Justin at 6/21/2005 12:00:04 PM
I am attempting to access the following registry HKEY_LOCAL_MACHINE\Security\Policy\PolyAdtEv using the following code. This registry has a binary representation of the settings of the audit policies on the remote machine. If I can read it then I can interpret it and determine what the pol...more >>

Can textboxes have transparent backgrounds?
Posted by melanieab at 6/21/2005 11:51:10 AM
Hi again, Just wondering if this was possible. I tried setting it in the Properties menu but got this response: This control does not support transparent background colors. Thanks again, Melanie...more >>

MulitiLine TextBox in datagrid?
Posted by perspolis at 6/21/2005 11:49:39 AM
Hi all dows anyone has a sample code about a multiline textbox in a datagid or a listbox in a datagrid?? thx in advance ...more >>

newbie: Help closing window
Posted by clsmith66 at 6/21/2005 11:40:02 AM
I need som help safely closing a window. I have an application which loops through all the files in a designated folder and runs OCR on them. The loop to do the OCR work is in its own method. The app runs fine unless I try to close the window before the loop is finished. Any suggestions on...more >>

algorithm question
Posted by matthias s. at 6/21/2005 11:34:55 AM
hi, as a self-taught programmer I've got little clue about coding patterns and general algorithms. so I'm asking here hoping to improve my skills: I've got a large array of objects, say Car(s) where a Car has got a MaxSpeed and Brand property. How would I go most effectively to search the ar...more >>

FileSystemWatcher
Posted by Peter Kirk at 6/21/2005 11:14:36 AM
Hi I am trying to use FileSystemWatcher to watch for changes in a directory. The problem I am exepriencing is a double firing of an OnChanged event when a file is opened, edited, and saved. Why is the event fired twice? Here is my code: static void Main(string[] args) { FileSystemWat...more >>

PLEASE. ListView's Row Height
Posted by Víctor at 6/21/2005 11:02:40 AM
Anyone knows how change Windows Forms ListView's Row Height? I need show data in a ListView Outlook 2003 like, with two lines (title and date) on each row. Thanks. Víctor. ...more >>

DirectX and Graph Editor
Posted by RicercatoreSbadato at 6/21/2005 10:53:01 AM
I've the DX SDK, but I don't find the GRAPH EDITOR (like this http://www.flipcode.com/articles/article_directshow01-01.jpg). Where Can I find it? -- RicercatoreSbadato...more >>

Is this a good application Design?
Posted by Jay Balapa at 6/21/2005 10:00:01 AM
Hello, Currently my application has three tiers- 1. Presentation Layer (Asp.Net / Win Forms/ Pocket PC UI.) This predominantly contains User Controls, Custom Controls and Win/Web Forms. I have one base form and I inherit from that form. All validation is done in this tier. There is ze...more >>

Reader problem...
Posted by Craig Lister at 6/21/2005 9:57:58 AM
Newbie alert! I am trying to get data from my mySQL database... With some help, I have got this far, but there is an exception in data.dll (??) on the : "OleDbDataReader Reader = Command.ExecuteReader();" line. Can you see a problem here ? string ConnectionString = "Location=myconn...more >>

Security
Posted by Justin at 6/21/2005 9:44:03 AM
Is there a way to programmatically access Audit Policies and Security Options in windows 2000 and NT. If anyone knows of a way please let me know. Thanks. ...more >>

Timer - temporay pause
Posted by Dave at 6/21/2005 9:42:01 AM
I have a program that I need the program to temporarly stop and wait for a response from a piece of equipment. After a set period I want the program to continue. Like below --execute lline before pause --pause statement- pausefor set period --execute line after pause I tried using a time...more >>

.NET dev. Web hosting
Posted by Studio P.M. at 6/21/2005 8:43:14 AM
Dear colleagues, Could you recommend a valid Web hosting provider for .NET developers? As a developer of Microsoft .NET Web applications for WSS (Windows SharePoint Services) I'm looking for a Web service test environment where I could: - define and manage IIS v. 6 Virtual Directories ...more >>

COM and registration question
Posted by oliderid NO[at]SPAM yahoo.co.uk at 6/21/2005 8:14:42 AM
Hi, I'm new to C# and the windows world (I used to work on Java and *nix OSes). I'm using visual studio .net 2003. I'm working on a add-in application to be used under a software. I was able to settle the correct COM interface. Now I must register the software in the windows registry. Th...more >>

App.Config and XMLDocument
Posted by ryanbreakspear NO[at]SPAM norubbishgmail.com at 6/21/2005 7:44:45 AM
Hi All, I've created a class for reading from the App.Config which implements IConfigurationSectionHandler. I want the Create() to return an XMLDocument something like: public object Create(object parent, object ConfigContext, XmlNode section) { XmlDocument XmlDoc = new XmlDocument(); ...more >>

cannot convert from <STRUCT_NAME> to ref <STRUCT_NAME>
Posted by Gee at 6/21/2005 7:41:03 AM
I get the above error with this code and I can't figure out why? Any ideas please? See code below - the actual error is included in the code: public struct NETRESOURCE { public Int32 dwScope ; public Int32 dwType; public Int32 dwDisplayType; public...more >>

Cannot run any macros through Visual Studio 2003
Posted by BuddyWork at 6/21/2005 7:23:43 AM
Hello, Does anyone have the solution for the following issue? I cannot run any macros (include the samples) from the Macro Explorer using Visual Studio 2003. I've tried creating my own using the Recorder and then trying to run it and it just does nothing. I have also reinstalled VS 2003 and...more >>

datatable updating
Posted by gl at 6/21/2005 7:21:04 AM
What's the best way to update a datatable? For instace, if the datatable has a column called tempbit with either a 1 or 0 in it, and i wanted to reset all rows back to 0, what would be the best way to do that? I know i could just loop row by row, but is there an eaiser way to just call a sql s...more >>

What is the best way to write this generic method?
Posted by Robert Zurer at 6/21/2005 7:06:43 AM
This method works but FxCop rightly complains "Generic methods should provide type parameter" http://www.gotdotnet.com/team/fxcop/docs/rules.aspx?version=1.32 &url=/Design/GenericMethodsShouldProvideTypeParameter.html public sealed class ReflectionAgent { public static T GetCustomAttri...more >>

Strange problem (asp.net application)
Posted by Hash at 6/21/2005 6:52:04 AM
Hi All, I have a small asp.net app developed in C#, where I am using COM components and Activepdf toolkit to create pdf files for given documentID's. I am using DataReader to get the docID's from sybase database. My problem is, the application when opened or accessed first time after 1 d...more >>

unable to open website
Posted by Newbie at 6/21/2005 6:31:04 AM
I have a C# asp.net webform with a Link Button to a website but it's not opening the website correctly. It's saying "The page cannot be found". But the website is loading when I use IE. Below is the code and thanks in advance. private void lbtnWebsite_Click(object sender, System.EventArgs e) ...more >>

VB6 Types
Posted by wg at 6/21/2005 6:18:54 AM
I am sort of new to C# from VB6. Is there a similar function to the variable Type found in VB6. There I created a Type then an array of that variable that could be used. I could then dynamically alocate memory depending on the number of variables needed. For example Type Tags Dim Na...more >>

set mouse postion
Posted by Emjay at 6/21/2005 6:15:03 AM
Newbie needs to know how to set the mouse position....more >>

Reorder listbox items in asp.net
Posted by CodeRazor at 6/21/2005 6:07:04 AM
Is it possible to reorder items in a listbox server control by having the user select an item and then click an up or down button? ... how? Or is this something that can only be achieved client side? thanks ...more >>

How can I set the fontsize in a String
Posted by Kaushik at 6/21/2005 4:42:03 AM
Hello Everybody, Can anybody tell me... Suppose I have a string strHtl="This Flower is yellow" I want First two words of the above string in font ariel and size 10 with Brown text background. I will then write this text with the same format I described above with stream...more >>

problem in accessing a BSTR* from C#
Posted by Gilad Walden at 6/21/2005 3:57:01 AM
I use C# in .NET framework. I have an ActiveX implemented in C++ that has a COM interface method that gets as it’s out parameter a BSTR* . The interop translates this BSTR* into C# string. From my managed code, I am calling that function with ‘out’ parameter of ‘string’ type. For ...more >>

Failed to open meta data ???
Posted by (cmrchs NO[at]SPAM yahoo.com) at 6/21/2005 2:56:48 AM
Hi, I'm compiling a cs file in .NET 2005 and try to view the assembly-exe using the ildasm tool but I get an error : "Failed to open meta data" whereas in .net 2003 it was no problem. how come ? how can I view what's inside the 2005-assembly ? thanks CHristian ***************...more >>

How to download and print msdn help files / documentation as doc or pdf
Posted by Manuel Lopez at 6/21/2005 1:09:35 AM
Here's a simple question: how do I download or print out the entire documentation (or a large chunk) in readable format (doc or pdf)? It's not of much use to me if I have to go to every separate html page and print page-by-page. Is there a utility to do this, or is it on a separate website...more >>

Characer length = 0
Posted by Zest4Csharp at 6/21/2005 12:55:02 AM
hi there, I found in the literature the C# line below: dataAdapter.UpdateCommand.Parameters.Add("Subscriber", OleDbType.Char, 0, "Subscriber"); Does the above mean that the value to be updated to field "Subscriber" is of type 'Char' and that it can have ANY length?...more >>

dynamic creation of web service proxy...
Posted by Ollie Riches at 6/21/2005 12:00:00 AM
I know this has probably been asked a lot but I can't find any good exmaples so.... Can anyone give some url's to C# code that dynaimcally generates a web service proxy at runtime? Cheers Ollie Riches http://www.phoneanalyser.net Disclaimer: Opinions expressed in this forum are my...more >>

What dir executing is done from
Posted by Mads W. at 6/21/2005 12:00:00 AM
I want to read an ini file which is located in the same dir as my .exe file. But how can I do that without having to have the excact same dir for all my program installations. Let me try to elaborate: PC 1 has my C# program lying in C:\Application\Csharp.exe Here I need to read my ini fi...more >>

Make web pages show up as black and white
Posted by JCL at 6/21/2005 12:00:00 AM
I have a winform and on this winform, I have a WebBrowser control. Users can browse the web through this form. Is there a way that I can make web pages show up as grey scale pages, with the color being converted to black and white? In this way, users will always see a colorless web page when they...more >>

Setting the description for a Windows service
Posted by Mark Rae at 6/21/2005 12:00:00 AM
Hi, Apologies for asking this again - I know it's been answered before - but I am creating a Windows service and would like to add a description to display in the Services MMC snap-in. I know it's possible to do this by writing directly to the Registry: http://www.codeproject.com/dotnet/d...more >>

How to Programmatically create a DataGrid
Posted by ad at 6/21/2005 12:00:00 AM
I use the code to create a DataGrid and filled with data, But the DataGrid1 didn't display in WebForm. How can I display the DataGrid after creating it? DataGrid DataGrid1 = new DataGrid(); ...more >>

Simple Button
Posted by Rodrigo Ferreira at 6/21/2005 12:00:00 AM
Anyone uses the simple button component from DevExpress? ...more >>

Copy: Hashtable to Properties
Posted by James Scott at 6/21/2005 12:00:00 AM
Hello, I have a values stored in a Hashtable hash and I want assign them as properties to an object obj obj.x1 = (String)hash[x1]; obj.x2 = (long)hash[x2]; obj.x3 = (int)[x3]; ..... Is there a better (more reusable) way, like this Pseudocode: foreach (DictionaryEntry de in hash) {...more >>

Socket.BeginSendTo and Socket.BeginSendFrom on a single Socket instance from multiple threads
Posted by Jonas Hei at 6/21/2005 12:00:00 AM
Is it safe to call socket.BeginSendTo and socket.BeginSendFrom on a single instance of Socket from two different threads running simultaneously? This is required because I need to listen on a certain URI [IP:Port] and I need to send outgoing messages from that local socket [IP:Port] some...more >>

Problems with System.Mail Class
Posted by Calvin at 6/21/2005 12:00:00 AM
In short, I've written a newsletter component which sends out an HTML email. However, whilst everything seems to work fine if email is downloaded onto a windows pc, the same email doesn't download images/format correctly on mac in entourage. I create the HTMl page as normal, with images given ...more >>

Scrolling bug in MDI client windows
Posted by James CC at 6/21/2005 12:00:00 AM
[Cross posted in dotnet.framework.windowsforms and dotnet.languages.csharp, because it could apply to either] I have a strange bug in C# using windows forms. To make sure it's not some bug with my code, I've gone back to a simple test app, and still see the same behavior. I have created ...more >>

syncing timers
Posted by news.eclipse.co.uk at 6/21/2005 12:00:00 AM
Hi - I have two seperate threads each running timers - I was wondering if there is any way to sync the two seperate timers using a system clock or something - or would I have to simply create a routine? - which would not be that difficult I realize but was wondering - cheers James Jenkins ...more >>

MPEG2 and C#
Posted by RicercatoreSbadato at 6/21/2005 12:00:00 AM
I need to open a video MPEG2 and analyze frame per frame. I've read on http://msdn.microsoft.com/library/default.asp?url=/library/en-us/directshow/htm/supportedformatsindirectshow.asp that MPEG2 is not supported by the DirectShow. I've downloaded the codec for the MPEG2 from ELECARD. Now Can ...more >>

Debugging an Assembly DLL
Posted by Daniel Secci at 6/21/2005 12:00:00 AM
Hi all, I have an application which dynamically loads an Assembly DLL in the current AppDomain. I have to debug this assembly. How can I do that ? (VS 2003) I tried to attach the main process with the debugger but it does not help. Thanks in advance, Daniel Secci ...more >>

data conversion !!!
Posted by Giang Pham at 6/21/2005 12:00:00 AM
I have an activeX control written by C++ It has a function like this: void AppendYData(double FAR* pYData, long lDataSize, short nElementID) When I inssert it into project C#, it generate interface like this: public virtual new void AppendYData ( System.Double pYData , System.Int32 lDataSize...more >>

asp.net C# Button_click event and javascript function
Posted by Jason Huang at 6/21/2005 12:00:00 AM
Hi, What I want to do here is in the asp.net C#, when I click a button then some sorts of validation will be checked, then it will call a javascript function to open another webform. Would someone tell me how to involve the javascript function in the C# button_click event? Thanks for help...more >>


DevelopmentNow Blog