Announcement: Be excellent to each other.


Caravel Forum : Caravel Boards : Development : I just created a new program and I need input
New Topic New Poll Post Reply
Poster Message
slimm tom
Level: Smitemaster
Avatar
Rank Points: 1228
Registered: 10-14-2006
IP: Logged

File: Computer Shop.zip (150.5 KB)
Downloaded 50 times.
License: All Rights Reserved
icon I just created a new program and I need input (0)  
I started programming in Visual Basic some time ago and I just programmed my first real program. I didn't create it because I wanna sell or distribute it, but I created it to see what problems I'll encounter while programming, and if I could solve them.

The program isn't done yet, I'd just like some input on what I have right now and how I can improve my code. Attached is the program in executable form and the source code. (THIS PROGRAM IS MY CREATION. PLEASE DON'T DISTRIBUTE THIS ANYWHERE ELSE THAN IN THIS TOPIC. Not like anyone would, but just to be sure. :) )

Form 1 is done. I just need to create form 2, which will give an overview of the order the customer is about to place. I could possible improve some code in form 1, like putting the Warranty Radio Button_CheckedChanged code into a function. I'm also planning to add some more features.

So fellow programmers, please look at my buggy code and enlighten my mind with your superior programming wisdom. :P
03-08-2008 at 10:13 PM
View Profile Send Private Message to User Show all user's posts High Scores Quote Reply
vinheim
Level: Smiter
Rank Points: 300
Registered: 05-31-2007
IP: Logged
icon Re: I just created a new program and I need input (0)  
How did you learn Visual Basic? All my tutorials sucked at teaching me (or I suck at learning :) )
03-08-2008 at 11:00 PM
View Profile Send Private Message to User Send Email to User Show all user's posts Quote Reply
coppro
Level: Smitemaster
Rank Points: 1308
Registered: 11-24-2005
IP: Logged
icon Re: I just created a new program and I need input (0)  
My programming wisdom would be as follows:

A) Don't start with VB - it's a language that MS desperately wants to not exist anymore (and I agree with them). I don't know what a good place to start truly is, but Scheme and Java are good places to look, if modern education is any hint (and there's a lot of good free Scheme books out there - that particular one was recommended to me by a teacher at my school).

B) Since you accidentally triple-posted, you can go back and delete the other threads by editing them and checking the delete box when you edit.
03-09-2008 at 12:57 AM
View Profile Show all user's posts Quote Reply
calamarain
Level: Smitemaster
Avatar
Rank Points: 933
Registered: 03-25-2007
IP: Logged
icon Re: I just created a new program and I need input (+1)  
Another good one to learn is Python. The sheer amount of *good* Python tutorials online is immense. Also, there's a load of premade libraries, so you can get in and going on cool high level stuff relatively quickly.

____________________________
My Holds
Click here to view the secret text

03-09-2008 at 01:45 AM
View Profile Send Private Message to User Send Email to User Show all user's posts This architect's holds Quote Reply
Monkey
Level: Master Delver
Avatar
Rank Points: 190
Registered: 03-21-2006
IP: Logged
icon Re: I just created a new program and I need input (+1)  
coppro wrote:
I don't know what a good place to start truly is, but Scheme and Java are good places to look
Python's also a great place to start. You can download it at http://www.python.org/.

____________________________
lurking
03-09-2008 at 02:15 AM
View Profile Send Private Message to User Show all user's posts This architect's holds Quote Reply
NiroZ
Level: Smitemaster
Rank Points: 1302
Registered: 02-12-2006
IP: Logged
icon Re: I just created a new program and I need input (0)  
Why is this topic appearing 3 times?
03-09-2008 at 04:31 AM
View Profile Send Private Message to User Send Email to User Show all user's posts This architect's holds Quote Reply
coppro
Level: Smitemaster
Rank Points: 1308
Registered: 11-24-2005
IP: Logged
icon Re: I just created a new program and I need input (0)  
Accidental triple-post... slimm tom will probably fix it once he notices it.
03-09-2008 at 05:37 AM
View Profile Show all user's posts Quote Reply
slimm tom
Level: Smitemaster
Avatar
Rank Points: 1228
Registered: 10-14-2006
IP: Logged
icon Re: I just created a new program and I need input (0)  
vinheim wrote:
How did you learn Visual Basic? All my tutorials sucked at teaching me (or I suck at learning :) )

I had that too at the beginning. I learned best from real books, not from online tutorials. VB2008: Step By Step is a good one if you're an absolute beginner. You can buy it here.

And if you don't have the money or means to buy it, Microsoft's video tutorials are excellent. You'll learn a lot from those. You can find them here.

coppro wrote:
Accidental triple-post... slimm tom will probably fix it once he notices it.

Fixed, my internet was very laggy yesterday so I accidentally posted three times. :blush

coppro wrote:
A) Don't start with VB - it's a language that MS desperately wants to not exist anymore (and I agree with them). I don't know what a good place to start truly is, but Scheme and Java are good places to look, if modern education is any hint (and there's a lot of good free Scheme books out there - that particular one was recommended to me by a teacher at my school).

Yeah, the problem is, I already tried many other languages and I suck at them. Now I finally know a programming language and I don't want to just go on and try something else. I want to expand my knowledge of VB. And if I master it, I'll move on and try to learn C#.
I don't want to try C# just yet because you need to hard-code everything in your program. Visual Basic gives you the possibility to design an user interface and write some code for it, while the hard-code stuff is done behind the scenes. Yes, I know what you're going to say: "But you don't have complete control of your program with VB." The answer is: I don't want complete control just yet. I first want to start with easy programming, and later try some harder programming languages.

And about MS not wanting VB to exist, why would they? They just released a full new VB version into Visual Studio 2008. There are lots of books for sale about VB. MS makes money with it, and that's what they're trying to do, right?

But instead of talking about possible other languages, could someone with visual studio 2008 and a little knowledge of VB please look at my code and give some input? After all that's why I posted here. To learn better coding techniques and to improve my program.
03-09-2008 at 10:03 AM
View Profile Send Private Message to User Show all user's posts High Scores Quote Reply
Briareos
Level: Smitemaster
Avatar
Rank Points: 3516
Registered: 08-07-2005
IP: Logged
icon Re: I just created a new program and I need input (0)  
slimm tom wrote:
I don't want to try C# just yet because you need to hard-code everything in your program. Visual Basic gives you the possibility to design an user interface and write some code for it, while the hard-code stuff is done behind the scenes. Yes, I know what you're going to say:
On the contrary - what I want to say is "The same windows forms editor used for VB.Net works exactly the same for C#, so where's the difference exactly?" (Except for the lack of cringeworthy VB syntax, that is... but then I still wouldn't touch it with a ten foot pole either.)

Of course, having had the "pleasure" of having to fix some program recently that used the visual designer for oodles of SQL statements made me die a little on the inside... :~(

np: Tocotronic - Freiburg (Kapitulation Live)

____________________________
"I'm not anti-anything, I'm anti-everything, it fits better." - Sole
R.I.P. Robert Feldhoff (1962-2009) :(
03-09-2008 at 10:47 AM
View Profile Send Private Message to User Send Email to User Visit Homepage Show all user's posts Quote Reply
slimm tom
Level: Smitemaster
Avatar
Rank Points: 1228
Registered: 10-14-2006
IP: Logged
icon Re: I just created a new program and I need input (0)  
Briareos wrote:
slimm tom wrote:
I don't want to try C# just yet because you need to hard-code everything in your program. Visual Basic gives you the possibility to design an user interface and write some code for it, while the hard-code stuff is done behind the scenes. Yes, I know what you're going to say:
On the contrary - what I want to say is "The same windows forms editor used for VB.Net works exactly the same for C#, so where's the difference exactly?" (Except for the lack of cringeworthy VB syntax, that is... but then I still wouldn't touch it with a ten foot pole either.)

If you mainly use the Visual Designer for C# you kinda defeat the purpose of the language. In my opinion, one of the best things of C# is that you have complete control over all things in your program. And the lack of easy syntax is just the problem, If I look at some VB code I almost directly understand what's happening. If I look at C# code, I don't. The VB syntax is much easier to understand for a beginner (which I am)
03-09-2008 at 11:04 AM
View Profile Send Private Message to User Show all user's posts High Scores Quote Reply
Briareos
Level: Smitemaster
Avatar
Rank Points: 3516
Registered: 08-07-2005
IP: Logged
icon Re: I just created a new program and I need input (0)  
slimm tom wrote:
If you mainly use the Visual Designer for C# you kinda defeat the purpose of the language.
Can't say that I disagree with you there... :)

____________________________
"I'm not anti-anything, I'm anti-everything, it fits better." - Sole
R.I.P. Robert Feldhoff (1962-2009) :(
03-09-2008 at 11:12 AM
View Profile Send Private Message to User Send Email to User Visit Homepage Show all user's posts Quote Reply
slimm tom
Level: Smitemaster
Avatar
Rank Points: 1228
Registered: 10-14-2006
IP: Logged
icon Re: I just created a new program and I need input (0)  
And why should I use C# when I could use VB and accomplish the same in less time? I'm not planning to write complex programs or games. If I would, I would probably use C# because it's more powerful. I want to program little programs just for fun and I won't get anything more (except frustration) from using C# for that purpose.

[Last edited by slimm tom at 03-09-2008 12:40 PM]
03-09-2008 at 11:18 AM
View Profile Send Private Message to User Show all user's posts High Scores Quote Reply
coppro
Level: Smitemaster
Rank Points: 1308
Registered: 11-24-2005
IP: Logged
icon Re: I just created a new program and I need input (0)  
Personally, I hate C# for a very different reason (it's one of the best languages out there): portability. C# only really has one implementation worth its beans, and that's Microsoft's. Which only works on Windows (sure there's Mono, but Microsoft conveniently made the language standard without the accompanying libraries, so it's not that useful). As such, I don't touch C# ever, and it's similar enough to Java that stuff from one is generally applicable to the other (not the libraries, the core features). I'm actually of the opinion that C# was just made to make up for J++ having an injunction installed against its development.
03-09-2008 at 02:41 PM
View Profile Show all user's posts Quote Reply
Pekka
Level: Smiter
Rank Points: 302
Registered: 09-19-2007
IP: Logged
icon Re: I just created a new program and I need input (+4)  
Here's my response to slimm tomm. I'm trying to be brief and civil. The brief part didn't quite work out, though.

It's often quite hard to get people to really look at other people's source code. And if you do ask people to review your code, you should make an effort to make it as polished as possible. If you say that it's only half done, why should someone else make an effort to go through it? You don't hand in your essays half done either and promise to write the rest after the teacher has graded the first part.

Of course, software is often created incrementally and you have demos and preview versions and what not. But still, asking for comments and saying it's not yet done don't really go well together. Show that you care about the program you are making, and others will too.

I think, it's OK to make programs just for practice. You should make lots of them, in fact. But do realize not every one will be a keeper.

For what it's worth, I would have read through the code if it had been in a language I know relatively well, but I have really no VB experience at all. I'll offer a bit of my own programming wisdom instead, such as it is.

I learned to program in C, and I got much better at it when I found something that I cared about. In my case it turned to be algorithms, and specifically how one algorithm can be so much faster than another. I spent a lot of time studying the standard algorithms from books and writing code with them. It turned out to provide a useful basis for learning more about programming later, but when I was starting out, I just wanted to know more about these things. Every clever algorithm I came across was like a little puzzle and I wanted to figure them out.

Mostly, I didn't ask people about how good my code was or whether I programmed correctly. I started worrying about that only much later. And I'm glad I looked at other languages besides C eventually, but the way I started worked quite well for me.

You should find something in programming that you care about. There's much less need for people to know C these days, so I'm not saying you should switch to it. Just think about what would be interesting to do now and work from that. Don't be in a rush.

You'll have plenty of opportunity to get people to look at your code eventually. Also, look at other people's code.
03-15-2008 at 05:43 PM
View Profile Show all user's posts This architect's holds Quote Reply
kyevan
Level: Disabled
Rank Points: 54
Registered: 08-29-2007
IP: Logged
icon Re: I just created a new program and I need input (0)  
coppro wrote:

C# only really has one implementation worth its beans, and that's Microsoft's. Which only works on Windows (sure there's Mono, but Microsoft conveniently made the language standard without the accompanying libraries, so it's not that useful).

Actually, most of the libraries are standard. Most non-GUI code works on both - the issues come in once you start using winforms. Or p/invoke, obviously, but that's calling to OS-specific libraries, and that breaks compatibility in ANY language. (And a winform implementation, sadly, is nearly useless. It's such a weak library, you pretty much have to use Win32 API calls to do a lot of stuff...)
08-11-2008 at 07:44 PM
View Profile Send Private Message to User Show all user's posts Quote Reply
Syntax
Level: Smitemaster
Rank Points: 1218
Registered: 05-12-2005
IP: Logged
icon Re: I just created a new program and I need input (0)  
Pekka wrote:
...

Wow... I've rarely heard better words than those. Passion is the thing, and that's what got me started. You put that across better than I ever could.
08-13-2008 at 04:45 AM
View Profile Send Private Message to User Show all user's posts Quote Reply
New Topic New Poll Post Reply
Caravel Forum : Caravel Boards : Development : I just created a new program and I need input
Surf To:


Forum Rules:
Can I post a new topic? No
Can I reply? No
Can I read? Yes
HTML Enabled? No
UBBC Enabled? Yes
Words Filter Enable? No

Contact Us | CaravelGames.com

Powered by: tForum tForumHacks Edition b0.98.8
Originally created by Toan Huynh (Copyright © 2000)
Enhanced by the tForumHacks team and the Caravel team.