⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 global.bas

📁 用于三次采油技术的经济评价
💻 BAS
字号:
Attribute VB_Name = "GLOBAL"

Global formbl_x As Single, formbl_y As Single
Global loadtab_bz As Integer                               '调用表格窗体标志
'----------- draw_line ---------------
Public Const grnum_max = 8         '绘制曲线总数
Public Const grpoint_max = 250     '曲线最多点数
Global yaxis_num As Integer
Global px1, py1, px2, py2 As Single
Global xaxis_type, xaxis_visible, TRborder_visible As Integer
Global xaxis_min, xaxis_max, xaxis_interval, twoyaxis_interval As Single
Global title_name$, xaxis_name$, xaxis_format$
Global title_fontsize, axis_fontsize, axisname_fontsize, grnote_fontsize As Single
   
Global yaxis_grnum(), yaxis_type() As Integer
Global yaxis_min(), yaxis_max(), yaxis_interval() As Single
Global yaxis_name$(), yaxis_format$()
   
Global grpoint(), gr_type(), grnote_visible(), grnote_LR() As Integer
Global grnote_name$()
Global Lstyle(), Lwidth(), Pstyle(), Pwidth() As Integer
Global Lcolor(), Pcolor() As Single

Global grdatx(), grdaty() As Single
Global grdatx_str$()
Global objBackColor


Function plotx(resx)
   plotx = bkx1 + 12 + ((bkx2 - 7) - (bkx1 + 12)) * resx / gridx
End Function

Function ploty(resy)
   ploty = bky1 + 13 + ((bky2 - 8) - (bky1 + 13)) * resy / gridy
End Function

Function fx_plotx(resx)
   fx_plotx = bkx1 + 5 + ((bkx2 - 5) - (bkx1 + 5)) * resx / gridx
End Function

Function fx_ploty(resy)
   fx_ploty = bky1 + 5 + ((bky2 - 5) - (bky1 + 5)) * resy / gridy
End Function

Function draw_plotx(resx)
   draw_plotx = forplot_x1 + (forplot_x2 - forplot_x1) * resx / gridx
End Function

Function draw_ploty(resy)
   draw_ploty = forplot_y1 + (forplot_y2 - forplot_y1) * resy / gridy
End Function

Function resx(plotx)
    resx = (plotx - (bkx1 + 12)) * gridx / ((bkx2 - 7) - (bkx1 + 12))
End Function

Function resy(ploty)
    resy = (ploty - (bky1 + 13)) * gridy / ((bky2 - 8) - (bky1 + 13))
End Function

Function fx_resx(plotx)
    fx_resx = (plotx - (bkx1 + 5)) * gridx / ((bkx2 - 5) - (bkx1 + 5))
End Function

Function fx_resy(ploty)
    fx_resy = (ploty - (bky1 + 5)) * gridy / ((bky2 - 5) - (bky1 + 5))
End Function

Function draw_resx(plotx)
    draw_resx = (plotx - forplot_x1) * gridx / (forplot_x2 - forplot_x1)
End Function

Function draw_resy(ploty)
    draw_resy = (ploty - forplot_y1) * gridy / (forplot_y2 - forplot_y1)
End Function

Public Sub adjust_size_form(obj1 As Object, bz1 As Integer, bz2 As Integer)
    If bz1 = -1 Then obj1.Height = obj1.Height * formbl_y
    obj1.Width = obj1.Width * formbl_x
    If bz2 = -1 Then obj1.FontSize = obj1.FontSize * formbl_x
    obj1.Left = obj1.Left * formbl_x
    obj1.Top = obj1.Top * formbl_y
End Sub

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -