Take the 2-minute tour ×

I do not know if there is special programming in C# for the web or it is the same?. If it is the same then what are the topics that I should focus on in C# in order to use it building web application by ASP.NET (Web forms or MVC). For example, if I want to build a website for one of the health centers, will I need a lot of knowledge in C#?


  • What are the topics that I should focus on in C# so I have enough confidence to build small - medium websites?
share|improve this question
add comment

4 Answers

up vote 6 down vote accepted

C# is the language, and is the same for web development as for anything else. You'll need a strong foundation in the language for serious web work, including:

  • Expresions, types, variables, Operators, castiing
  • Control Statements - loops, switch, if
  • Namespaces
  • Methods
  • Exception handling
  • Properties
  • Enums
  • Overloading
  • Collections & arrays
  • Using attributes
  • Classes, objects, interfaces, inheritence, constructors, encapsulation, polymorphism
  • A good understanding of events

You may not need in depth understanding of:

  • Reflection
  • Generics
  • Delegates
  • Threading
  • Linq
  • Lambda expressions

However, C# itself will be the least of your worries. You'll also need:

  • Foundational HTML and CSS
  • Basic OO principles
  • Know-how about your data store: many people use SQL Server or some other RDBMS (so need SQL, ADO.Net as well as knowing how to set up the server).
  • To know your way around the IDE
  • To be able to set up solutions, projects, references, imports
  • To be able to build, run and deploy your code
  • Some javascript(?)

Then there is the asp.net stuff itself (I don't use MVC so can't comment on that area):

  • The event model
  • Session / state management (viewstate, session state)
  • Basic controls
  • Configuring IIS
  • Directives (<%...%>)
  • Configuration
  • How to structure the project
share|improve this answer
Do you need ADO.Net or can you alternatively use Linq-to-SQL or Entities Framework for Database ORM? Also, is the 'event model' much different than the standard DOM event model (OnLoad, OnMouseDown, etc...)? –  Evan Plaice Mar 26 '11 at 9:52
@Evan: There are a lot of alternatives on the data storage front, so you're right - you're not tied to ADO.Net. As for the event model, I was thinking of the server-side events that are raised by ASP.Net. These server side events are quite different from the events you mention, which occur in the user's browser. Knowing these events (when and why they fire & what to do about them) is one of the most important things that an ASP.Net programmer can learn. On the flip side, you can get in a real mess if you don't know enough about them: that was my experience anyway. –  Kramii Mar 26 '11 at 22:07
@Kramil Cool, thanks for clearing that up. Now, I only wish I had an ASP.Net project to work on so I could fill in the gaps in my understanding :) –  Evan Plaice Mar 27 '11 at 8:30
need to remember this answer the next time someone says "but it's just a website; easy right!" On a side note don't forget performance (consequences) of various software architecture / design decisions. –  Ken Henderson Aug 30 '11 at 1:11
@Evan: generally speaking Linq-To-Sql, EF, and other ORMs are a layer on top of ADO.NET. Also MS originally developed the classic ASP.NET model (eventing specifically) so that it would be similar to the windows app model [trying to get app developers to move to the web]. This is separate from the events that happen at the client (browser) and require a post back to the server. If you want to take a deeper look a typical 'get my feet wet' application suggestion is to build your own blog. –  Ken Henderson Aug 30 '11 at 1:16
add comment

You will probably need more knowledge about SQL and other database related technology than anything specific about C# other than the fact that it is an object oriented language. The best way to do these things is to just build a small project and see what code idioms come up because each framework has it's own way of doing things.

If you know how to program then learning C# won't be hard. The hard part will be learning how to structure your application with whatever framework C# provides for web applications and this is just a matter of working with the framework to get acquainted with its API.

share|improve this answer
Can you explain why is it more important to know deeply SQL rather than C#, while most code will be written in C# and not every web application will need a database (or an SQL server)? –  MainMa Mar 26 '11 at 8:20
@MainMa: I didn't say deeply but enough to know how to work with the data in the database and some things about normalized and non-normalized table structures. I'm not sure what kind of web application doesn't need a database. Any non-trivial web application needs to persist information and the best way to do that is to store the data in a database. –  davidk01 Mar 26 '11 at 8:24
add comment

You can certainly use Linq to SQL or Entity Framework for your database work, but you will need to know about generic collections and LINQ to make effective use of them. I recently wrote a library project for a local school with a couple thousand books and a checkout/returns system using Entity Framework, code first, without having to write a line of SQL or doing any database design, but this is specific to the code first approach and it may be easier to go from a database-first approach to build your ORM from an existing database. Either way it's still necessary to know SQL for testing and so on.

The event model in WebForms works basically like WinForms assuming you drag, drop and doubleclick your controls, although you'll have to pay attention to postbacks (via IsPostBack property), viewstate, session, etc. In my opinion MVC will take considerably more skill in C# and understanding of more advanced concepts, in addition to the HTML, JavaScript and CSS you will have to work much more closely with.

share|improve this answer
add comment

You can use either C# or VB.NET for ASP.NET Development. I would recommend you get a good book by searching on amazon.com. A high rated book will cover most of the topics needed to develop a small to medium website.

Its not that difficult if you have some knowledge of programming. Infact I believe web development is a lot easier ( my case more interesting too ) than desktop development.

Also I would like to add that ASP.NET uses the .NET Framework which comes in versions. I think the latest is .NET Framework 4. Just keep that in mind that when selecting a book and getting the tools.

share|improve this answer
add comment

Your Answer


