📄 逐跨活荷载.frm
字号:
VERSION 5.00
Begin VB.Form Form4
AutoRedraw = -1 'True
BorderStyle = 5 'Sizable ToolWindow
Caption = "逐跨活荷载计算"
ClientHeight = 3195
ClientLeft = 60
ClientTop = 285
ClientWidth = 4680
LinkTopic = "Form4"
MaxButton = 0 'False
MDIChild = -1 'True
MinButton = 0 'False
ScaleHeight = 3195
ScaleWidth = 4680
ShowInTaskbar = 0 'False
Begin VB.PictureBox Pict2
AutoRedraw = -1 'True
BackColor = &H80000007&
Height = 3150
Left = 30
MousePointer = 2 'Cross
ScaleHeight = 3090
ScaleWidth = 4575
TabIndex = 0
Top = 30
Width = 4630
End
End
Attribute VB_Name = "Form4"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit
Private Sub Form_Load()
Me.Height = 3600
Me.Width = 4800
Dim Fscal
Fscal = Pict2.Height / Pict2.Width
If Cengtot / Pict2.Height > Kuatot / Pict2.Width Then
Pict2.Scale (-1, Cengtot + 1)-((Cengtot + 2) / Fscal - 1, -1)
Else 'If Cengtot / Pict2.Height < Kuatot / Pict2.Width Then
Pict2.Scale (-1, (Kuatot + 2) * Fscal - 1)-(Kuatot + 1, -1)
End If
Call 杆件图2(Pict2)
End Sub
Sub 杆件图2(Pict As PictureBox)
Dim i As Integer, j As Integer
Dim temp1 As Single, temp As Single
Dim X1 As Single, Y1 As Single, x2 As Single, y2 As Single, sinA As Single, cosA As Single, L As Single
For i = 1 To Ncell
Pict.Line (XY(NGN(i, 1), 1), XY(NGN(i, 1), 2))-(XY(NGN(i, 2), 1), XY(NGN(i, 2), 2)), vbWhite
Next i
temp = Lx(1)
For i = 2 To Kuashu
If temp > Lx(i) Then temp = Lx(i)
Next i
For i = 0 To Kuashu
temp1 = temp1 + Lx(i)
Pict.Line (temp1 - temp / 4, 0)-(temp1 + temp / 4, 0), vbWhite
Next i
temp1 = 0
For i = 0 To Kuashu
temp1 = temp1 + Lx(i)
For j = 1 To 3
Pict.Line (temp1 + (1 + j - 2.5) * temp / 10, 0)-(temp1 + (j - 1 - 2.5) * temp / 10, -temp / 10), vbWhite
Next j
Next i
For i = 1 To Ncell ' 画杆件
Call SetT(i, L, sinA, cosA, X1, Y1, x2, y2)
If L > Lmax Then Lmax = L
' Pict.Line (X1, Y1)-(x2, y2), vbBlack
If Form1.Check1.Value = 1 Then
Pict.CurrentX = (X1 + x2) / 2
Pict.CurrentY = (Y1 + y2) / 2
Pict.ForeColor = vbGreen
Pict.Print Format(i, "##")
End If
Next i
For i = 1 To Nodg
If Form1.Check2.Value = 1 Then
Pict.CurrentX = XY(i, 1)
Pict.CurrentY = XY(i, 2)
Pict.ForeColor = vbBlue
Pict.Print Format(i, "##")
End If
Next i
End Sub
Private Sub Pict2_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
Dim X1 As Single
Dim Y1 As Single
Dim i As Integer
X1 = X: Y1 = Y
If Button = 1 Then
X1 = X: Y1 = Y
For i = 柱总数 + 1 To Ncell
If Abs(Y1 - XY(NGN(i, 1), 2)) < 1 And X1 > XY(NGN(i, 1), 1) And X1 < XY(NGN(i, 2), 1) Then
Call 杆件图2(Pict2)
Pict2.Line (XY(NGN(i, 1), 1), XY(NGN(i, 1), 2))-(XY(NGN(i, 2), 1), XY(NGN(i, 2), 2)), vbRed
击中构件号 = i
Call 生成荷载Ld(8)
Call Form1.Command1_Click
End If
Next i
End If
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -