Pythagoras in VB6

Category:
Dates and Math
Type:
Snippets
Difficulty:
Beginning
Author:
Anonymous

Version Compatibility: Visual Basic 6

More information:
This code snippet will calculate the longest side of a 90 degree triangle, or the diagonal of a square. All you need is two TextBox controls, a Label, and a CommandButton and this single line of code.

Instructions: Copy the declarations and code below and paste directly into your VB project.

Declarations:

Code: