This article is a C# supplement to the tutorial that Michael Washington did called Creating a Super-Fast and Super-Easy DotNetNuke Module For absolute beginners for DotNetNuke Version 4.3 or higher.
To make full use of this article you should first download the C# version of this module from the Downloads section of this web site. Now you should generally follow the instructions from the adefwebserver (above) to create the module. You can create both the VB and C# examples side-by-side for comparison of just one or the other.
There are a few nuances that you should be aware of when it comes to the C# part of the project.
The 4 files that are specific to the C# part of the project all start with CS and are not needed if you are only creating the VB part of the project. If that's the case then you should not be reading this article but the tutorial listed above.
Two of the C# files should be placed in a folder under the App_Code folder of the web site in question. If for example your web site is at C:\DotNetNuke_2\Website then you should put the CSThingsForSaleController.cs and CSThingsForSaleInfo.cs in the C:\DotNetNuke_2\Website\App_Code\CS\ folder. I have selected a folder called CS but you can call it anything you want.
In my projects, I put all of my C# code in folders under the ..\CS\ folder so that I can just specify one folder in the web.config file to be compiled separately.
Now this part is important and relates to the last sentence above. If you're compiling (using) C# code in a VB project you need to tell the compiler to compile the C# code apart from the VB code and build separate DLLs for the C# code. You do this by specifying the folder in the web.config file like so:
This lets the compiler know that the CS directory below the App_Code directory and all sub-directories below it should be compiled into a separate DLL.
Under the DesktopModules folder you can create a CSThingsForSale module and just do exactly the same with this folder as you would do for the VB folders mentioned in Michael's tutorial above and you will be able to create and use the C# version of this tutorial.
You can create and use the VB and C# module side by side - they will both work together.
If you have any questions then feel free to ask in the Forum and I will do my best to answer them.