Software Development Network Logo
  • Smart Devicet
  • Visual C#
  • VS Team System
  • SQL Server
  • Windows Vista
  • .NET Development
  • SharePoint Products
  • Visual Studio
  • Visual FoxPro
  • IE Development
  • Visual Basic
  • Microsoft ISV
  • Audio and Video
  • Windows Forms
  • Visual C++

Software Development Network >> Visual C#

Visual C#

New Question

Merge sort code
how do I code if radiobutton2 is checked then answer=9;
Obivous oversite?
Why can't an interface method be internal?
Plugin tutorial
No Insert on my Menu VS.2003
adomdClient
Picking at random, with varied probabilities
From SqlDataReader to DataGrid
reference object not updated

Top Answerers

Wojtek
Corey Bornmann
GoDaddy
MSP.Saami
rfsmason
Anonymous X
Michael Morris
Jasmine2501
MikeBzz
Rik78
DDC-I
Only Title

Answer Questions

  • Jon Braganza using vb6 component ?

    Hi, Is there a way to use vb6 components in C#, just like in old asp (Server.CreateObject)... I tried with Activator.CreateInstance but didn't worked...is continue to as kfor the reference... Good Morning!! Have you able to get the desired results According to you what could be the reason of the exception. You said, it is not about casting, right. Have you able to figureout something. Hey, I am back again!!! Have a look at following article http://www.codeproject.com/csharp/usecomappincs.asp The late binding section should help. Excerpt for the article We have Get IDispatch Interface using Type.GetTypeFromProgID( "Project1.Class1" ) We have to create instance using the type ID Activator.CreateI ...Show All

  • 2162 What is the difference between debug mode and release mode?

    Can anybody help me with the difference between release mode and debug mode!! I have no idea of what they are and their significance. From debug mode, it stll gives the same error. How do I install .Net Framework Thanks Also, changing from Debug to Release mode can screw up directory access, I've noticed. I had an application that always accessed a particular subdirectory. Always worked great until I changed to release mode and did the build. Maybe someone can explain why Also, I have a question for the release. After I release my project, the executable file is only run with the machine that I compile it. If I take that file and run with a different ...Show All

  • becklighter Create a function that takes a Property and a Value as a parameter

    This might be a little out there, but lets say that I really want to pass a property of a complex class to a function that will assign the property a value. Example: Private Void AssignValueToProperty(Property property, Object Value) { property = Value } Form1_Load() { AssignValueToProperty(This.BackColor, Color.Red) AssignValueToProperty(This.Text, "Form1") AssignValueToProperty(This.Size, new Size(500,500)) } Is such a function possible, maybe using tools like reflection can someone post a quick example of how I would do this not quite sure what you mean. you can use the public properties approach. Example:   //top of class, global variable declaration: private string theName = String ...Show All

  • dotnetsekar I have a really newbie question on scope

    Under C I would do something like “const int Max = 25”, And place this in a header file which I #include in all the C files, so the whole application had scope to Max. I know I have to use static and C# doesn't have include files, so where do I put it so the whole application h as scope to it (Max=25), without physically coding it in every file You could also use static classes, so you dont have to instantiate a class every time you need to get static, constant values. //using C# 2.0 public static class Constants {      public const int MAX = 25;      public const int MIN = 0;      public static double _2pi;    ...Show All

  • Wee Bubba How can I add a tooltip to a button?

    ... I have a button with no text, but I want to add a tooltip that says "Seek". How can I add a tooltip to a button Thanks, Hi, in the designer: 1- add a tooltip to your form 2- add a button to your form 3- select the button and go to properties 4- scroll down till you see Misc: ToolTip on nameOfYourToolTip (this will only appear after you add a tooltip to the form 5- add some text and that's it in code: Button button1 = new System.Windows.Forms.Button(); Tooltip toolTip1 = new System.Windows.Forms.ToolTip(); toolTip1.SetToolTip(button1, "test"); ...Show All

  • Carel Greaves I have a text file(sample.txt) with 2 lines of data.

    I have a text file(sample.txt) with 2 lines of data. (i.e) MSH|^~\$|ADMIT|CLAY COUNTY MEMORIAL|| (line 1) EVN|A01|200502110909|| (line 2) I have split the line 1 into segments such as MSH ^~\$ ADMIT CLAY COUNTY MEMORIAL I have written these values into xml file. Similarly I have also split line 2 into segments such as EVN A01 200502110909 Now I want to write these segments into another xml file. But I want to write both line 1 and line 2 at the same time into different xml files. How can I proceed with I am using the following code: Dim filetoread As String filetoread = Server.MapPath("sample.txt") Dim filestream As StreamReader filestream = File.Opentext(filetoread) Dim readcontents As String readcontents = f ...Show All

  • prasad_8104 vs2005 designer fails to open form converted from vs2003

    I have about a dozen of so projects that all share a number of menu click processing functions, which are implemented in the base class. Under 2003, it worked out fine. But I am getting "The *** method cannot be the method for an event because a class this class derives from already defines the method" when I tried to use the designer with vs2005. I assume that is by design Is there a way to get around this problem so I do not need the functions in all projects Have you had any luck getting this to work I've run into the same problem and am just now starting to explore my options. Dave, I'll ask around to find out whether this is by design (and why). For ...Show All

  • Lord Arokh In the .net class framwork, there is a number of class ,Is there any best practise to get familar with these classes?

    In the .net class framwork, there is a number of class such as System.Runtime.Remoting etc, Is there any best practise to get familar with these classes I want to know where can i get all the sample programs to be familar with the .net class library. I appreciate your help. use the following site: http://www.codeproject.com they have a lot of artclise from beginners to experts and you can browse them by technology, language, and so on. refer to the docs! :-) ...Show All

  • Joe Sanders "The parameter 'sectionGroupName' is invalid"

    I'm trying to create a dataset. I have my database connection set up correctly, but when I try to pull the table into the dataset designer, I get the following error message: Failed to merger object(s). The parameter 'sectionGroupName' is invalid. Parameter name: sectionGroupName. Also, when I try to open the dataset designer for an existing dataset (.xsd file) a blank box appears where the table should be. If I click on the blank box, I get the error message: Mouse click operation failed. Exception has been thrown by the target of an invocation. I've tried searching the KB for these errors but I can't find anything. Does anyone know what could be causing this and how I can fix it Thanks! -Dell Cleaning up the app ...Show All

  • RadAmant0 scheduler like a calender

    hi people, i am writing a sheduler where you allocate engineers to jobs. jobs happen on a specific day and an engineer is not allowed to be allocated to more than one job on the same day. when i move a series of jobs along by one day, how can i ensure that by moving the job (hence the engineer) along, they do not conflict with other jobs that the engineer had for that day am i supposed to load everything into memory and cycle through them are there any shortcuts or techniques for this sort of thing As the scheduler goes on for ever (there is no end date), i would have to check all the way up to the last task. doesn't seem right. I suppose it might be down to the way i arrange my classes. I dunno. just wondered if anyone had any ideas or li ...Show All

  • hazz Object reference not set to an instance of an object.

    Hi, I have this Code (I use .NET FrameWork 2 with Enterprise Library for Data Access and Logging) : try { DbCommand SpCommand = DB.GetStoredProcCommand( "CreateUser" ); DB.AddInParameter(SpCommand, "name" , DbType .String,name); DB.AddInParameter(SpCommand, "city" , DbType .String,city); DB.AddInParameter(SpCommand, "description" , DbType .String,description); result = ( int )DB.ExecuteScalar(SpCommand); } catch ( Exception ex) { Logger .Write(ex); throw ex; } I Get This Error : Exception Details: System.NullReferenceException: Object reference not set to an instance of an object. Source Error: Line 54: { Line 55: Lo ...Show All

  • alex_hristov Problem implementing 'CodeDomSerializer' on custom control

    Hello, I have a control which have member of type 'List<MyCustomItem>'. I wanted to generate this property by myself using 'CodeDomSerializer". Todo so i created a class 'MyCustomList' which inherit from 'List<MyCustomItem>'. I added attribute 'DesignerSerializer' which points to a class that inherit 'CodeDomSerializer". i override the Serialize method and returned 'CodeStatementCollection' object. The code serialized great in method 'InitializeComponent' and looks something like: this.MyControl.MyCustomCollection = new Sakal.MyCustomList(); this.MyControl.MyCustomCollection.Add(New Sakal.MyCustomItem()); this.MyControl.MyCustomCollection[0].DataType = "car"; this.MyControl.MyCustomCollecti ...Show All

  • Ahoapap No Overload error help

    I'm creating a TreeView at runtime. This tree loads, the app populates it from a database and the child nodes are updated correctly. However, I'm currently getting this error after adding a line of code that would handle any node selection: Error 1 No overload for 'OnTreeView_AfterSelect' matches delegate 'System.EventHandler' I've created an instance of the TreeView at the class level and added code to create it and add it to the form at run time. The error occurs when the build gets to the highlighted line in the code below. I have read thru the MS online help concerning this and I'm very confused because according to all of the samples I've come across, I'm doing everything right. I know there must be something I've missed. ...Show All

  • Kimball Detecting service pack?

    How can I programmatically detect which service pack has been installed on the client machine I didn't see anything about Windows XP Service Pack in your original post either ;) Anyway, call GetVersionEx , passing a OSVERSIONINFOEX structure and checking the wServicePackMajor and wServicePackMinor values. http://support.microsoft.com/default.aspx kbid=318785 http://blogs.msdn.com/robvi/archive/2004/02/17/75272.aspx This is helpful; but I'm not seeing anything that says it's detecting Windows XP Service Pack 1. How would I do that programmatically Thanks for the help. Whew! Working with unmanaged interops is kinda out of my league at this point. Is ther ...Show All

  • pateramj Getting Exception in executing "informix" query through C#.net

      Hi,           I am using C#.net to access Informix database through oledb provider.          I am executing simple query "insert into prnque(rundate) values('11/02/2006')" using oledbcommand, where "prnque" is one table and "rundate" is one column of type date. But i am getting one Exception IErrorInfo.GetDescription failed with E_NOINTERFACE(0X80004002) .           If i use this query in informix query box it is working fine. So Plz give me some suggestions.......... Thank you, Hi Premal, Have you found any resolution for this error. I ha ...Show All

123456789101112131415161718

©2008 Software Development Network

powered by phorum