home *** CD-ROM | disk | FTP | other *** search
/ Programmer 7500 / MAX_PROGRAMMERS.iso / VISUAL_B / CODIGO_2 / X_TAL4 / DEMODLL.FRM (.txt) < prev    next >
Encoding:
Visual Basic Form  |  1993-08-28  |  3.0 KB  |  100 lines

  1. VERSION 2.00
  2. Begin Form frmDemoDLL 
  3.    Caption         =   "XTAL.DLL Demo"
  4.    ClientHeight    =   4020
  5.    ClientLeft      =   105
  6.    ClientTop       =   690
  7.    ClientWidth     =   7365
  8.    Height          =   4710
  9.    Left            =   45
  10.    LinkTopic       =   "Form2"
  11.    ScaleHeight     =   4020
  12.    ScaleWidth      =   7365
  13.    Top             =   60
  14.    Width           =   7485
  15.    Begin CommonDialog CMDialog1 
  16.       CancelError     =   -1  'True
  17.       Left            =   135
  18.       Top             =   3405
  19.    End
  20.    Begin Label Label1 
  21.       Caption         =   "Warning: All changes are made to the original file. Make sure you have backed up your reports."
  22.       FontBold        =   -1  'True
  23.       FontItalic      =   0   'False
  24.       FontName        =   "MS Sans Serif"
  25.       FontSize        =   12
  26.       FontStrikethru  =   0   'False
  27.       FontUnderline   =   0   'False
  28.       Height          =   1275
  29.       Left            =   1695
  30.       TabIndex        =   0
  31.       Top             =   450
  32.       Width           =   3405
  33.       WordWrap        =   -1  'True
  34.    End
  35.    Begin Menu mnuDemo 
  36.       Caption         =   "&Demo"
  37.       Begin Menu mnuGetLabelDimensions 
  38.          Caption         =   "&Label Dimensions..."
  39.       End
  40.       Begin Menu mnuGetReportDescriptions 
  41.          Caption         =   "&Report Title..."
  42.       End
  43.       Begin Menu mnuSetFaceName 
  44.          Caption         =   "&Font..."
  45.       End
  46.       Begin Menu sep1 
  47.          Caption         =   "-"
  48.       End
  49.       Begin Menu mnuExit 
  50.          Caption         =   "E&xit"
  51.       End
  52.    End
  53. Option Explicit
  54. Sub Form_Unload (Cancel As Integer)
  55.     Unload frmReadDescriptions
  56.     Unload frmGetSetDimen
  57. End Sub
  58. Sub mnuExit_Click ()
  59.     Unload frmDemoDLL
  60. End Sub
  61. Sub mnuGetLabelDimensions_Click ()
  62.   frmGetSetDimen.Show 1
  63. End Sub
  64. Sub mnuGetReportDescriptions_Click ()
  65.     frmReadDescriptions.Show 1
  66. End Sub
  67. Sub mnuSetFaceName_Click ()
  68.     Dim saveErr As Integer
  69.     Dim fontFace As String
  70.     Dim nFontSize As Integer
  71.     Dim report As String
  72.     Dim errcode As Integer
  73.     On Error Resume Next
  74.         cmdialog1.FontName = ""
  75.         cmdialog1.FontSize = 0
  76.         cmdialog1.Flags = CF_PRINTERFONTS
  77.         cmdialog1.Action = DLG_FONT
  78.         saveErr = Err
  79.     On Error GoTo 0
  80.     If saveErr <> 0 Then Exit Sub
  81.     MsgBox "Reminder: Font Style is not used.", 32
  82.     fontFace = cmdialog1.FontName
  83.     nFontSize = cmdialog1.FontSize
  84.     cmdialog1.DialogTitle = "Select Report To Modify"
  85.     cmdialog1.Filename = ""
  86.     cmdialog1.Filter = "Reports (*.rpt) | *.rpt "
  87.     cmdialog1.FilterIndex = 1
  88.     cmdialog1.Flags = OFN_PATHMUSTEXIST
  89.     On Error Resume Next
  90.         cmdialog1.Action = DLG_FILE_OPEN
  91.         saveErr = Err
  92.     On Error GoTo 0
  93.     If saveErr <> 0 Then Exit Sub
  94.     mousepointer = 11
  95.     report = cmdialog1.Filename
  96.     SetFontAll report, fontFace, nFontSize, errcode
  97.     If errcode Then MsgBox Str$(errcode)
  98.     mousepointer = 0
  99. End Sub
  100.