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# > november 2005 > threads for monday november 28

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

Best way to print a HTML file?
Posted by David Templet at 11/28/2005 11:35:01 PM
I have a C# application that generates its reports in HTML. After it creates the report, it opens it in IE so it can be viewed or printed. I would like to add the ability to print the report directly from the application, but I haven't found an easy way to do this. I am probably making it o...more >>

Difference between type castings?
Posted by Benny Raymond at 11/28/2005 11:09:19 PM
I'm starting to see a lot of "somevar as sometype" Just cause i'm curious, what's the difference between that and (sometype) somevar ?...more >>

Uninstallation problem in window sservice.
Posted by archana at 11/28/2005 10:58:42 PM
Hi all, i have created windows service in c# .net. But at a time of building setuo of that service i forgot to specify uninstall action in custom actions. Because of which even if i tried to uninstall the service it is not getting removed from service control manager. Can some one tell m...more >>

How to set first column's property of header row?
Posted by Grace at 11/28/2005 10:47:04 PM
I use a datagrid included in a repeater. as following: (.aspx) <asp:repeater id="rp_perform" Runat="server"> <HeaderTemplate> <table border="0" bgcolor="gray" cellspacing="0" cellpadding="0"> </HeaderTemplate> <ItemTemplate> <tr bgcolor="white"> <td width="100%"> ...more >>

Sending Email
Posted by Ant at 11/28/2005 10:31:03 PM
Hi, I'm using the MailMessage & smtpMail classes in System.Web.Mail to send mail, however it's not sending any emails. I'm using it on a Windows 2003 server. The simplest way to use this is smtpMail.Send("from@here.com", to@there.com, "Message subject", "Message Body") I'm sending it ...more >>

Calling COM DLL interface function at run-time
Posted by Meya-awe at 11/28/2005 9:38:19 PM
I am using C++ unmanaged code, given a string to function name, i need to be able to call the DLLs COM interface with the same name. How can i do this in C++ unmanaged code? thanks, BRAMOIN *** Sent via Developersdex http://www.developersdex.com ***...more >>

Why doesnt textbox print or var change?
Posted by Brad Rogers at 11/28/2005 8:47:49 PM
All, Being immersed in vb.net and trying CSharp after almost a year I forgot the differences. I like vb fixing the uppercase/lowercase names and seeming to be more flexible to code entry. But while trying to insert a text box to see when a method is used, and putting a counter to bump some...more >>

How to expose an enum
Posted by Ant at 11/28/2005 8:12:05 PM
Hi, Im wrapping a MailMessage object & need to expose the Priority property. This property is set to a value of the 'MailPriority' enum. My question is, how do I create a member that accepts this enum as a value? as a field named Priority: public MailPriority Priority; //doesn't work S...more >>



Street address.
Posted by Zeya at 11/28/2005 6:43:37 PM
I need to find and replace US street address from HTML files in C# into something like this: [Some string: street address] street address [Some string2], how can I do this using C# and Regular expression? Thanks. ...more >>

Q: Translation of VB Code, total brain melt down...
Posted by Visual Systems AB (Martin Arvidsson) at 11/28/2005 6:20:20 PM
Hi! I have this line of code in VB that i am trying to get to C# But my mind is completley blank... New HookProc(AddressOf TheHookProc) How is that translated into Visual C#? Any ideas Regards Martin ...more >>

Making a transparent gif can't REALLY be this hard, can it?
Posted by RCS at 11/28/2005 6:10:49 PM
I'm working on an ASP.NET webpage that generates an image (and am using VWD 2005 until my copy of VS2005 ships). I have done all the obvious (and not-so-obvious) things to try to give a gif that I am generating, a transparent background. On the newsgroups - everyone points to this MSDN arti...more >>

subdirectory of another
Posted by colson at 11/28/2005 6:03:41 PM
Is there a function to find out if directory B is a sub-directory under directory A? Thanks for your answer ...more >>

Another C# marshaling question
Posted by Laurent at 11/28/2005 5:57:17 PM
Hi again, I created a thread some days ago, while I was trying to access a C++ DLL using my C# program. First of all, I want to thanks all the guys who helped me. But I still have a problem... My C++ DLL has a function which has the following prototype: long FF_Function(v...more >>

MDI
Posted by Maarten at 11/28/2005 5:55:26 PM
Hi, I have an MDI interface. In the parrentform i can open multiple childforms. form program1 form program2 form program3 .... like this DocNum++; Worksheet.Text = "Document " + DocNum.ToString(); Worksheet.MdiParent = this; Worksheet.Text = "Program " + DocNum; Worksheet.Nam...more >>

How to include .net framework in the Setup Projects created VS 2005
Posted by S.Creek at 11/28/2005 5:45:58 PM
Hi, I am trying to create a setup project and would like it to contain the ..NET 2.0 framework, so user will not need to download it in his installation. does anybody know how to do that with VS 2005? VS 2003 needed the bootsstrapper add in, is is the same here, or did Microsoft add more...more >>

settings designer - can't find my types
Posted by Tim Mulholland at 11/28/2005 5:06:01 PM
I am setting up all my settings using the built-in settings stuff in Visual Studio (though using my own provider to change the storage location/type for the settings). All goes well until i try to set the Type of one of my settings to something that is in my current project. Types in the cu...more >>

Generics
Posted by Gene Vital at 11/28/2005 5:05:17 PM
Hi all, I need some help in understanding how to use Generics. I have a class based on a user control that can be put on any Container at runtime, I want to be able to call a method on the parent class without knowing the type of the parent class, can this be done with C#? I thought t...more >>

Copy of List<>
Posted by Brian Pelton at 11/28/2005 4:41:13 PM
I am not sure how to fix this problem I've stumbled into... I have a list<> of an interface type. I need to pass that list to a method that adds more objects to the list. But, eventually, I need to get back to the original list<> object. --- In other words; let's say I start with an...more >>

Data Grid question.. SIMPLE!
Posted by B. Cavour at 11/28/2005 4:09:49 PM
Ok, I need the first row/colum cell's text to be highlighted when the forms starts. I know how to get cell & row to highlight, BUT, I just need the Text to highlight. Any ideas of where to look for this property? ...more >>

dynamically compiled c# code - is it debuggable in 2.0?
Posted by Benny Raymond at 11/28/2005 3:57:02 PM
Does anyone know off hand if dynamically compiled C# is debuggable in ..net 2.0?...more >>

Simple Meta Search Engine
Posted by sb Luis at 11/28/2005 3:54:57 PM
Hi, I want a class whitch can get the result of famous search engines (yahoo, altavista,...) and show them. thanks in advance. Luis. ...more >>

Enum and generic IComparable interface
Posted by Stefan L at 11/28/2005 3:52:49 PM
Hi everybody, when migrating to the .NET 2.0 framework we decided to encourage the use of generic functions because they ought to run faster than their equivalent object-implemantations. Now I have the following problem: I adapted my common functions to use the generic implementations of ...more >>

Why where new() doesn't allow parameters?
Posted by Lasse_Vågsæther_Karlsen at 11/28/2005 3:26:32 PM
Ok, I realize that it doesn't really matter because it simply isn't possible, but does anyone know the reason why the constraint on the generic parameters for new() doesn't allow parameters? Ie. why isn't this allowed: public class Collection<T> where T: SomeBaseClass, new(Session) to m...more >>

Limit App to 1 Instance (Per File)?
Posted by Mario at 11/28/2005 3:15:02 PM
I have a C# app that runs script files. The app is launched using a command line argument to indicate which script should run. Most scripts are run indefinitely in a loop and periodically perform tasks. When the script is launched the Title Bar of the app indicates the name of the app and the n...more >>

TransparencyKey for MDI child
Posted by Derrick at 11/28/2005 3:14:46 PM
Hello all; I have a form with the Background color and TransparencyKey set to the same value. When I run this as a Windows App, everything works as it should. However, if I change this project's output to DLL and try to host the same form within an MDI container, the transparency does not ...more >>

KeyCode, KeyValue and KeyData
Posted by Alberto at 11/28/2005 3:06:57 PM
Could you tell me witch is the difference between keycode, keyvalue and keydata in a keydown event? keyvalue is always the ascii code? thank you ...more >>

change toolstrip button colour when button pressed
Posted by Mel at 11/28/2005 3:04:05 PM
Hi, Is there any way I can force to change button background colour when toggle button is checked? Just like button change its background colour when mouseover in MS Visual Studio.NET. I hope I can get my question answered. Thank you very much....more >>

Extending objects at runtime
Posted by James at 11/28/2005 2:51:06 PM
Hi, I've been trying to figure this out for a while and can't find the answer. For simplicity I will use a basic example rather than my real classes. I have one base class, Item and various extended classes which inherit from Item, ExtendedItem1, ExtendedItem2, etc. As expected, Item defin...more >>

Help with WndProc
Posted by Derrick at 11/28/2005 2:39:08 PM
Hello all; I'm trying to create a UI that's a little atypical. In the main form's Paint event handler, I draw an image on the form - this is what I want to by my "real" UI. I turned off the form border, and set the form's background and transparency key to be the same value. As you know,...more >>

DataSet.ReadXml
Posted by C Glenn at 11/28/2005 2:38:55 PM
I'm attempting to use ReadXml. It's working in that I end up with some data in the DataSet. But I'm not able to deal with it effectively after that. The XML file is properly formatted in that it was created with WriteXML, so it contains the name of the table (I've inspected it to be sure)....more >>

Asynchronous Serial port
Posted by shayke via DotNetMonster.com at 11/28/2005 2:26:25 PM
Hello, I am trying to write asynchronous serial port. meaning, read and write operations are made via async cllbacks. so far so good. I open my port in continues state: 1)Set the BytesToRead property of the serial port. 2)open the port 3)generate read request 4)meanwhile generate write req...more >>

Q: Can you use a Class Library in another environment than Studio?
Posted by Visual Systems AB (Martin Arvidsson) at 11/28/2005 1:58:14 PM
Hi! Is it possible to use a .NET Class Library in another environment. I have this 4GL, you can use regular DLL's there, but is .NET Class Library made for the .NET Environment only? Regards Martin ...more >>

FAQ: VS 2003 and 2005 running together
Posted by Rene at 11/28/2005 1:37:56 PM
I am still waiting for my copy of VS 2005 that I ordered about 2 weeks ago. When I finally get VS 2005, I will want to continue to run my projects using 2003 and at the same time I want to make a copy of my currently projects and upgrade them to VS 2005 and .Net 2 to make sure everything works...more >>

Interesting file managment feature of VS2005
Posted by Kevin Frevert at 11/28/2005 1:13:54 PM
In the process of learning VS2005/C# (having a background in Borland Delphi 2 through 2005) I came across an interesting feature of Visual Studio's file management. At first, it appeared there wasn't a way for me to 'share' common business objects (ex. \Projects\Objects\Customer\CustomerObje...more >>

Tables.CanRemove
Posted by C Glenn at 11/28/2005 1:05:17 PM
I'm doing this: if ((this.Tables.Contains(dt.TableName)) & (this.Tables.CanRemove(dt))) { this.Tables.Remove(dt); } and my table is not being removed. Which is fine, I guess. The things is, I don't know why. I have confirmed that it is the second portion of the boolean that's...more >>

read user section from config file to drop down list
Posted by Antonio at 11/28/2005 12:43:27 PM
Hello, in my web.config file I have <?xml version="1.0" encoding="utf-8" ?> <configuration> <appSettings> <add key="a" value="aaa" /> <add key="b" value="bbb" /> </appSettings> <system.web> .... I want to display in a drop down the key data. How do I loop through the a...more >>

Write to DebugOutputString in Debugging Mode
Posted by tobi at 11/28/2005 12:37:04 PM
Hi NG, how can i write to the DebugOutputString while running my app in debugging mode? I want my app to write always to the DebugOutputString and never want VisualStudio to catch the Debug.WriteLine calls, so that i always see the the debug output in DebugView. thanks tobi ...more >>

MDI Tab controls
Posted by Brian Henry at 11/28/2005 12:13:58 PM
Does anyone know of a good control or source code that will create MDI like tabs like you get in .NET or Office OneNote? preferably with out having to have a MDI client on the form? thanks! ...more >>

SOAP Performance - Really so slow ?
Posted by frankgerlach NO[at]SPAM gmail.com at 11/28/2005 12:06:06 PM
>From my simple performance tests of SOAP it seems that it is about ten times slower than binary object request protocols such as RMI, IIOP or SimpleORB. Is this also YOUR experience ? ...more >>

Reflection Doubt!
Posted by Vai2000 at 11/28/2005 11:51:18 AM
Hi All, I am using Reflection for invoking an assembly.I use the LoadFrom(string) Method, have few doubts, will appreciate all your answers. 1. Should the assembly resides in GAC or at my custom location? (Please tell me pros/cons) 2. If multiple calls are made to the target assembly by a Mult...more >>

Parsing percentage % to double
Posted by Mike9900 at 11/28/2005 11:51:10 AM
I use this code, but I get exception: String num = "29%"; System.Globalization.NumberFormatInfo ni = new System.Globalization.NumberFormatInfo(); ni.PercentSymbol = "%"; double nums = double.Parse(num, System.Globalization.NumberStyles.Any, ni); Is there a way to parse the percent value b...more >>

How can I check if a type is nullable with reflection?
Posted by Narshe at 11/28/2005 11:34:29 AM
How can I check if a type is nullable? If a type is created like bool? = null;, then how can you tell if the type is nullable as opposed to not? You have to cast from bool to bool? and such, so I'll need to know if a type is nullable. -Josh ...more >>

Emails seemingly disappearing.. very strange problem
Posted by Chris Ashley at 11/28/2005 11:14:10 AM
I have been tearing my hair out (or indeed, what's left of it) all day with this one. I'm not sure if it's a .NET issue, a server issue or anything else and would appreciate any guidance. Basically, I have a web app that sends emails. Very basic code, nothing fancy, and I have had it working o...more >>

How to convert an access database programmatically using C#?
Posted by Jon S via DotNetMonster.com at 11/28/2005 10:41:54 AM
Hi all, I would like to convert an Access '97 database to Access 2002 format pragrammatically using C#. How would I do this? Thanks in advance. -- Message posted via DotNetMonster.com http://www.dotnetmonster.com/Uwe/Forums.aspx/dotnet-csharp/200511/1...more >>

Chat: The C# Language, December 1st @ 1pm Pacific Time
Posted by Scott Nonnenberg [MSFT] at 11/28/2005 10:17:44 AM
The C# Language "Want to know more about anonymous delegates in C# 2.0, or our design rationale for them? Have some questions about our current thinking on C# 3.0? Perhaps you'd like to share your ideas with other C# users or the C# language team. Join the C# team for all that and more - it's...more >>

VS2005/c#2.0: enum and user control problems
Posted by Mike at 11/28/2005 10:16:01 AM
I'm using VS2005 beta 2. (1) It looks like "foreach" is looking for an IEnumerable only, and not an IEnumerator. That means that class I use in the interation has to have GetEnumerator(), rather than supporting the IEnumerator protocol (incl. automatically created generator class using "yi...more >>

Help pls how to call .net dll from Delphi
Posted by Raghu Raman at 11/28/2005 10:06:46 AM
Hi , I have written a .net dll and i want to call this from Delphi. Please tell me the procedures and examples that helps me to call the ..net dll from Delphi. With Thanks Raghu On His feet.. *** Sent via Developersdex http://www.developersdex.com ***...more >>

Is there any Vector in C#???
Posted by Jefe at 11/28/2005 9:31:07 AM
Hi group I want to translate my program from C++ to C#, I used STL vector in my C++ program but I wonder what data type should I use when I want it to act like a STL vector, but I don't want to use System.Array class!!!!! Regards, ...more >>

Code Busy Message
Posted by Tim at 11/28/2005 8:58:05 AM
Hi, I am looking for a more elegant solution to the wait cursor. There are some places in the software I have created where there is a few seconds lag where the DB processes requests and sends back the data. Right now I have used the wait cursor, but I would like to popup a form or somet...more >>

LDAP question
Posted by Rob at 11/28/2005 8:50:38 AM
Hi everyone, I have a task to do on our current existing website wich is a .aspx+C#. What I need to add, is to create an authentication form and then based on user's privillage give him ability to view some pdf documents. So I was wondering if C# is the right language to do this task and also...more >>

most efficient mechanism(s) for packing/sending/unpacking data through a webservice for a smart client.
Posted by hazz at 11/28/2005 8:22:04 AM
if I think about efficiently sending data back and forth through a webservice for a 'typical' application (in this case smart client using Composite UI application block) what questions do I ask that would point me toward the optimum mechanism(s) using XML as the payload vs. serialized hydra...more >>

System.Timers.Timer performance test ?
Posted by logdenav NO[at]SPAM hotmail.fr at 11/28/2005 8:00:45 AM
Hello I'm testing the performance of the System.Timers.Timer class. I created a small program that create 100 User objects. Each USer object create a MyTimer object. The constructor of the User class contains a name and a time to wait for the timer. Calling start on the User objet initiate t...more >>

GetEntryAssembly for default appdomain
Posted by Andy at 11/28/2005 7:53:47 AM
Hi, I was wondering if it was possible to get the Entry assembly for the default application domain (and how to determine what the default app domain is..). I'd like to get to it for logging purposes, and it would be nice it the object can discover that one its own, instead of trusting that...more >>

Text Input Problem
Posted by alexmaster_2004 at 11/28/2005 7:40:03 AM
Hi i want to know how i can make the TextBox control just accept numbers and "."; EX: the user can enter "1" OR "1.4" Hope anyone could help Thanks ...more >>

sent time incorrect
Posted by bonokoot NO[at]SPAM gmail.com at 11/28/2005 7:36:48 AM
Hello, I wrote this program in C# that accesses a SQL Server database that runs a stored procedure and sents the results in an email every 30min. I wrote this as a windows application instead of a windows service, so the application is run every 30min through a scheduled task. When the email i...more >>

problem showing focus on a button
Posted by melanieab at 11/28/2005 7:36:05 AM
Hi, From reading something months ago, I've been under the impression that saying button1.Focus() is enough to focus on the button and highlight it (the dotted box). If this is true, I don't know what's wrong with my version, but it doesn't work. In certain circumstances, when a button is d...more >>

Backgroundworker issue
Posted by Ulf at 11/28/2005 6:53:25 AM
Hi, I have some problems with a BackgroundWorker when calling a WebRequest : private void bgrdTask_DoWork(object sender, DoWorkEventArgs e) { e.Result = WebServerRequest((string[])e.Arguments); } the WebServerRequest function simply creates a HttpWebRequest to the uri specified ...more >>

strange problem....
Posted by Erland at 11/28/2005 6:20:09 AM
Hi there, I am using Visual Studio 2003 and trying to write an windows application in C#. Whenever i run my program , it runs normally and i close it. Sometime later, i try to run the program with Ctrl+F5 and i get following errors i)-Could cope temporary files to the output directory. ii)-The...more >>

System.Resources.MissingManifestResourceException
Posted by Dan Neely at 11/28/2005 6:00:02 AM
I'm trying to use an ImageComboBox in my app. The control worked fine in a demo app, but the contructor throws a System.Resources.MissingManifestResourceException with the text: "Could not find any resources appropriate for the specified culture (or the neutral culture) in the given assembl...more >>

Help ! regex problem?
Posted by roopeman at 11/28/2005 5:00:11 AM
any problem of the regex? the code as below is not working ! if just one keyword,such as "Microsoft.*", it 's work well , anybody can help me ,Thanks! using System.Text.RegularExpressions; Regex r = new Regex("[Microsoft.*][KingSoft.*][Symantec.*][Oracle.*]"); if (r.IsMatch(strCoName)) { ...more >>

lock and object passing by ref
Posted by MSDNAndi at 11/28/2005 3:03:08 AM
Hi, I get the following warning: "Possibly incorrect assignment to local 'oLockObject' which is the argument to a using or lock statement. The Dispose call or unlocking will happen on the original value of the local." My code is: using System; using System.Collections.Generic; using Sy...more >>

Closing console in Windows Applications
Posted by Giojo at 11/28/2005 2:42:54 AM
Hello guys! I can't resolve this problem.. I want my programm in c# working with only console if there are some parameters, but if someone make double-click on the exe I want to start the graphic GUI without the black console on background.. Now I check if there are some parameters and if there...more >>

C# Bit problem
Posted by Jason Huang at 11/28/2005 12:00:00 AM
Hi, In my SQLServer 2000 MyDataBase.MyTable, there's one field MyStatus which datatype is Bit(1). So the MyStatus in MyTable is either 0 or 1. Now I have a ComboBox MyCombo in MyForm, and there're two items "Yes" and "No". Where "Yes" represents 0 in MyTable.MyStatus, and "No" represents 1...more >>


DevelopmentNow Blog