Making editors for cricket games

abhishek_rox said:
Oh i though it was between start number and end number like if numbers were 1 and 6 then 2+3+4+5

Thanx for your help, what about second exercise

The second excercise is just an update on the first one.If the user hasnt entered a number in the start postion(or the end position for that matter),the program will just terminate with an EndSub,otherwise the first procedure happens again.

For excercise 3 we are passing all the values in the textboxes to integer variables.

x=startNumber.val();
y=startNumber.val();

Then we do the same operations with them using x and y.

For i=x to y
...
 
But whats the code

If .................. ?? Then
The code
Else EndSub

What do i write after If?
 
abhishek_rox said:
But whats the code

If .................. ?? Then
The code
Else EndSub

What do i write after If?

This should probably be it,Im still not sure as Ive not done vb for a while now.Declare the variables using Dim.If its still not working,try reading some of the tutorials in this thread as they should give you an idea on the codes.

Code:
if(startNumber)  then
For i = startNumber To endNumber

answer = answer + i

Next i
else 
ExitSub
End If
 
Ok thanx, so

If (startnumber), means that a value has to be assigned to startnumber in the textbox right?
 
abhishek_rox said:
Ok thanx, so

If (startnumber), means that a value has to be assigned to startnumber in the textbox right?

Thats what I mean.Im not sure again if vb.net accepts that kind of code though.Ive just been into more c++ & java lately.
 
any tutorial using ms word visual basic editor :help :upray
or show complete msg.
i mean after As system in the code.in 1 tut.
 
Last edited:
I Have Worked On The Second Tutorial And Tried My Best To Build On It.
Just Tell Me If It Is Nice.And I Cannot Seem To Get The "<" Or ">" Correctly i.e. If I Type Case <"150" It Means That The Programe Has To Show The String If The User Types 150 Or Above Right ?
 

Attachments

  • FORM1.zip
    8.1 KB · Views: 6
Vaisakh said:
I Have Worked On The Second Tutorial And Tried My Best To Build On It.
Just Tell Me If It Is Nice.And I Cannot Seem To Get The "<" Or ">" Correctly i.e. If I Type Case <"150" It Means That The Programe Has To Show The String If The User Types 150 Or Above Right ?

Nice try, I'll try it when I get home on my computer. About your question, I can't remember anything aobut the second tutorial but if you use < or > with strings it sorts them in alphabetical order, so "aa" > "bb" is false but "cc" < "dd" = true, I think. If I'm completely wrong, let me know.
But yeah > is bigger than and < is smaller than.
 
Help Please!

Alright I am Using SharpDevelop 2.0 and I want To Know a Couple Of Things.Please Someone Explain Things Like Embi Does.In His Third Tutorial Embi Explained Everything Quite Clearly.First Of All In Barmyarmy's Tutorial Of Multiple Abilities Changer: 1.What Is Imports System.IO And Where Do We Type It.
2.Do We Have To Type In Public Class FORM1 Or It Comes itself i.e. (Sub button1click Comes On Clicking button1 But We Can Type It Too).My Computer Does Not Show Public Sub, Private Sub etc. It Only Shows Sub
3.When I Try To Declare The Global Variables I Do Not Have The Option Of FileStream,BinaryReader Or BinaryWriter.I Also Have Problems With The Next Two Parts Of The Tutorial But I Will Post Them Later But First I Have To Get The Answers Of The Above Questions.STEP BY STEP AND PACE BY PACE A LITTLE PATIENCE WINS YOU THE RACE.
 
Last edited:
Vaisakh said:
Alright I am Using SharpDevelop 2.0 and I want To Know a Couple Of Things.Please Someone Explain Things Like Embi Does.In His Third Tutorial Embi Explained Everything Quite Clearly.First Of All In Barmyarmy's Tutorial Of Multiple Abilities Changer: 1.What Is Imports System.IO And Where Do We Type It.
2.Do We Have To Type In Public Class FORM1 Or It Comes itself i.e. (Sub button1click Comes On Clicking button1 But We Can Type It Too).My Computer Does Not Show Public Sub, Private Sub etc. It Only Shows Sub
3.When I Try To Declare The Global Variables I Do Not Have The Option Of FileStream,BinaryReader Or BinaryWriter.I Also Have Problems With The Next Two Parts Of The Tutorial But I Will Post Them Later But First I Have To Get The Answers Of The Above Questions.STEP BY STEP AND PACE BY PACE A LITTLE PATIENCE WINS YOU THE RACE.

Cheers mate, hopefully I can answer your questions

1) Imports System.IO simply saves you from writing System.IO.Streamwriter etc, instead you can just write StreamWriter. You put this at the very top, before anything else.
2) If I understand your question correctly, you are asking if Class Form1 is written automatically. It should be when you create a new form, what version of Visual Basic are you using? Are you using Visual Basic.net?
3) Question 1 will solve this one ;)

Hope that helps, good luck mate.

Embi
 
Thank You Very Much Embi.I Understood Everything You Said And I Am Using SharpDevelop 2.But I Also Do Have Microsoft Visual Basic 6.0 Working Model Edition.
I Don't Know Which One To Use.
 
Vaisakh said:
Thank You Very Much Embi.I Understood Everything You Said And I Am Using SharpDevelop 2.But I Also Do Have Microsoft Visual Basic 6.0 Working Model Edition.
I Don't Know Which One To Use.

No problem mate, thanks for the rep ;)

SharpDevelop 2 uses Visual Basic.net, which is a newer version of Visual Basic 6, so I would recommend you use SharpDevelop.

With SharpDevelop 2, you can also use another language called C#, but its quite different from Visual Basic so I wouldn't recommend it to anyone who is learning VB. Otherwise, its a good route to get into C and C++ programming.

Is anyone else willing to have a go at any of these tutorials?
 

Users who are viewing this thread

Top