form1.frm
来自「可以产生随机网络拓扑(包括waxman等多种模型)的源码」· FRM 代码 · 共 51 行
FRM
51 行
VERSION 5.00
Begin VB.Form Form1
Caption = "Form1"
ClientHeight = 3885
ClientLeft = 60
ClientTop = 450
ClientWidth = 4200
LinkTopic = "Form1"
ScaleHeight = 3885
ScaleWidth = 4200
StartUpPosition = 3 'Windows Default
Begin VB.TextBox Text1
Height = 3615
Left = 120
MultiLine = -1 'True
TabIndex = 0
Top = 120
Width = 3855
End
End
Attribute VB_Name = "Form1"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Form_Load()
Dim string_api As String
Dim x As Double
' building a string using syntax from the "String-API"
api_string = "normal()"
' obtain a handle to the generator object
unuran_handle = unuran_create(api_string)
If (unuran_handle > 0) Then
For i = 1 To 10
' sample and show the generated random numbers
x = unuran_sample(unuran_handle)
Text1 = Text1 & x & vbCrLf
Next i
' freeing the generator object
Call unuran_destroy(unuran_handle)
Else
Text1 = "ERROR: random-generator could not be initialized"
End If
End Sub
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?