VB School Assignment? Project Due Tomorrow? Chat LIVE With A Programming Expert!
Home
Forums
Programming
Web Development
Tutorials
Snippets
Blogs
Freelance
Jobs
Lounge
Login
Join for Free!
Code Snippets
Visual Basic Source Code
You're Browsing As A Guest! Register Now...
Become a VB Expert!
Join 358,485 VB Programmers for FREE!
Get instant access to thousands
of VB experts, tutorials, code snippets, and more! There are 2,185 people online right now.
Registration is fast and FREE...
Join Now!
Chat
LIVE
With a VB Expert
Pythagoras' Theorem
Finding the hypotenuse.
Submitted By:
firebolt
Actions:
Rating:
0
1
2
3
4
5
Views:
896
Language:
Visual Basic
Last Modified:
April 20, 2009
Instructions:
Place in a command button.
Snippet
Dim
a
As
Single
Dim
b
As
Single
Dim
c
As
Single
Cls
a =
InputBox
(
"Enter Side A"
)
b =
InputBox
(
"Enter Side B"
)
c =
Sqr
(
a ^
2
+ b ^
2
)
Print
c
Copy & Paste
Dim a As Single Dim b As Single Dim c As Single Cls a = InputBox("Enter Side A") b = InputBox("Enter Side B") c = Sqr(a ^ 2 + b ^ 2) Print c
Comments
There are currently no comments for this snippet. Be the first to comment!
Add comment
You must be registered and logged on to </dream.in.code> to leave comments.
Advertising
|
Terms of Use
|
Privacy Policy
|
About Us
|
Site Map
Forum Index:
Programming Help
|
C and C++
|
VB6
|
Java
|
VB.NET
|
C#
|
ASP.NET
|
PHP
|
ColdFusion
|
Perl and Python
|
Ruby
|
Databases
|
Other Languages
|
Game Programming
|
Mobile Development
|
Software Development
|
Computer Science
|
Industry News
|
52 Weeks Of Code
|
Programming Tutorials
|
C++ Tutorials
|
Visual Basic Tutorials
|
Java Tutorials
|
VB.NET Tutorials
|
C# Tutorials
|
Linux Tutorials
|
PHP Tutorials
|
ColdFusion Tutorials
|
Windows Tutorials
|
HTML/JavaScript Tutorials
|
CSS Tutorials
|
Flash Tutorials
|
Web Promotion Tutorials
|
Graphic Design & Photoshop Tutorials
|
Software Development Tutorials
|
Database Tutorials
|
Other Language Tutorials
|
ASP.NET Tutorials
|
Game Programming Tutorials
|
WPF & Silverlight Tutorials
|
Mobile Development Tutorials
|
Python Tutorials
|
Ruby Tutorials
|
Copyright 2001-2010
MediaGroup1 LLC
, All Rights Reserved
A
MediaGroup1 LLC
Production - Version 6.0.2.1.36
Server: secure2
Search
Updated!
w00t
Over 509,000 Pages!
Advanced Forum Search
Live VB Help!
Be Social
VB Tutorials
Visual Basic 6 Library Functions – String Type
File Handling in Visual Basic 6 Part 1 - Sequential Files
Visual Basic 6 Quick Reference (Cheat Sheet)
Resize Form & Controls For Screen Size - VB6
Connecting to a SQL Server database using ADODB
Visual Basic 6 Library Functions – Numeric Type
DISASSEMBLING VISUAL BASIC APPLICATIONS
Visual Basic 6 -Determining Each Character in VB
VB Timer
File Handling in Visual Basic 6 Part 2 - Binary File Handling
65 More VB Tutorials...
Reference Sheets
VB Snippets
Reading a Text file Line by Line
Open & Saving .txt files
Shutdown Computer from VB
RoundUp and RoundDown functions in VB 6.0
Starting an *.exe file from VB6 code
calculator
Analog Clock
Decimal to Binary
Open/Close your CD-Drive.
Open/Close your CD-Drive door.
231 More VB Snippets...
DIC Chatroom
Join our IRC Chat
Bye Bye Ads
Monthly Drawing
Top Contributors
Top 10 Kudos This Month
Martyn.Rae
(1200)
Dogstopper
(250)
coden4fun
(250)
FlashM
(100)
aniri
(100)
Asscotte
(100)
Anarion
(100)
macosxnerd101
(75)
David W
(75)
krismania
(50)
Programming Help
C and C++
VB6
Java
VB.NET
C#
ASP.NET
PHP
ColdFusion
Perl and Python
Ruby
Databases
Other Languages
Game Programming
Mobile Development
Software Development
Computer Science
Industry News
52 Weeks Of Code
Web Development
Web Development
HTML & CSS
JavaScript
Graphic Design
Flash & ActionScript
Blogging
SEO & Advertising
Web Servers & Hosting
Site Check
What's Here?
Members:
358,485
Replies:
966,640
Topics:
163,457
Snippets:
4,999
Tutorials:
1,329
Total Online:
2,185
Members:
120
Guests:
2,065