C# Demonstrations (.Net)

Most demonstrations are taken from Getting Started with RemObjects C# for .Net and adapted so that they also run in the open source SharpDevelop IDE. Following this recommendation we went to the download page. We went to the section entitled "Downloads for SharpDevelop 5 (C# support only!)" and clicked on Setup Download [11900 KB]. The downloaded file performed a quick installation (for which we accepted all the defaults) and its error messages enabled us to adapt easily the RemObjects C# code so that it would compile in SharpDevelop 5. Matt Ward's Feature Tour is very helpful and easy to follow.

RemObjects C# has some extensions to the language. We list examples of changes required to enable our RemObjects C# programs to compile by SharpDevelop.

  • We needed the code using System in SharpDevelop.
  • We must use int or Int32 instead of Integer in SharpDevelop.
  • In a static class the methods must be declared as static in SharpDevelop.
  • In console_output_cs we needed to append f (for float) to Single MySingle = 1.2345.
  • In loops_cs array initialisation with objects is less concise than the RemObjects C# original.
  • In enums_and_sets we found a way of emulating pred and succ.
  • In filestream_cs we changed the declaration FileStream fs; to FileStream fs = null;.

Follow the numbered links to the C# demonstrations that (except for Drawing on a Form) compile in RemObjects C# also.

Programming - a skill for life!

How to apply your knowledge of Pascal when learning C#