Home > Software engineering >  The younger brother novice for vb print function, a great god glad
The younger brother novice for vb print function, a great god glad

Time:09-26

The code below


Public Class Form1
Private Sub Form1_Click (sender As Object, As EventArgs e) Handles Me. Click
Const PI=3.1415926
Dim r As Double
Dim As Double s
R=InputBox (" please enter the radius ", "input radius")
S=PI * r * r
Print Now
The Print s

End Sub

Private Sub Form1_Load (sender As Object, As EventArgs e) Handles MyBase. Load

End Sub
The End of the Class

Print Now wrong type for the date type type cannot be converted to Interger
Print s wrong type for the s is a local variable must use parentheses, I wit to print (s) or error,

O great god glad

CodePudding user response:

This is the.net environment ah...

CodePudding user response:

Change the print to Debug. Print

CodePudding user response:

Put two text box
TextBox1. Text=DateTime. Now. The ToString ()
TextBox2. Text=s.T oString ()
  • Related