Wrox Programmer Forums
Go Back   Wrox Programmer Forums > ASP.NET and ASP > ASP.NET 2.0 > ASP.NET 2.0 Professional
|
ASP.NET 2.0 Professional If you are an experienced ASP.NET programmer, this is the forum for your 2.0 questions. Please also see the Visual Web Developer 2005 forum.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 2.0 Professional section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old October 16th, 2007, 02:40 PM
Registered User
 
Join Date: Oct 2007
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default O my goodness.......... I cant believe this

I am just disgusted right now with having to do clean-up and .net conversion projects.

In a nutshell here is the disaster. I am converting over a project from .net 1.1 to .net 2.0. Going into the project, I did not know it was a vb.net project. Honestly I have never chosen and will never chose vb.net as the project code behind language. I built the project to put up on the server just to have it working and the website is just filled with errors. I commented out the code in one function and immediately there is another problem in some other function. The error I continue to get when I comment out the code in functions is this .....
Exception Details: System.NullReferenceException: Object reference not set to an instance of an object.

Dude why in todays day and age are people still creating variables/objects without freaking initializing them or typing them. Now I am stuck with 4 dozen .aspx.vb files to freaking clean up and another 2 dozen damn App_Code files to clean.

It makes it harder for the client to maintain their website when their website is filled with "I dont know what this object" is for variables that "when I am ready to use it" it [u]SHOULD</u> work because vb allows me to walking across the highway blind folded.

I wish I was a magician, this is just ridiculous. And what I was not surprised at, is the fact that it is taking these freaking outsourced jokers 1 year to complete a project that I know from experience(Because I have worked on 2) could have been done in 3 months. No wonder they cannot even get done with the project because their coding style is just atrocious.

Rant over :(:(:(:(

 
Old October 16th, 2007, 02:46 PM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

Don't blame the language for incompetent developers. I can give you a similar mess in C# if you like.....

BTW, System.NullReferenceExceptions have nothing to do with variable declaration. They do exist in C# as well.......

Imar
---------------------------------------
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Everyone is unique, except for me.
Author of ASP.NET 2.0 Instant Results and Beginning Dreamweaver MX / MX 2004
While typing this post, I was listening to: For Reasons Unknown by The Killers (Track 5 from the album: Sam's Town) What's This?
 
Old October 16th, 2007, 02:58 PM
Wrox Author
 
Join Date: Oct 2005
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default

Quote:
quote:Originally posted by truenbalive


Honestly I have never chosen and will never chose vb.net as the project code behind language.
Why not? Write me a snippet of code in C# that can't be wrote in VB.NET. (I am talking on a functional level since, obviously, nothing you write in C# will compile in a VB project and vice versa)

Quote:
quote:Originally posted by truenbalive


Exception Details: System.NullReferenceException: Object reference not set to an instance of an object.

Dude why in todays day and age are people still creating variables/objects without freaking initializing them or typing them. Now I am stuck with 4 dozen .aspx.vb files to freaking clean up and another 2 dozen damn App_Code files to clean.
This is a poor programming practice and not the fault of the language itself. The type of error can pop up in a C# application just as easily when coded by the same person.

I am not going to turn this into a language Flame War, there are plenty of other people that fight that battle and, at the end of the day, its a silly argument. I know both VB and C# and it is a shame that VB.NET coders are getting the same bad wrap as they did back when it was the C++ camp vs VB camp.

Also, being the pompus "I am a god in the programming world" attitude is not going to win you any friends. (You imply this when you say: And what I was not surprised at, is the fact that it is taking these freaking outsourced jokers 1 year to complete a project that I know from experience(Because I have worked on 2) could have been done in 3 months.) It is very easy to be on the outside looking in and say "Wow it took them a year to do THIS?! I could have done it in 3 months!"

But could you have? Was there a break down in communication between the PM and the programmers that caused countless revisions? Were the clients problematic with change requests? So on and so forth. Just because an app doesn't hit its deadlines doesn't mean its the programmers fault and you need to account for all the possible variables.

So yep, there is my 2 cents.

================================================== =========
Read this if you want to know how to get a correct reply for your question:
http://www.catb.org/~esr/faqs/smart-questions.html
================================================== =========
Technical Editor for:
Beginning Visual C# 2008
Professional Search Engine Optimization with ASP.NET
Professional IIS 7 and ASP.NET Integrated Programming
Wrox Blox: Introduction to Google Gears
Wrox Blox: Create Amazing Custom User Interfaces with WPF and .NET 3.0
================================================== =========
 
Old October 16th, 2007, 03:02 PM
Registered User
 
Join Date: Oct 2007
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

You are right. It is about incompetent developers. I actually do not prefer vb because I am coming from the following background C -> C++ -> C# -> Java -> Haskell -> Scheme so understand I am picky about variables that are written in this manner

Dim v
' some more code that if value then set v
If v = [some object] Then

I get a error on that because v is nothing unless v was set if a condition earlier in the code was true.

It is not the language....but my real issue is with people who like to code blindly, it is harder to debug.

So again, I am not knocking the language. Actually I did not knock the language it is just in this day and age people continue do write dirty code that is hard to clean up.

 
Old October 16th, 2007, 03:12 PM
Registered User
 
Join Date: Oct 2007
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Parsons I am not knocking the language. I could sit down and write "good" VB code but that would be relative to the reviewer of the code.

You stated

Also, being the pompus "I am a god in the programming world" attitude is not going to win you any friends. (You imply this when you say: And what I was not surprised at, is the fact that it is taking these freaking outsourced jokers 1 year to complete a project that I know from experience(Because I have worked on 2) could have been done in 3 months.)


I am not implying this in no way especially since I was sure to mention it was this specific project that would have most likely gotten pass one year because of the mess already in the project.

I am sure you know it takes great planning and experience to write efficient applications. I could go ahead and write 100 lines of copy and paste code versus 1 function to repeat the same behavior and that is my issue here. The other day some guy told me there was not way in .net to have a drop down menu, when this functionality already exist in the 2.0 framework. This person was supposingly working with the 2.0 framework but apparently had no knowledge of the tool they are working with.

So again, I am not knocking the language, it is the people who give the language a bad reputation that I have a problem with.

I have dealt with those clients as you mentioned who want to change their requirements every day. But hey, for every change they want they have to pay for it right.

 
Old October 16th, 2007, 03:42 PM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

Quote:
quote:So again, I am not knocking the language. Actually I did not knock the language it is just in this day and age people continue do write dirty code that is hard to clean up.
That I agree to. That's why I always try to help others understand good coding techniques and best practices. Helps to avoid projects like yours.... ;)

So, I take it we'll see you here more often, providing tips and help to programming newbies so they can write better web sites than the one you're dealing with now?? Cool!

Imar
---------------------------------------
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Everyone is unique, except for me.
Author of ASP.NET 2.0 Instant Results and Beginning Dreamweaver MX / MX 2004
While typing this post, I was listening to: Play For Today by The Cure (Track 6 from the album: Staring At The Sea - The Singles) What's This?
 
Old October 24th, 2007, 02:06 PM
Authorized User
 
Join Date: Apr 2005
Posts: 94
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Everyone has their preference in language. I love C# over VB.Net also as I love C++ over VB. It is just ap reference. My preference is I find it hard to scan over VB code and see what is going on vs the "," and ";" and so forth in the C languages that let you know where end of line is and what not. I also find VB too wordy and I do agree on the untyped variables like
Dim variable

I have the same issue in JScript with "var" which can be anything while in C you have to declare the data type you are using or convert of you were being fancy but I will not say VB developers are any less that C# developers. I actually give a VB coder props if he makes code I can read because I have seen some VB code that is garbage but not because of the language. I do have advice for VB developers that C# programmers take for vantage.

Type your variables when you declare them and stick with that type throughout the program for that variable. A C# programmer can make the same mistake but I see it being easier for a VB developer since they do not have to type the variable when they declare it.

I only have one question. Hey Imars, is that some program you are running that is tracking what MP3s your listening to when posting or are you adding that by hand?

 
Old October 24th, 2007, 02:18 PM
Wrox Author
 
Join Date: Oct 2005
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default

Its a WebService and he explains how he wrote it here:

http://imar.spaanjaars.com/QuickDocID.aspx?QUICKDOC=277

I am curious about this statement you made though: A C# programmer can make the same mistake but I see it being easier for a VB developer since they do not have to type the variable when they declare it.

How so? The closest I can come to realizing this is if I create a variable of Type object:

object o;
which is what a VB Programmer is really doing when they do:
Dim o

(I do agree with you completely that it should be accompanined by a Type, even if it is object, regardless)


================================================== =========
Read this if you want to know how to get a correct reply for your question:
http://www.catb.org/~esr/faqs/smart-questions.html
================================================== =========
.: Wrox Technical Editor :.
Wrox Books 24 x 7
================================================== =========
 
Old October 24th, 2007, 02:32 PM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 2,189
Thanks: 5
Thanked 59 Times in 57 Posts
Send a message via MSN to gbianchi
Default

You will have to stop flaming VB or I will have to set you on fire (Just Kidding :))

I love VB B/C is "Wordy" as you said. I been programming since more than 10 years now, and I try to move to C# (back in 2004), but despite there is nothing new on it (just learning a new syntaxis), there is no point in blame VB because you are reading bad code make by a bad programmer (or maybe just a good one that was in a real hurry).

I can read any of the 2 language, I prefer writing in VB, and I has option explicit and strict turned on, so I have to program like if I was in C# (but is not case sensitive, thanks god!).

That was a point I never understand. Why sometimes C# or C++ programmers call variables like do similar things like:
pointertonowhere
Pointertonowhere
pointertonoWhere

and don't use 3 diferents names for it.. in that case VB programmers can flame C(anything) programmers, look for a real name for that variables please!

HTH

Gonzalo

================================================== =========
Read this if you want to know how to get a correct reply for your question:
http://www.catb.org/~esr/faqs/smart-questions.html
^^Took that from dparsons signature and he Took that from planoie's profile
================================================== =========
My programs achieved a new certification (can you say the same?):
WORKS ON MY MACHINE
http://www.codinghorror.com/blog/archives/000818.html
================================================== =========
I know that CVS was evil, and now i got the proof:
http://worsethanfailure.com/Articles...-Hate-You.aspx
================================================== =========
 
Old October 24th, 2007, 02:40 PM
Wrox Author
 
Join Date: Oct 2005
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default

Quote:
quote:Originally posted by gbianchi
 You will have to stop flaming VB or I will have to set you on fire (Just Kidding :))
That is funny.

I don't think Quick was flamming VB or anything just stating his opinion on why he doesn't like it.

However, the best .NET flame I have seen to date was a C++ programmer friend of mine had a shirt made that said: My compiler compiled your compiler.


Anyway, moving on. ^^

================================================== =========
Read this if you want to know how to get a correct reply for your question:
http://www.catb.org/~esr/faqs/smart-questions.html
================================================== =========
.: Wrox Technical Editor :.
Wrox Books 24 x 7
================================================== =========









Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.