Computing.Net > Forums > Programming > How to: Edit Visual Basic Apps

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Click here to start participating now! Also, check out the New User Guide.

How to: Edit Visual Basic Apps

Reply to Message Icon

Name: eta378
Date: March 9, 2005 at 14:08:01 Pacific
OS: Windows XP
CPU/Ram: 512
Comment:

Ok, I have several questions regarding VB with M$ Visual Basic Studio 6.0 installed as my vb tool.

-Firstly, how do you take a program you created and turn it into a stand-alone program? For example, if I were to create a calculator, it is saved as "Calculator.frm" - How could I turn this into an .exe so I could run it on windows without turning on Visual Basic.

-Second, How do you edit apps that were originally created in vb? Example - I have an friend's app edited in vb that is a .exe.(if you look at the icon, its a little vb rectangle with the teal title bar tilted to the left)

-Third, I'm trying to create a average calculator where the user enters numbers in several text boxes, then hits calculate. I wrote it, but deleted it after it failed. So I'll write it real quick here:

dim avg as double
avg=(text1.text + text2.text + text3.text) / 3
Label1.Caption="The average is " & avg

Whenever I hit "Calculate," all of the text boxes with the numbers turn to 0 and the average is 0......

Help would me much appreciated =)
Thanks in advance
-eta378



Sponsored Link
Ads by Google

Response Number 1
Name: StuartS
Date: March 9, 2005 at 14:51:46 Pacific
Reply:

To turn the source code calculator.from into a programme click File Make xxxxxx. xxxxx being the name of the application you have given it.

for the second question, you cant. You need the source code to edit a compiled programme.

As for the average, there is nothing in it that I can see that is wrong. There is something else making the boxes zero.

Stuart


0

Response Number 2
Name: eta378
Date: March 9, 2005 at 17:58:02 Pacific
Reply:

Thnx ALOT for the fast reply Stuart! The only thing is, i just retried my formula for the average, and its incorrect - if you enter 5 in all three text boxes, the average comes out to be 185. What am I doing wrong?

Everything else works tho!


0

Response Number 3
Name: StuartS
Date: March 9, 2005 at 18:13:40 Pacific
Reply:

Try this:

Dim avg As Double
avg = (CDbl(Text1.Text) + CDbl(Text2.Text) + CDbl(Text3.Text)) / 3
Label1.Caption = "The average is " & avg

Cdbl converts the value in the Text Box to a Double, the same as avg.

Stuart


0

Response Number 4
Name: browser
Date: March 10, 2005 at 06:28:23 Pacific
Reply:

eta, what is the rest of the code? Perhaps we might see something.

Browser


0

Response Number 5
Name: eta378
Date: March 10, 2005 at 09:08:27 Pacific
Reply:

It's ok browser - Stuart fixed my error.

Thanks again fellaz

~Problem solved~


0

Related Posts

See More



Sponsored Link
Ads by Google
Reply to Message Icon

linked lists/external fil... Dev C++ kills my system



Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Programming Forum Home


Sponsored links

Ads by Google


Results for: How to: Edit Visual Basic Apps

how to in visual basic .exe to .frm www.computing.net/answers/programming/how-to-in-visual-basic-exe-to-frm/5292.html

Using Alt in visual basic www.computing.net/answers/programming/using-alt-in-visual-basic/6067.html

Visual Basic.......help! www.computing.net/answers/programming/visual-basichelp/889.html