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

Software Development Network >> Visual C#

Visual C#

New Question

IE toolbar
Windows Service will not run on Windows 2003 Server
byte array to bitmap
Exported Class
Switch question
HOW TO Convert DataReader To DataSet
Search for Substring in AutoCompleteStringCollection()
Generic-question
input data to website
Looking for Good Summary on Organizing Win Forms Solution

Top Answerers

indersunny
Kolf
CJW99
TA123
Keith Henkel
wimpi
detzX
Thibaud
justing1975
smeets116
Interferenza
Only Title

Answer Questions

  • Thaya Dynamic array of floats?

    Hello all, I've consulted several books on C# but haven't found a suitable answer to the following: How does one create a dynamic 1 and 2-dimensional array of floats that can be resized at runtime based on some user-selectable parameter WITHOUT using ArrayList In my past C++ days I've always just used the looped " float** " approach. My requirement now is to pass this C# array to a legacy C++ DLL using P/Invoke...I understand it's tricky using this mechanism and therefore want to avoid collections (ArrayList) and stick with something simple - the unmanaged function call takes a float** argument. Thanks for any and all help! I would be tempted to say "use a generic list": List< ...Show All

  • John Woodiwiss SP2 causing error?

    I have a project that is having issues with SP2. It is a browser that was created to incorporate encryption and decryption protocols. I have done some minor fixes to the code since it was originally made, on my machine with SP2; now, the browser has exceptions on machines still running SP1 with the Explorer 6 browser object. In order to recompile this application to run on these older machines, do I need to remove SP2 from my own machine, or does anyone know of a workaround Thanks I'm sure willing to try; but my application is comprised of several different solutions at this point (I'm working on putting them all together in one solution, but running into compilation errors because of output ...Show All

  • Richard Carmel DateTime Problem

    Hi, What’s the best way to calculate and return two DateTime values in C# .NET for the below examples: Return Beginning and End Date of a week given a Date {i.e. Date given: Wednesday 17 th January 2007, Beginning Week Date: Monday 15 th January 2007, and Ending Week Date: Sunday 21 st January 2007} The same again for the month. And same again for the year Thanks Hi, Testsubject Since begin with Monday and end with Sunday, the code can be:             DateTime dt = new DateTime (2007,1,17); Week:             if (dt.DayOfWeek != DayOf ...Show All

  • pnb Generics Problem

    Hi, I am having a problem with overloading generics. I cannot do this: Usually in C++ I do this, thi s in the hdVector3D class: operator T*() { return &m_p[0]; } Where: private: T m_p[3]; Where T is the template.So in my main C++ program I do this: hduVector3D<double> position; hdGetDoublev(HD_CURRENT_POSITION, position); Where the type of hdGetDoublev is: hdGetDoublev(unsigned int pname, double * params); So what I have done above is that whenever I do hduVector3D<double> position, I can place it inside the double * params. I wish to do the same within C#. I have done my C# interop and it accepts this: [DllImport("hd", EntryPoint = "#10")] public static extern void hdGetDoublev(uint pname, Do ...Show All

  • CMU Writing to multiple files

    Hi, I want to read in a file which contains words ending with ';'. And after that, i want to write the content of it to multiple files. Depending on what the letters the word contains. Suppose the word is 'reader'. Then i want it to cute and paste this word to a doc called "EA-words". I declared and created the files. And i read in the document called "mixedwords.txt" and put its content to an arraylist. This is as far as i got: //declared 15 files to write to. while((linesInArray = sr.ReadLine()) != null) { compareLines.Add(linesInArray); } Anyone any ideas Thanks in advance! you can use the .Contains method to check if a string has a particular character/string in it. foreach ...Show All

  • spi Create a non-existing file in OpenFileDialog

    Can I do this Thanks! Not directly... but then that’s not it’s job. What is it exactly you are trying to do If you want to be able to have a user specify a file that does not exist yet you may want to consider using the SafeFileDialog instead, or set the OpenFileDialogs CheckFileExists property to false. ...Show All

  • enric vives How to tell the difference between windows 2000 and windows XP in .net

    I am developing a class library in C# and it uses Win32 API calls that are only available on Windows XP or later. I would like to detect the OS and provide an alternate code path for Windows NT and Windows 2000. The OperatingSystem.Platform returned from Environment.CurrentOS does not allow me to tell between the different versions and the values used for OperatingSystem.Version do not appear to be documented. At least I could not find them. Does anyone know how I can get this info from the .NET framework in C# I could make additional API calls to figure this out but I cannot understand why MS would have created an Environment.CurrentOS property that does not provide this information. Thanks You ar ...Show All

  • arcintl Parameter mismatch when using Invoke method on overloaded method

    Hello, I am having some trouble adding a new row to a DataGridView from a different thread to which it was created. Basically this is the code I am using: public delegate int DataGridRowAdd ( params object [] values); public void OnMessageRecevied(_SMSMessage SMSMessage) { if ( this .SMSRXGridView.InvokeRequired) { DataGridRowAdd RowAdd = new DataGridRowAdd ( this .SMSRXGridView.Rows.Add); object [] args = new object [5]; args[0] = this .SMSRXGridView.Rows.Count.ToString(); args[1] = SMSMessage.SMSOrigin; args[2] = SMSMessage.SMSMessage; args[3] = "Accept" ; args[4] = "Reject" ; this .In ...Show All

  • Hervens Struct Problem

    I am trying to write a similar struct to the System.Drawing.Colour struct, ie I want to be able to do the following. BarColour bc=BarColour.White; How do I get the BarColour struct to return a BarColour struct from within a static public property which is instantiated with a colour without the struct having a public constructor. I have the following code so far:- struct BarColours { private string _colour; public static BarColours White { get { _colour= "White" ; BarColours bc = this ; return bc; } } public static BarColours Black { get { _colour = "Black" ; Ba ...Show All

  • LORD ORION How to make a tabpage invisible from user?

    Help Thank you very much. this.tabControl1.TabPages.Remove(this.tabPage2); ...Show All

  • InfiniZac Code Snippets NOT inserted from Intellisense

    If I select a code snippet in Intellisense and use a completion character and press <TAB> the code is not inserted. I have read http://support.microsoft.com/kb/913452/en-us but this does not apply - even the "built-in" C# snippets such as "prop" or "for" are not inserted. This happens on 2 different PCs running Windows XP. (The code snippet pickers works fine on both PCs.) Any thoughts cheers Andrew I have to hit the Tab key twice for prop template... and it gets inserted with it waiting for me to add text. Do you have a specific snippet in mind or one you have created Here are my steps to use prop, just so we are on the same page. ...Show All

  • Jamie Wood Subtracting Times with Date

    I thought this might have been a simple task...I need to subtract 4 hours from the current datetime that is input.  The datetime format is mm/dd/yyyy hh:mm and the hours are a 24 hour clock.  After it's input, I then take and parse this string into a strDate array and strTime array by doing args[0].split('/') and args[1].split(':').  After this is where I try to subtract the 4 hours, but there's a whole lot to account for as in if the hour is 1, you'd have to go to the previous day and if the day is the first day of the month, going back one day would take you back another month, etc.  Is there an easier way to do this   The month is really what's throwing me.  Thanks in advance for the help! ...Show All

  • MPSIperson Queue in c# for SerialPort communication...

    Hi... I want to use FIFO queue concept for PC serial port communication through PC com port for data transmission & reception. Can anybody suggest me any good document available on net for this or any suggestion how i can use it in my application... Thanks, Vinay The Queue class in .NET can be used for what you want. However without more information about what you want to enqueue I'm not sure what you'll do. Serial ports do not necessary send all the bytes of a request in a single packet so it is possible that you'll get multiple events for a single block of data you care about. A Queue might not be the best way to go here. However assuming that you build workable data from se ...Show All

  • Astek djacquet KeyPressed eventhandler

    Hi, I was wondering why i can't use a keyPressed eventhandler in a console application. It keeps saying that im missing an assembly or a using directive. The console application does not recognize the System.Windows.Forms directive. So is there any other way to us that eventhandler Thanks in advance! If you are using .NET 2.0 the Console class underwent a significant upgrade. The Console class doesn't use events like Windows applications do, you need to call ReadKey in a loop and process each key as required. If you search MSDN for ConsoleKeyInfo there is a quite good example. You can't because obviously all text will be typed into the console, so theres no reason t ...Show All

  • edukulla doubt in FOR loop urgent .

    DateTime sdate=Convert.ToDateTime(amcsdate.Text); DateTime edate=Convert.ToDateTime(amcedate.Text); DateTime i; for(i=sdate;i<=edate;i=i.AddMonths(1)) { Response.Write(i); } above coding works fine . how to store the values of i in different variable like d1,d2,d3 etc. Example : sdate = jul 03 2006 edate = jul 03 2007 now i want to store the value of i in d1,d2,d3,d4.........etc till i <= edate . after getting the values of d1,d2 etc i will be storing in database . my table format : d1 d2 d3 d4 etc ............ jul 03 2006 Aug 03 2006 Sep 03 2006 Oct 03 2006 If you're using C# v2.0, then instead of using ArrayList you could use List<DateTime ...Show All

575859606162636465666768697071727374

©2008 Software Development Network

powered by phorum