What does the M stand for in C# Decimal literal notation?

It means it’s a decimal literal, as others have said. However, the origins are probably not those suggested elsewhere in this answer. From the C# Annotated Standard (the ECMA version, not the MS version): The decimal suffix is M/m since D/d was already taken by double. Although it has been suggested that M stands for … Read more

How to make an installer for my C# application?

Add a new install project to your solution. Add targets from all projects you want to be installed. Configure pre-requirements and choose “Check for .NET 3.5 and SQL Express” option. Choose the location from where missing components must be installed. Configure your installer settings – company name, version, copyright, etc. Build and go!

At least one object must implement IComparable

Well, you’re trying to use SortedSet<>… which means you care about the ordering. But by the sounds of it your Player type doesn’t implement IComparable<Player>. So what sort order would you expect to see? Basically, you need to tell your Player code how to compare one player with another. Alternatively, you could implement IComparer<Player> somewhere … Read more

Categories c# Tags

What is the difference between String and string in C#?

string is an alias in C# for System.String.So technically, there is no difference. It’s like int vs. System.Int32. As far as guidelines, it’s generally recommended to use string any time you’re referring to an object. e.g. Likewise, I think it’s generally recommended to use String if you need to refer specifically to the class. e.g. This is the style that Microsoft tends to use … Read more

Playing a MP3 file in a WinForm application

The link below, gives a very good tutorial, about playing mp3 files from a windows form with c#: http://www.daniweb.com/software-development/csharp/threads/292695/playing-mp3-in-c This link will lead you to a topic, which contains a lot information about how to play an mp3 song, using Windows forms. It also contains a lot of other projects, trying to achieve the same … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)