473,395 Members | 1,905 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

ASP.NET - Final Year Student Project Dilema ?

Okay I was petrified of posting this under the 'ASP.NET' thingy place, because the question itself is not based on actual code and problems encountered.

The question I wanted to ask was this:

In industry today, is there really a big fuss made out of whether one adopts the 'in-line' coding practice over 'code-behind' ?

i'm writing a piece of software, which will ultimately be webdriven - so I chose asp.net as my technology platform.

As i'm not and 'expert' programmer, I am limiting myself to 'in-line' coding , whereby the connection strings, form actions occur all one one page.

i have difficulty grasping what people mean by 'separating logic from presentation' and gave up on the whole 'layers' thing, as it was unnecessarily confusing the average guy like me. Sometimes I just wish they told you stuff in a no nonsense manner, that way the 'common man' would 'get it'.

So, should I adopt a 'code-behind' approach to writing all my .aspx pages , and if so - will lecturers/members of the academic staff pick up on that and award me extra marks ?

or since im not building a system for a big company, and its just a standalone solution (prototype) for a client of mine who needs a tool to aid him on decision making, could I not simply keep it simple and use 'in-line' code ?

asp.net wizards, those in industry, fresh graduates in the comp science discipline etc - please get back to me on this one
Dec 21 '09 #1
1 2479
Frinavale
9,735 Expert Mod 8TB
I don't think there is an industry standard for these types of decisions. It's all going to depend on the standards that the company has set to use. Since you are the company in this case, you can chose to what you wish.

Separating the VB/C# code out of the ASP.NET pages and into layers gives your application flexibility. There is a definite advantage to keeping a clear distinction between the UI and the logical code that drives the application. It took me a while to see the advantage of this too.

If you keep your code separate in layers (for example the user interface layer, the business logic layer, and the data access layer) it makes your application a lot easier for testing. If you implement each layer separately in such a way that it doesn't depend on another layer you can test things much more easily.

For example, you have a Data Layer. The point of this layer is to manipulate data in your data store. You can implement this component and test it to make sure it works before using it in another component. For example you can use unit tests to make sure that you can add things, edit things, and delete things in your data store.

Now you have a business layer. This layer contains the business logic for your application. It's layer that makes logical decisions based on user input and data from the data store etc. If this layer is kept separate from the Data Layer and the User Interface than you can also test it more easily...you aren't tied to using a web interface to test this component. You can test it using any tools you want to use.

Now you have the user interface layer. This layer can be very complicated. Sometimes you need to use JavaScript and Ajax in your user interface along with CSS...any of these things can cause bugs that may make your application unusable.

If you are trying to debug a problem it can be very hard to track down the cause especially as applications grow in size and complexity. Keeping your layers separate can let you test each component separately to find where the problem is happening. You can't do this when everything is merged together into the ASPX code.

Not only does it make things easier to test but it also wraps your code into clean, clearly defined tiers so maintaining this code in the future will be easier. If you changed the name of a table you don't need to go looking through each page in your ASPX page to make the change in your code...you just make the change in the Data Access layer. If you make a business logic change, you don't need to be looking through code that also connects to the data store...you just go to the business layer and make the change there....

Say you change out the database for an XML file!
Now you just have to change 1 component: the data access layer...the rest of the project doesn't get touched by the update which means there's less chance of breaking something else in the process.

Or say you want to provide an additional view for your website that is targeted towards mobile devices. If you keep your UI separate from your Business Logic and your Data Access logic then all you have to do write new web pages that link into the existing Business layer...instead of having to re-write your business logic for the mobile version.

Also, by separating your application into layers, it gives you the option have multiple people working on the same project at the same time. You can have a web designer working on the user interface, a database expert working on the data access layer, and another software developer implementing the business layer. Each person can use their own unit tests to ensure their part is working before adding it together into the completed project.

There's a lot of benefits to keeping your individual layer separate!

-Frinny

PS I moved your question to the software development forum since this is more of a software development question than anything else.
Dec 21 '09 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

11
by: Sridhar | last post by:
Hi, I am doing my undergrade CS course. I am in the final year, and would like to do my project involving Python. Our instructors require the project to have novel ideas. Can the c.l.p people...
16
by: Kirk Bevins | last post by:
Hello, new to posting, got a dilema in c++. I cant seem to create new instances of my student class. The idea is to make a database where the user inputs surnames and library card numbers etc. The...
2
by: SemSem | last post by:
iam in the final year in computer scince department. i have to choose a project to work in all this year and at the final i have to give them the project and documentaion and live demo of what i...
2
by: astarter | last post by:
Hello friends. I am second year student of Computer engg. in DCE. I want to make some project to hone my programming skills. Please suggest some. I know C,C++, Java( core only) and DS. Any help...
13
by: ravi | last post by:
I am a final year computer engineering student i am looking for some good as well as tough project ideas in C/C++ Can anybody help me by giving their ideas Thanks in advance.
1
by: ieyra204 | last post by:
hi guys, i need help for my final year project. i use to make a databases for student to check their result using SMS. i use microsoft access for the database but i did'nt know how to implement...
2
by: micangello | last post by:
i need ideas on what my final year project can be about i have studied 2 years of pure math (advanced calculus and algebra, topology, statistics..... ) i then switched ot computer science now...
11
by: ITrishGuru | last post by:
Hi all, I'm doing my FYP using csharp and MS Outlook to develope a plugin app. My question isn't about programming as such, Its more about project managment. Does anybody have a good URL that...
2
by: micangello | last post by:
I im in my last year computer science,we have a final year project for Automating File systems..we're using C++ since we need to create classes for the inode and blocks and superblock ... etc... but...
6
by: truezplaya | last post by:
Hi all I am currently in the situation of deciding what to do for my final year project. I was wondering if any had already done such a project and if they could shed any light on the level of...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.