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

Software Development Network >> Visual C#

Visual C#

New Question

Excel 2003 vs Excel 2007
web parts deploying problem
Visual Studio 2005 crashes when excluding a dataset from a project.
best practices to secure c# applications
How to find the folder or file path dynamically?
Minimize an application during runtime
Hook and unhook and event using delegate
validat string start with 4 or 5 digit number
Inconsistent line endings
What is with all of the files for a simple program?

Top Answerers

msmuser
spanky4_3
StijnV
djmIV
Bonebreak
kok_cz
tattoo
SarasMax
Evgeny Popov
adi151478
GUI Library Technical Information
Only Title

Answer Questions

  • enric vives Stack and Heap Data Structure

    hai all, value-type uses Stack Data structure, for method calls. ref-type uses Heap Data structure, for method calls. And my question is, What is Heap DS Anyone pls explain me . Also in this regard, how it is used with ref-types .That is how heap is used to change the original value Also, how is Stack DS used with value-types thanks.. thanks!!!!! a lot useful one.. Check this out: http://www.c-sharpcorner.com/UploadFile/rmcochran/csharp_memory01122006130034PM/csharp_memory.aspx ArticleID=9adb0e3c-b3f6-40b5-98b5-413b6d348b91 Hi, Please go through the following link. Hope this helps. http://msdn.microsoft.com/library/default.asp url=/library/en-us/dv_vstechart/html/datastructures_guide.asp Thank ...Show All

  • Huybs Kris if i have a code inside my class that s all messy and badly formatted and aligned, can I format it correctly

    Is there an automatic shortcut key or command to align and format my code automatically: like the IFs and whiles are all the code is badly indented Thank you Hi, try Edit | Advanced | Format Document (keyboard shortcut: Ctrl+K, Ctrl+D). Hope it helps, Andrej thank you ...Show All

  • Philippe Cand how to write a function to read string (or byte)from right side

    help me please... public static string ReverseStringWords( string input) { StringBuilder sb = new StringBuilder (input.Length); string [] words = input.Split( ' ' ); for ( int i = 0; i < words.Length - 1; i++) { sb.Insert(0, words ); sb.Insert(0, ' ' ); } sb.Insert(0, words[words.Length - 1]); return sb.ToString(); } If you mean on just Reverse characters in the string: public static string ReverseStringCharacters(string input) { StringBuilder sb = new StringBuilder(input.Length); foreach (char c in input) sb.Insert(0, c); return sb.ToString(); } boban.s wrote: public static string ReverseStringWords( string input) { ...Show All

  • John Lieurance Best way to update a class when modifying a member

    Hi, I have a UserControl derived class containing a Label, which I would like to be updated every time a public string on the class is modified. For this, I created accessors for the public string, in this way: public class MyControl : UserControl { private Label _label; private string _string; public string MyString { get {return _string; } set {_string = value; _label.Text = value + " " + value; /* do something fancy with the new value */} } /* ... */ } What I dislike of this approach is that I have the feeling of having duplicated the string inside my class. I am not sure if this is accurate, as I am new to C# development. Anyway, is there any other way to update elements of a class when a member is mo ...Show All

  • nharendt error CS0016

    I'm trying to run the csc command on a server. One user works, but I can't get any other user to work. I've tried giving the other users admistrative rights, but still no luck. The user that does work logs in against the machine and not against the company domain. I can not find any other differences. Why can't any user run this The command is like csc.exe /target:library /out:D:\DEVTEST\cc_keys.dll /reference:D:\DEVTEST\library.dll cc\src\Class1.cs Microsoft (R) Visual C# 2005 Compiler version 8.00.50727.42 for Microsoft (R) Windows (R) 2005 Framework version 2.0.50727 Copyright (C) Microsoft Corporation 2001-2005. All rights reserved. error CS0016: Could not write to output 'd:\devtest\cc_keys.dll' -- 'The direct ...Show All

  • David_Lindley SELECT-INTO query problem

    Hi I have a SELECT-INTO query which I wish to add some additional columns to the destination table. I can create the table and add the columns after it, but I wonder how is it possible to add that columns directly with the SELECT query. Thanks in advance, farshad Hi, Are you working with SQL Server You can add an additional column like this: SELECT *, null AS AdditionalColumn INTO DestinationTable FROM SourceTable Don't forget to add an alias to your new column, otherwise it will not work. Although this works, the additional column is not always with the correct datatype. When working in SQL Server, it might be easier to create a new table by letting SQL Server generate a script of the source table for ...Show All

  • Bisjom Help on creating a generic singleton class

    I am on the process of creating a generic class for the singleton pattern. My implementation as follows: public class Singleton<T> where T : new() { public static T getInstance() { if (this_ == null) this_ = new T(); return this_; } private static T this_; } Sample use would be: Singleton<Logger>.getInstance().someMethodHere(); The problem with this implementation is that the target class that would be converted into a singleton must have a public constructor, which is in the first place I am preventing it. I have implemented a simliar approach in C++, however I've used a "friend" class that sould also be declared on the user class. Please advice. Thanks. (BTW, th ...Show All

  • Marcin Ksi&amp;#261;&amp;#380;ek Shutdown.exe problems

    Process shutdown = new Process(); shutdown.StartInfo.FileName = "C:/WINDOWS/System32/Shutdown.exe"; shutdown.StartInfo.Arguments = "-s -f -t 20 -m \\deruu"; shutdown.Start(); I can get it to log me out using argument -l only, but with that I only get a "Frozen" cmd window titled "Shutdown.exe" and nothing happens. Hy, Friend I read this blog. I have one link of same forum so, try this one. http://forums.microsoft.com/MSDN/ShowPost.aspx PostID=243746&SiteID=1 try this: Process shutdown = new Process("shutdown"); shutdown.StartInfo.WorkingDirectory = Environment.GetFolder(Environment.SpecialFolder.System); shutdown.StartInfo.Arguments = &quo ...Show All

  • RLawson Callback from C++ .dll fails with "The memory could not be written"

    Hi, I'm having serious problems getting code that used to work in Visual Studio 2003, to work in .NET 3.0. I'm using Microsoft Expression Interactive Designer, but I figure my question is not really related to that product at all. I have a dll that controls a USB device (an ArtLebedev Mini 3). I can call bits of the dll fine and correctly set up my USB device. The problem is using a method within my c# code for the callback when a button on the device is pressed. After setting up the callback, pressing a button on the USB device causes the whole application to crash with a "The memory could not be written" error. Which i'm assuming means the dll is trying to call my method in c# but for some reason can't (memory address has chang ...Show All

  • flyte how to return null from a constructor

    say, i a m trying to do something like: class something something(streamreader){ if (wrong format or end of file) caller receives null as result else build object from what has been read in file } i tried 'return null', but it says it can not do that since a constructor is 'void', so i can not place a return sentence. i'm not sure something like this.dispose would retunr a null, since the 'dispose' may be asynchronous (or something) i have the next alternative class something blah blah somehting(string) (build object from string, check if string==null or wrong format before calling) static bool checkformat(string) check to see if string is adecuate to build somet ...Show All

  • Whoisit smtp client/server for password recovery, logins etc

    Hi all, Just found this forum tonight so I hope I'm posting in the right place - I didn't see any other topics that seemed to relate to my problem. Firstly, I'm a rookie with this stuff! I have a uni project I am in the middle of doing. It has been going well and my visual C# website is looking really good. I do however have a problem. I cannot seem to set up the server to send emails. I have options in for members to recover their password, change password, etc. However, when the user fills in the boxes and clicks submit, an error screen comes up to do with the email/smtp. I have messed about with it for hours and got nowhere. When I go to ASP.NET config web page to try and set the application smtp up that way it pre-selects 'Port 25'. My ...Show All

  • Itzik Katzav how to protect C# desktop exe from decompiling or reverse engineering ?

    How to protect code of a desktop exe from reverse Engineering and get source code As decompiler are easily available any one can easly get source code.Can Strong Name or obfuscator software guarantee source code protection.Is there any other technique apart from these any other language like vc++ has more security features Visual Studio 2005 Professional includes Dotfuscator Community Edition. If you have one of the lower versions of Visual Studio, I think you can buy Dotfuscator (the cheap version) for like $50. ...Show All

  • Dr Z Get string back from a C++ function to my C# code

    Hello , I am writing a C# method to calls a C++ unmanaged function. One of the arguments of the C++ function will return a string. How do I implement this Many thanks, >> Clarify what you mean by " One of the arguments of the C++ function will return a string." char* foo1(); void foo2(char* buff); std::string foo3(); void foo4(std:string& outstr); Hello, Currently, I am still investigating how to do the job is the best. But I read a Microsoft C# Programmer's CookBook, it has a cheater "Call a Function in an Unmanaged DLL". It uses an example, its C# code calls GetPrivateProfileString which is an API in Kernel32.DLL. The last argument of GetPrivateProfileString is L ...Show All

  • Danny Thorpe MSFT public get, protected set

    How can I declare a property with a public get and a protected set accessor That really is silly. It should work something similar to changing the scope. public string Prop{ override get{//} set{} } The compiled IL it's finally two different methods so I dont see a reason why this is not possible, well obviously the compiler, but I mean I dunno why is it that the compiler do allow that. Wjhat about VB or J# or Delphi, could a prop be overriden like that Thanks guys. I knew there was a reason to get VS2005.... Since what you really get from the base class is one virtual method called get_MyProp there will n ...Show All

  • Alfonso Calderon Why did I only get part of what I intend to get?

    No error was complained! The following program is to write a whole year's month,day,weekday in a MSSQL table. But somehow, for many times I have tried, but each time I got only part of what I intend to get: the whole year with 12 monthes, instead, I only got 3 or 4 months' content in the table. Can anybody tell me why calendar.dll using System; using System.Configuration; using System.Data; using System.Data.SqlClient; using database; namespace calendar { public class calendar { private int _nian; //year private int _yue; //month private int _ri; //day private int _xingqi; //weekday private string _errorInfo; public int nian { get {return _nian;} set {_nian=value;} } public ...Show All

282930313233343536373839404142434445

©2008 Software Development Network

powered by phorum