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 2003 > threads for tuesday december 30

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

ASP.NET1.1 Timeout period elapsed prior to obtaining a connection from the pool.
Posted by Kamalanathan T. at 12/30/2003 11:16:33 PM
Hi, We have developed an Web application in ASP.NET with C# and we r using SQL Server 2000. We get the Timeout expired error, when more than 300 concurrent users hit the site. I hagone thru the code, to check whether all the Connections are closed. everything is perfect, and infact t...more >>


Getting a value out of StringDictionary
Posted by John at 12/30/2003 10:59:15 PM
Hi! I have a StringDictionary itialized as follows: private void frmICUCalculations_Activated(object sender, System.EventArgs e) { StringDictionary dataDict = new StringDictionary(); dataDict.Add("Item1", "2001" ); dataDict.Add( "Item2", "2002" ...more >>

How do Embed a file as a resource?
Posted by M at 12/30/2003 10:49:44 PM
Hi Folks, Does anyone know how to embed a file into a resource in C#? You seem to be able to embed Icon, Bitmap, Cursor's & Strings. But how do you embed a file??? In VC++ version 6 you would, Find the Resource, Load It, get its size, and then write it out to where ever you ...more >>

ComboBox
Posted by Jim Heavey at 12/30/2003 9:42:57 PM
You apparently can bind a HashTable to a ComboBox? How do you set the ValueMember and DisplayMeneber? ...more >>

Making my own type castable to string?
Posted by Kenneth Baltrinic at 12/30/2003 8:57:26 PM
I am implementing a class that routinely needs to be cast to and from a string. I would love for some way to make the compiler realize that my class can be cast to and from a string. Implementing a TypeConverter seems like it is designed to do this kind of thing but it doesn't actually do it, ...more >>

Doubt
Posted by Baskar RajaSekharan at 12/30/2003 8:38:18 PM
Hi, Please clarify my doubt in C#. I have one Dll which is created in (VC7). I want to load the Dll dynamically in my C# project. How to do that. How to load the Dll Dynamically. In Vb, We get the ProgId and then with the help of CreateObject we do it. Similary Is...more >>

Re:
Posted by Charlie Williams at 12/30/2003 7:27:53 PM
This works for me. string myValue = dataDict["Item3"]; By the way, I'm assuming you are refering to the System.Collections.Specialized.StringDictionary, but I don't see a member named "Item" Charlie ...more >>

Serializing?
Posted by Tobias Zimmergren at 12/30/2003 7:18:21 PM
Hi, just wondering what serializing really is, and howto use it? Thanks. Tobias __________________________________________________________________ Tobias ICQ#: 55986339 Current ICQ status: + More ways to contact me __________________________________________________________________ ...more >>



Language Enhancement Idea
Posted by Matt Osborne at 12/30/2003 6:03:45 PM
I don't know if this is the correct forum to propose a new feature for the C# languange, but I thought I would do so anyway. I was working on a project and thought of a feature that would possibly help many developers. It was the adition of a new loop that crossed a foreach and a do loop. ...more >>

Threading problem
Posted by Paul E Collins at 12/30/2003 5:46:37 PM
I have written a game that allows the user to upload high scores to the Web. I now want this upload to occur on a separate thread so that the window remains responsive. My attempt looks like this: m_worker = new Thread(new ThreadStart(UploadScores)); m_worker.Start(); // ... private void ...more >>

Attributes and Generics in C#
Posted by Brian at 12/30/2003 5:34:01 PM
Hi, According to An Introduction to C# Generics (http://www.msdn.microsoft.com/vcsharp/default.aspx? pull=/library/en-us/dv_vstechart/html/csharp_generics.asp) the AttributeUsage enumeration has a GenericParameter value. [AttributeUsage(AttributeTargets.GenericParameter)] public class ...more >>

String Manipulation
Posted by kuya789 NO[at]SPAM yahoo.com at 12/30/2003 5:29:21 PM
1. How do I remove non-alphanumeric characters? Input: dEFD&*fdff/df; output: dEFDfdffdf 2. How can I capitalize the first character of a word? Input: remember Output: Remember Thanks...more >>

Graphics and GDI+
Posted by Gary Morris at 12/30/2003 5:26:11 PM
Happy New Year, all! I hope that everyone is in good spirits, and for those that choose to indulge, you are imbibing in good spirits as well. The subject is graphics and GDI+, something that may or may not belong here, so I'll start with this: Is there a newsgroup that specifically deals wi...more >>

migrating ASP to ASP.Net: #include
Posted by Davíð Þórisson at 12/30/2003 4:49:19 PM
hi, I am getting really excited to start migrating so much less time it's going to take to do my web projects!! in my old Asp web I had a common frame for all pages which was simply included at top of each .asp file. Actually all layout was done through various strings (strFrame, strMain, str...more >>

A class with only static members
Posted by Simon Harvey at 12/30/2003 4:36:06 PM
Hi everyone, I have a class that I want to use to store application state information. I was thinking that I would probably want to make all the information static in that class because the application should only have one copy of application information. First Question: Is this the right ...more >>

ZeroDeployment
Posted by Suresh at 12/30/2003 4:34:53 PM
Hi All, 1) Zero Deployment talks of downloading an application from the webserver and running it(Talks of placing the client app in the virtual directory of IIS). I have a client ( built using C# on .NET) acessing a webservice running of Tomcat. Now how do I place the my .NET client in T...more >>

Editable list view style control
Posted by wonil kim at 12/30/2003 4:28:33 PM
Hi, All. Can I use ListView control for sub item editing purpose? For example, Name Value ------------------ X 1 Y 2 ATTR 10 If I have above style list name and value pair, is it possible allow to user edit "Value" column only? If I didn't...more >>

C# vs Sun Java security
Posted by Mario at 12/30/2003 4:08:27 PM
I've been reading some Sun Java articles where they say Applets cannot import dlls and cannot write to disk. (This does NOT apply to applications, only to Applets.) Supposedly, this is NOT something you can cotrol with a security manager or in any other way. The dll exclussion is due to t...more >>

Import a DLL at runtime
Posted by David Vestal at 12/30/2003 3:29:25 PM
I need to import an unmanaged DLL (not COM or .NET, just a plain DLL), but there's a caveat. I don't know its name at compile-time. I know the functions and function signatures that are in it, but I can't discover the name of the DLL until runtime. DLLImport, unless I'm mistaken, can only...more >>

Exiting an application
Posted by Andrew Warren at 12/30/2003 3:28:00 PM
I'm trying to exit a Windows Forms application while in the form's constructor (after InitializeComponent() has been called) and am finding that calling Application.Exit () still leaves the form displayed and running. Trying to force the form to close with this.Close() does not work either...more >>

Read Standard Output of a Child Process by CreateProcessAsUser
Posted by bo_dong NO[at]SPAM yahoo.com at 12/30/2003 3:19:58 PM
In my asp.net webservice application, I need to launch a DOS process as authorized users. To impersonate users, I use <impersonation = true> in my webconfig. I can't use Diagnostics.Process.Start, because it creates a child process using parent process token "System", not the impersonated thread...more >>

C# object model / documentation
Posted by Davíð Þórisson at 12/30/2003 2:55:48 PM
Hi, when I was programmin ASP/JScript I had a very nice utilitiy which I got from MSDN (Script56.CHM). It's simply a help file but containing object orientiated documentation of all scripting languages. Very handy and easy to maneuver and quickly find information needed. Is there something si...more >>

accessing parent variables
Posted by Rustam Asgarov at 12/30/2003 2:44:44 PM
how can i access variables defined in the parent class from the child class: By some way other than passing as parameter to constructor. I mean. class Parent{ public int b; public Method() { b = 5; Child child = new Child(); } } class Child{ public Met...more >>

Naughtily loading the data members of a struct - when it's boxed
Posted by Steve Terepin at 12/30/2003 2:40:29 PM
I have a binary file containing fixed-length records, which I need to read into an array of structs. I've found a relatively nice way to do this, roughly as follows (some details omitted) : [StructLayout(LayoutKind.Explicit,Size=8)] struct MyStruct { [FieldOffset(0)] int field_A ; [Field...more >>

SQL Query
Posted by kuya789 NO[at]SPAM yahoo.com at 12/30/2003 2:36:33 PM
My db table looks like this FILENAME FILE_CREATED FILE_MODIFIED test 9/12 test2 9/13 10/13 .. .. all FILE_CREATED field have value, only some FILE_MODIFIED have value. I need to get the value of FILENAME column and this is what i have SELECT FILENAME FROM REW_FILES ...more >>

Big5 to/from Utf-8 string conversion module
Posted by Mullin Yu at 12/30/2003 2:27:49 PM
I want to develop a middle tier module of big5 to/from utf-8 conversion module by using .NET platform. utf-8 big5 -------> [module] -------> <------ <------- utf-8 big5 any ideas of classes and methods to use? ...more >>

c#, DataSet and CLS Compliance
Posted by news.microsoft.com at 12/30/2003 2:10:46 PM
The question is, is a DataSet CLS compliant? Minimally implemented code, with an attribute [assembly: CLSCompliantAttribute(true)] in the assemblyinfo.cs compiles just fine (is it possibly the data INSIDE the dataset that could invalidate its compliancy?): using System; using System.Data; ...more >>

Use C++ Header file within C#
Posted by vanlil NO[at]SPAM yahoo.com at 12/30/2003 2:05:16 PM
Hi! Sorry if this has been already answered but I've searched the archives and found nothing. Our Dev-Team needs to replace an existing C++ written DLL that is already used by several applications. As we're mainly into Java we've looked at opportunities to implement these dll functions as...more >>

Casting
Posted by Jim Heavey at 12/30/2003 1:44:56 PM
If I have a method which requires and object to be provided and I what to know if the object can be cast to an int16, or double what command would I use to find this out? In VB, I think the format is If typeof MyField is System.String, but that does not seem to cut it in C# Thanks in ad...more >>

String Problem
Posted by Pablo Salazar at 12/30/2003 1:38:27 PM
Hi people I try to fill treeview but when i compile the programa it gave me the following error : "Use of Unassigned local variable 'nombre' " public void Agregar(TreeNode x,int tipo) { string nombre; switch (tipo) { case 1 : nombre = "Elemento"; break; ...more >>

crawler pool
Posted by steveocsic NO[at]SPAM hotmail.com at 12/30/2003 1:38:18 PM
Hi, I've coded a basic crawler where by you enter the URL and it will then crawl the said URL. What I would like to do now is to take it one step further and do the following: 1. pick up the url's I would like to crawl from a database and pass them to the crawler. Once the crawler has cra...more >>

Datagrid cell - How to de-select a cell
Posted by Randy at 12/30/2003 1:29:43 PM
Hello, Can someone tell me how you de-select (un select) the currently selected cell in a datagrid? Thanks ...more >>

Encryption/Decryption of stream.
Posted by Martin at 12/30/2003 1:04:39 PM
Hi Im trying to make a Client/Server where im going to encrypt the stream = but i cant get it to work. I can recieve and send as long as im not = trying to send/recieve encrypted. but when i am i cant send, recieve or = both. The Send/Recieve Code is the same on both Server and client. Send/...more >>

How to read a Doc or PDF file
Posted by Shayer at 12/30/2003 1:00:11 PM
Hello All I am trying to read a MSDoc file and PDF file using Streamreader and then display the content into a richtext box. But cant do that. Anyone can pls help me out Thanks Shayer ...more >>

How to this in csharp
Posted by RA at 12/30/2003 12:36:33 PM
I have the follwoing: FILE_FLAG = 0x8; DIR_FLAG=0x4; NewFlag = FILE_FLAG | DIR_FLAG; I need to find if FILE_FLAG exists in NewFlag. How to write this in csharp? Thanks. ...more >>

'finally' block
Posted by Brian at 12/30/2003 12:32:43 PM
Is it possible to have more than one try/catch/finally block within a method? Also, if the code never enters the try block of code, is the finally block executed? I have a try block in a branch of a switch statement and I only want the finally to execute if the branch of the switch state...more >>

getting a handle on nested controls
Posted by Marco Martin at 12/30/2003 12:22:46 PM
Hi, I have a control that nests other controls. I need to be able to get a handle on these controls when clicked. the problem is that when I click on one of the nested controls, my mouse down event does not fire and I cant add a mouse down event to the nested controls. Any ideas? best ho...more >>

Color
Posted by Jim Heavey at 12/30/2003 12:20:19 PM
Hello, It must just be a bad day for me...Maybe I should just go home... The compiler highlights this line... using System.Drawing...there is such a namespace, why can't I import it? If I what to format a string and at the same time assign it a particular color, what is the best way to do ...more >>

Dataset: How to Access specific column data?
Posted by David M at 12/30/2003 12:16:41 PM
When using a dataset, how can one get to a column data element using this format: dataset.Tables[0].Rows[0].... I can get to a specific row, but I am not sure how to get to the column or data. I tried using the keyword Column, but no luck. Also, is direct access the best way to access...more >>

using IDisposable
Posted by newbie at 12/30/2003 12:16:11 PM
I have Class A that implements IDisposable, within this class i have method A that creates a new Sqlconnection object and execute some stored proc, in Class B, I create an instance of Class A object with the using statement.. my question is when my using statement ends Class A's dipose method shoul...more >>

Calling a C# constructor..
Posted by Alan Seunarayan at 12/30/2003 12:14:33 PM
Hello all, I need to know if I can call a C# constructor in the same way VB.NET and JAVA can. For example: class myClass { public myClass() { Console.WriteLine("Hello from constructor 1"); } public myClass(string name) { Console.WriteLine("{0} says \"Hell...more >>

Business / Data tiers - efficiency
Posted by Daisy at 12/30/2003 12:13:41 PM
Hi Folks, Got a load of business objects - Product, Price, Offer, FAQ, Description... Product contains collections of the others (eg. Product.Offers is a collection of Offer objects) Similarly, in the database, Price, Offer, Faq, Description all have Product foreign keys (and there can be...more >>

File Access
Posted by Dan DeLuca at 12/30/2003 11:46:58 AM
All, My understanding of the Windows file system is somewhat limited so I apologize if my question is a bit basic. I am having some issues with the System.IO classes, which I use to copy files on a server, when the server directories start to get full. The program starts to get painful...more >>

Database not found
Posted by Bernardo Heynemann at 12/30/2003 11:24:22 AM
The following block of code gives me an error. MultiBD is my class for multiple databases. connection= MultiBd.GetConnection(DataProviderType.OLEDB); connection.ConnectionString = MultiBd.GetConnectionString (1); comand = connection.CreateCommand(); comand.CommandText = strSelectComand; c...more >>

Installing to the GAC
Posted by Mark Irvine at 12/30/2003 10:41:28 AM
Hi, Does anyone know a good article on how to do this? I have read the C# article on the MS support site, however I still have a few questions: Does the dll always have to be located in a bin directory? From my early attempts at installing to the GAC, I noticed that the codebase property h...more >>

cache question
Posted by kuya789 NO[at]SPAM yahoo.com at 12/30/2003 10:18:35 AM
Is it possible to store a string into cache? It seems that only datatables/dataset can be stored in cache from the examples on MSDN and the internet. I tried changing it to a string and retriving it but it says null reference error or something like that. this is what i did --------- cache.ins...more >>

Any open-source DB module used by C# and VB6
Posted by Mullin Yu at 12/30/2003 10:10:29 AM
My project has both C# web services and VB6 application, VB6 COM and ASP applications, and they need to use the db connection to MS-SQL and Oracle. Is there any open-source DB module having the concept of connection pool, and don't need to create the connection everytime, and easily be configured...more >>

Decimal Format
Posted by Jim Heavey at 12/30/2003 9:37:51 AM
According to "professional Asp.Net 1.0" it says that to format Decimal you can use the Format Character of "D" or "d", but everytime I try this I get an exception "Format specifier invalid". I am guessing that there must be a misprint. Is that correct? What character should I use?...more >>

TAPI
Posted by ibrahim NO[at]SPAM islamabad-dot-net.no-spam.invalid at 12/30/2003 9:21:51 AM
i want to make the project on Dot Net TAPI.. my query is that which language is suitable for the TAPI e.g. C Sharp or VB.NET Thanx ----== Posted via Newsfeed.Com - Unlimited-Uncensored-Secure Usenet News==---- http://www.newsfeed.com The #1 Newsgroup Service in the World! >100,000 Newsgrou...more >>

Casting objects - method pointer table being used?
Posted by Marty McDonald at 12/30/2003 8:58:43 AM
I know about boxing & unboxing... but I'd like to know just a bit more. For instance, Dog is derived from Animal. Dog has a method called "Bark". Assume we're calling a method like this... Dog spot = new Dog(); DoStuff(spot); The method looks like this... private void DoStuff(Animal a) ...more >>

Database Navigation Button(s) Class
Posted by Les Cardwell at 12/30/2003 8:51:31 AM
I'm developing a dbms app, and would like to reduce the code for the nav buttons to a class. I've developed a form class for the forms to be used (cFormTemplate), but haven't decided where to place the code for the nav buttons... 1. Within the cFormTemplate class. 2. Create a seperate cB...more >>

DataReader problem...
Posted by Bernardo at 12/30/2003 8:50:22 AM
Hi, I have a datareader, and I want for each record in my datareader to make an insert in other table, the problem is that an error occures, it sais that i have to close the datareder first! :-) Here is the code SQL = " SELECT ID_ECRAN "; SQL = SQL + " FROM MODULO_ECRAN"; SQL = SQL +...more >>

Namespaces and projects
Posted by RickN at 12/30/2003 8:31:27 AM
a) Is it best to split up a large application into multiple namespaces and multiple referenced projects or minimize the splits to all required client code in one client dll and all required server code in one server dll? b) To further clarify, performance-wise, is there a penalty to cross name...more >>

Marshalling (ie PostMessage) in C#.
Posted by Gregory Goeppel at 12/30/2003 8:26:11 AM
I have a component (with NO user interface) in C# that fires events from a seperate thread. The client of the C# component does processing with UI elements and other non thread safe variables within these events. I do NOT want the client to be processing the event from the secondary thread...more >>

Best database objects??
Posted by Bernardo at 12/30/2003 8:19:28 AM
Hi, Anyone knows what are the best database objects? The COM ADO is better then Data.OleDb or Data.SqlClient? Thanks,...more >>

C# reference to Cpp reference
Posted by Randy at 12/30/2003 8:05:55 AM
Hi all, I want to pass a reference from a C# app to a managed CPP dll, keep getting the errors Argument '1': cannot convert from 'out double' to 'double*' Argument '2': cannot convert from 'out int' to 'int*' I've been tying things till I'm red in the eyes.... Thanks for any help. I've s...more >>

Passing variables between forms.
Posted by Steve at 12/30/2003 7:58:52 AM
Can anyone recommend the best way to pass a string back to the calling class (windows form) from a dialog that was shown modally using ShowDialog?...more >>

Iunknown in c#
Posted by shay-ken NO[at]SPAM zahav.net.il at 12/30/2003 7:50:03 AM
Hello group. I need to use some COM components in C#. One of the components has a function that receives an argument which is an IUnknown for a different com object. In C++ it is implemented as: ComObject1->function(GetIUnknownForObject(ComObject2)); How do I implment this call in c#? H...more >>

Generic Conversion Of Types
Posted by Jim Heavey at 12/30/2003 7:31:17 AM
I am trying to figure out how to write a generic "format" routine to return a string type variable. I want to pass this routine an object and based on the type of the object format according to the type. I tried something like this, but of course it does not like this... How can I accomplish...more >>

Is there an equivalent of exit() for quitting a smartdevice application ?
Posted by Eric at 12/30/2003 7:06:56 AM
How can I quit a smartdevice application ? After I click the right-hand(up) "X" button in the Pocket PC 2002 Emulator,it seems that the smartdevice application has not been closed. (My smartdevice app has three forms. Every form has a "X" button which is close to the time information.) W...more >>

Newer Version Check
Posted by Martin Hazell at 12/30/2003 7:05:40 AM
I am just writing an app that will be used internally. What I would like it to do is to check the version of an exe on a server is different to the current one. I have managed to get the assembly version for the app executing, but I don't know how to read the version info for a file on...more >>

Refresh System tray
Posted by joe at 12/30/2003 6:50:14 AM
Hi guys, Is there any way to refresh the system tray. Every time the explorer crashes the notify icons are removed and I cannot see them when it comes back even when my application is running. I could not find any code to refresh the system tray in the KB articles any help or po...more >>

DLLImport for DLL containing ftell and fseek
Posted by trellow at 12/30/2003 6:46:09 AM
Does anyone know what DLL the ftell and fseek functions are in? I need to use these functions in a C# program. I know they are not in kernel32.dll. Thanks in advance, trellow...more >>

displaying unicode encodings (ie 0x73 type notation)
Posted by groove NO[at]SPAM hush.ai at 12/30/2003 6:20:02 AM
I'm trying to write a basic tool to convert strings to unicode encodings. Should be easy enough, I can do the encoding bit with the various encoding tools in C#, but what I can't seem to do is force C# to spit out the encodings - everything I've done just seems to decode the unicode and spit out...more >>

Putting a progress bar
Posted by Jose Lopez at 12/30/2003 5:47:10 AM
Hi, My program sometimes takes a little time. How can i put a progress bar to indicate to the user the progress of the job? Thanks in Advance. Good next year. Jose Lopez ...more >>

Invalid Argument
Posted by Pradeep MM at 12/30/2003 5:34:07 AM
Hi Folks, I have a issue in Micosoft Jet 4.0 OLEDB. I am doing a repeated append of data into Microsoft Access 2002 (XP). For a few files I get the error as INVALID ARGUMENT. When I try to append the same data independently, I dont get the error INVALID ARGUMENT. Any of you have co...more >>

Listening to traces exhibited by other application
Posted by Vinay at 12/30/2003 2:55:20 AM
Hi I want to listen to traces exhibited by other applications. Can some one help me and let me know how to do it? Can TextWriterTraceListener class be used from outside application to listen to traces? Thanks, Vinay...more >>

Excel Range...
Posted by Josema at 12/30/2003 1:22:55 AM
Hi to all. Im making a program that pass all the data from a sheet of excel to html. I would like to know how to take all the data from the sheet, cause mi program must calculate the number of rows and colums that are filled... Any clue for this newbie? Thanks in advance. Regards. ...more >>

HTTP Webserver - tcp thread issues
Posted by Microsoft News at 12/30/2003 1:07:48 AM
Hi, I have been using several http server code examples from the web, include one from msdn, and I can't seem to get a simple http server thread working. I can connect the server successful using IE6 and following url: http://127.0.0.1:5050 But when I attempt a second connect the windows symb...more >>

Stored Procedure Defination from C#
Posted by DIA at 12/30/2003 12:44:44 AM
Can we find the defination of a SQL stored procedure using c#? 1. Using SQL-DMO in c# I was able to locate a SQL server in the network. 2. Hit the target database in the selected server. 3. Get object of SQLDMO._StoredProcedure class point to the stored procedures which i need to refer. ...more >>

Stored Procedure Defination from C#
Posted by DIA at 12/30/2003 12:44:06 AM
Can we find the defination of a SQL stored procedure using c#? 1. Using SQL-DMO in c# I was able to locate a SQL server in the network. 2. Hit the target database in the selected server. 3. Get object of SQLDMO._StoredProcedure class point to the stored procedures which i need to refer. ...more >>

Context menu in Combo Control
Posted by Abhi at 12/30/2003 12:30:46 AM
I've created a class "MRP123MenuItem" derived from inbuilt MenuItem class to give customized look and feel to the user. I've created context menus for different controls using mine MRP123MenuItem's and it all works fine except for ComboBox control. It only displays a strip of context menus...more >>


DevelopmentNow Blog