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

Software Development Network >> Visual C#

Visual C#

New Question

Compiler error
convert double[] to byte??
curve length & area problem
How to raise an event
Using "Enter" key to leave text box?
Video editing in C#
What is with all of the files for a simple program?
Problem with the ModeCahnged event
"Flags" Attribute -- Useless???
Web services...

Top Answerers

ritzratz
RichardR
Latso
hancererkan
LordZoster
HillBillyB
ManjuVijay
Ronaldlee Ejalu
l Bllizzd l
m_nille
Verivizyon
Only Title

Answer Questions

  • guy87 Creating an Excel in C# having 60 columns and 6000 Rows is taking 20 minutes

    Hi, I am trying to create an Excel file using C#. But I am facing a performance issue. It is taking about 20 minutes to create a 1.5 MB Excel file. And for the 20 minutes, the Server's CPU is being used 100%. I have also tried to optimize the logic. I am using only 2 major for loops. Is this normal for a generation of a huge (60 cols*6000rows) Excel spreadsheet having static data without any logic written to it, to take 20 mins of 100% CPU If so, please give me a link to such an online resource so that I can have some online material for my support. OR Is the code still needs to be optimised. Please help me out in fixing this issue. Thank you in advance. Thanks and Regards, Neelesh ...Show All

  • monkeynova Question on behavior: Casting enum to int

    Consider the following:     public enum Value     {         First = 0,         Second,         Third     }     public void Test()     {         Value value = Value.First;         value = (Value)5;     } I was expecting the line 'value = (Value)5 is going to throw InvalidCastException since 5 is not definied in the enum.  Is this behavior by design PS: This is in .NET 2.0. Yes, it is by design. For the runtime only the under ...Show All

  • fripper Problem with System.Web.Mail

    Hello Everyone, I am trying to write code in my c# windows program to send email.  I found good tutorials online to get this done.  Most of which use the System.Web.Mail namespace.  When I come to write that in: using System.Web.Mail; I get this error: The type or namespace name 'Mail' does not exist in the class or namespace 'System.Web' (are you missing an assembly reference ) I even tried: using System.Web.Util;............but I pretty much got the same error message. When I come to look System.Web.Mail in the help files, I find it there, I just can not use it. Can someone please help me by pointing out what is wrong. I am using visual studio 2003 c# on windows xp home edition.     ...Show All

  • Eugenya Best processors for compiling Multi-Project solutions

    All, I'm working on a Visual Studio 2005 solution that comprises more than 20 projects. It feels like the project is growing faster than the IDE and my computer (P4, 3.4) can cope. It's all a bit slugish, and building and running is taking longer than i would like. My question is whether the compiler's build system would make use of a multi-core processor, especially in a multi-project solution In addition, would a quad core help the building better than a dual core Thanks Pete It is neccessary to create the separate assemblies in this case. I guess my question is about how well the Visual Studio C# build process uses multiple threads to build a solution. If a soluti ...Show All

  • Scott McKeown Export as HTML File

    Does anyone know what code I would use to export HTML code in a Rich Text Box into an HTML file I know in notepad you can simply go to "Save" and then you can save your file as whatever, but you have to add ".HTML" to the end, or it wont export as an HTML file. How do I tell my program to open the "Save Document" dialog for the Rich Text Box and have .HTML document as an output source, instead of having to enter it in the file name Thanks a lot guys! You have been a BIG help. One way would be to create a multi-line textbox hidden (visible=false) behind the Rich Text Box and then copy all the Rich Text Box content into it and then save it using a System.IO.StreamWriter object. In your Save File Dialog ...Show All

  • kakarato Barcode technology

    Has anyone here worked with barcode creation/scanning technology in C# before I'm looking for a best practice with using a specific standard of the technology and maybe some components I could use to generate the barcode image itself. I hadn't really considered just using the font to generate the barcode. I'll screw around with that a little bit and see what I can come up with. Thanks. barcodes are readed with a scanner and this acts as if it is keyboard, only it add standard a return character when it has readed the barcode.. so the program can detect it. Just Focus the textbox before scanning and catch the return key event on that textbox. To print barcodes, use a barcode font.. Just google for "barcode 39 font&qu ...Show All

  • mistys77 random alpha numeric character

    how can i create an a random alpha numeric variable You mean store a random alpha-numeric character in a variable Random rand = new Random(); int randValue = rand.Next(0, 36); char c; if (randValue < 10) c = randValue + '0'; else c = (randValue - 10) + 'A'; That should give you an alpha-numeric character. If you want to include lower and upper case letters, try this: int randValue = rand.Next(0, 62); if (randValue < 10) c = randValue + '0'; else if (randValue < 36) c = (randValue - 10) + 'A'; else c = (randValue - 36) + 'a'; I haven't tested the above code, it may be necessary to do some additional casting. It may be obvious to people who know, I just wanted to point ...Show All

  • pmak Passing type names as parameters

    Is there any easy way to pass in a typename as a parameter, and then create objects of that type. Even better, could I restrict the types to those derived from an abstract class. To be specific, I have an abstract Player type, which is implemented by concrete HumanPlayer, AiPlayer, NetworkPlayer classes. I want to be able to do the following: public void CreateNewPlayer(DerivedFromPlayerClass theType) { theType myPlayer = new theType(); } Is there any way to do this Or am I better off passing in an enumerated value representing the type, and then using a switch statement to create the new object Hey there, Your best off to do something along the lines of: public void CreateNew ...Show All

  • cookieCutter exposing a C# DLL's members to non .NET apps

    Hi, I posted this in another forum (slightly different question though) and the answers I recieved weren't very helpful. Basically, I need to create a C# DLL who's members can be accessed by a non .NET application (it's a Windows program called Extend). Now I was able to write one in C++ and have it's members be exposed using extern "C" int __declspec(dllexport), but so far have been unsuccessful in doing so in C#. Is it even possible Hi pappascd: Although very restrictive, I have succeeded in years past in exposing a subset of native methods from a VC++ class with __declspec(dllexport) without exporting all the members of a class.  This is the poor man's way of exposing an interfa ...Show All

  • Gosovic How to add Image in the MenuItem linked to treeview ContextMenu

    Hi I got a treeview control that display a list of tags., when you right click the menuitem pops up with the list of menus to select. now how can I add images to my menuitems. Your help will be highly appreciated. Thanks a lot , it worked perfect you need to do the following 1. Add ContextMenuStrip to the form. 2. Assisgn context menu to treeview by selecting TreeView and set it's ContextMenuStrip property to name of contextMenuStrip of p1 5. Add items to contextMenuStrip and on each item set value for each item's Image Propery If you need to access images dynamically you can use created variable for certain menu item and set its's Image property Hope this helps ...Show All

  • Andrei Faber HTML code in C#, problems with cotations!

    How can I write this HTML code between double cotations in C# for example: if ( str.Contains( "<img src=" /i/ic0.gif " align=" absmiddle "> <a href=" /cat/") i tried if ( str.Contains( "<img src=""/i/ic0.gif"" align=""absmiddle""> <a href=""/cat/" ) but it didn't work! mcpJim wrote: THX alot. That's a big help. I am wondering if I can have your email contact. I am not Microsoft Support btw, but my email is on my moniker. My hourly rate is high, (as a contract developer) but for the experience of what I bring to the job it is well worth it. <G> -OmegaMan ...Show All

  • young Code Access Security

    I am trying to understand CAS in preparation for exam 70-536. I want to know if a child group can provide more permissions than the parent group.For instance the All_Code group of the machine level have the Nothing permission and the child group My_Computer_Zone have the FullTrust permision.From this, I thought I can restrict the My_Computer_Zone group to Execute permission only and give a child group other permissions. So I have -Machine     -All_Code(Nothing)            -My_Machine_Zone(Execute,UI)                 - TestGroup(FileIO)Evidence file:///E:/bin/*. I creat ...Show All

  • robert12345 Generics: Test for a datatype

    Hello, I want to add special handling for a generic class I am writing. See below: class MyGeneric<T> { private T val; public MyGeneric(int src) { // I want to add customized handling such as this below: if (T is string) val = src.ToString() } } Is this possible with generics The code belos is not exactly what I want to do, but hopefully it gets the point across... I want to have customized handling for cartain types for T. GMagana, you used the cast on the wrong side of the assignment. val = (T)(object) src; P.S. As for the nice formatting... as you can see from my posts I'm not the right person to ask. ;) HTH --mc You're close. Try this inste ...Show All

  • Marcin Ksi&amp;#261;&amp;#380;ek directoryentry

    hi i have a problem with the first argument of this methode directoryentry.Invoke( ); where can i find the methodname that i should post as the first argument what the available methodename Try: obj.Invoke("ChangePassword", "", "NewPassword") Is this stuff working I couldn't try it out myself... hi all my dear friends: i was tired of trying all the ways and see the same exeption . please take a look at my code , that i use to add a user to active directory : DirectoryEntry de = new DirectoryEntry(" LDAP://192.168.0.1/cn=Users,dc=soheila,dc=org ", " Administrator@soheila.org ", "sohama3t", AuthenticationTyp ...Show All

  • Ghassan Rashed moving tools

    help......its friday...its snowing.....i need to go home.... but first I have to fix this I want to use the timer control which is in visual c#. But my app is built in web developer.....how can I get the timer control out of c# and onto the tool bar in web dev .........and it does't drop and drag. I dont mind just getting it on the page, let alone the tool bar. Anybody that can help me with this will be in my praises all weekend richard You can't use System.Windows.Forms.Timer in a web app. You could use System.Timers.Timer but keep in mind that a web app is stateless so as soon as the page request is complete the code goes away. If you have a timer attempting to call page method then chaos will ensue. You ca ...Show All

353637383940414243444546474849505152

©2008 Software Development Network

powered by phorum