Subscribe to Hack Blog[aloneprogrammer's Blog]        RSS Feed

here are some mistakes which vb beginners should be avoid.....

Icon 3 Comments
Mistake 1.)Coding a OS in vb
Many vb beginners do this mistake thinking that they can code an OS in vb and there are also many tut on youtube on this but think yourself how you can code an OS in which is depended on .net framework and .NET is on window depended but you can code a micro/embedded os using .NET Micro Framework but it is only available on Netudino.

Mistake 2.)C&Y
Copy and Paste this mistake many beginners do without realizing it.The thing is when someone learn vb and when something he can't do or understand he looks for example slowly-slowly it becomes it habit of C&Y

Mistake 3.)Immutable Strings
In .NET strings are immutable....which means once a string is created, its val canít be changed.

Mistake 4.)Ops cannot be performed on 0
It's common misconception that ops cannot be performed on 0....

You can also suggest the mistake you have seen in wild or some mistakes by you or your colleagues.

This list will be updated.

.....To Be continued

3 Comments On This Entry

Page 1 of 1

modi123_1 Icon

14 September 2012 - 09:48 AM
Good spot!

aloneprogrammer Icon

14 September 2012 - 09:54 PM

AdamSpeight2008 Icon

18 September 2012 - 03:49 PM
Mistake 5.) Controls are the only way doing things.
Using controls are variables. Learning start with console applications.

Mistake 6.) Doing things like it's vb6.
Using Asc Mid to me scream you don't know about the .net string functions. some of the definitions changed slightly (to vb6) but that change is big slip up for newbies, Strings are now an immutable reference type rather than a value type (so they can be Null/Nothing).
Defining all variables at the start of methods.
Dim a As Integer
Dim b As Integer
Dim c As Integer
a = 1
b = 2
c = 4

Only advantage of the above style is that IDE warns you about unused variables.
If Option Infer On then you can just write.
Dim a = 1 ' Inferred to be an Integer '
Dim b = 2
Dim c = 4

Mistake 7.) Using String for everything
Mistake 8.) Parallel Arrays.
When they should defining custom structures/classes objects and then creating a collection of those. Make things easier to code, maintain and modify.
Page 1 of 1

Trackbacks for this entry [ Trackback URL ]

There are no Trackbacks for this entry

May 2018

20 212223242526


    Search My Blog

    0 user(s) viewing

    0 Guests
    0 member(s)
    0 anonymous member(s)