home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The Houseplan Collection
/
HRCD2005.ISO
/
data1.cab
/
Zusatz
/
3DS
/
DATA2.Z
/
NorthDlg.frm
< prev
next >
Wrap
Text File
|
1999-08-17
|
4KB
|
166 lines
VERSION 5.00
Begin VB.Form NorthDlg
Caption = "Nordrichtung einstellen"
ClientHeight = 2205
ClientLeft = 60
ClientTop = 345
ClientWidth = 4680
LinkTopic = "Form1"
ScaleHeight = 2205
ScaleWidth = 4680
StartUpPosition = 3 'Windows Default
Begin VB.TextBox Radius
Height = 405
Left = 1800
TabIndex = 9
Text = "Text1"
Top = 1680
Width = 1215
End
Begin VB.TextBox yPos
Height = 405
Left = 2280
TabIndex = 7
Text = "Text1"
Top = 720
Width = 735
End
Begin VB.TextBox xPos
Height = 405
Left = 600
TabIndex = 5
Text = "Text1"
Top = 720
Width = 735
End
Begin VB.TextBox Angle
Height = 405
Left = 1080
TabIndex = 3
Text = "Text1"
Top = 120
Width = 2055
End
Begin VB.CommandButton DoUpdate
Caption = "Aktualisieren"
Height = 375
Left = 3360
TabIndex = 1
Top = 720
Width = 1215
End
Begin VB.CommandButton Quit
Caption = "Beenden"
Height = 375
Left = 3360
TabIndex = 0
Top = 240
Width = 1215
End
Begin VB.Label Label4
Caption = "Radius:"
Height = 255
Left = 120
TabIndex = 8
Top = 1755
Width = 1095
End
Begin VB.Label Label3
Caption = "y:"
Height = 255
Left = 1680
TabIndex = 6
Top = 795
Width = 255
End
Begin VB.Label Label2
Caption = "x:"
Height = 255
Left = 120
TabIndex = 4
Top = 795
Width = 255
End
Begin VB.Label Label1
Caption = "Winkel:"
Height = 255
Left = 120
TabIndex = 2
Top = 195
Width = 735
End
End
Attribute VB_Name = "NorthDlg"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit
Const PI As Single = 3.1415926
Dim exe As ArCon.ArCon
Private Sub Angle_Change()
Dim phi As Single, x As Single, y As Single, rad As Single
exe.GetCompas False, phi, x, y, rad
On Error GoTo done
phi = CDbl(Angle.Text) * PI / 180
exe.SetCompas False, phi, x, y, rad
done:
End Sub
Private Sub Radius_Change()
Dim phi As Single, x As Single, y As Single, rad As Single
exe.GetCompas False, phi, x, y, rad
On Error GoTo done
rad = CDbl(Radius.Text)
exe.SetCompas False, phi, x, y, rad
done:
End Sub
Private Sub DoUpdate_Click()
UpdateData
End Sub
Private Sub Form_Load()
Set exe = New ArCon.ArCon
exe.StartMe hWnd, ""
UpdateData
End Sub
Private Sub Form_Unload(Cancel As Integer)
exe.EndMe
Set exe = Nothing
End Sub
Private Sub Quit_Click()
Unload Me
End Sub
Private Sub UpdateData()
Dim phi As Single, x As Single, y As Single, rad As Single
exe.GetCompas False, phi, x, y, rad
Angle.Text = CStr(phi * 180 / PI)
xPos.Text = CStr(x)
yPos.Text = CStr(y)
Radius.Text = CStr(rad)
End Sub
Private Sub xPos_Change()
Dim phi As Single, x As Single, y As Single, rad As Single
exe.GetCompas False, phi, x, y, rad
On Error GoTo done
x = CDbl(xPos.Text)
exe.SetCompas False, phi, x, y, rad
done:
End Sub
Private Sub yPos_Change()
Dim phi As Single, x As Single, y As Single, rad As Single
exe.GetCompas False, phi, x, y, rad
On Error GoTo done
y = CDbl(yPos.Text)
exe.SetCompas False, phi, x, y, rad
done:
End Sub