home *** CD-ROM | disk | FTP | other *** search
/ Master 95 #1 / MASTER95_1.iso / microsof / vbasic4 / vb4-6.cab / mailoptf.frm (.txt) < prev    next >
Encoding:
Visual Basic Form  |  1995-07-26  |  9.0 KB  |  270 lines

  1. VERSION 4.00
  2. Begin VB.Form MailOptFrm 
  3.    BorderStyle     =   3  'Fixed Dialog
  4.    Caption         =   "Mail Options"
  5.    ClientHeight    =   3195
  6.    ClientLeft      =   3060
  7.    ClientTop       =   6060
  8.    ClientWidth     =   7500
  9.    ControlBox      =   0   'False
  10.    Height          =   3555
  11.    Left            =   3000
  12.    LinkTopic       =   "Form1"
  13.    ScaleHeight     =   3195
  14.    ScaleWidth      =   7500
  15.    Top             =   5760
  16.    Width           =   7620
  17.    Begin VB.PictureBox MessageOption 
  18.       BorderStyle     =   0  'None
  19.       Enabled         =   0   'False
  20.       Height          =   555
  21.       Left            =   3720
  22.       ScaleHeight     =   555
  23.       ScaleWidth      =   3735
  24.       TabIndex        =   12
  25.       TabStop         =   0   'False
  26.       Top             =   0
  27.       Visible         =   0   'False
  28.       Width           =   3735
  29.       Begin VB.CheckBox retRecip 
  30.          Caption         =   "&Return Receipt"
  31.          BeginProperty Font 
  32.             name            =   "MS Sans Serif"
  33.             charset         =   0
  34.             weight          =   400
  35.             size            =   9.75
  36.             underline       =   0   'False
  37.             italic          =   0   'False
  38.             strikethrough   =   0   'False
  39.          EndProperty
  40.          Height          =   375
  41.          Left            =   960
  42.          TabIndex        =   8
  43.          Top             =   120
  44.          Width           =   1815
  45.       End
  46.    End
  47.    Begin VB.PictureBox GeneralOption 
  48.       BorderStyle     =   0  'None
  49.       Enabled         =   0   'False
  50.       Height          =   2535
  51.       Left            =   0
  52.       ScaleHeight     =   2535
  53.       ScaleWidth      =   3675
  54.       TabIndex        =   11
  55.       TabStop         =   0   'False
  56.       Top             =   0
  57.       Visible         =   0   'False
  58.       Width           =   3675
  59.       Begin VB.CheckBox DownLoad 
  60.          Caption         =   "&Download Mail"
  61.          BeginProperty Font 
  62.             name            =   "MS Sans Serif"
  63.             charset         =   0
  64.             weight          =   400
  65.             size            =   9.75
  66.             underline       =   0   'False
  67.             italic          =   0   'False
  68.             strikethrough   =   0   'False
  69.          EndProperty
  70.          Height          =   255
  71.          Left            =   120
  72.          TabIndex        =   1
  73.          Top             =   480
  74.          Width           =   3315
  75.       End
  76.       Begin VB.CheckBox NewSess 
  77.          Caption         =   "&New Session"
  78.          BeginProperty Font 
  79.             name            =   "MS Sans Serif"
  80.             charset         =   0
  81.             weight          =   400
  82.             size            =   9.75
  83.             underline       =   0   'False
  84.             italic          =   0   'False
  85.             strikethrough   =   0   'False
  86.          EndProperty
  87.          Height          =   255
  88.          Left            =   120
  89.          TabIndex        =   2
  90.          Top             =   840
  91.          Width           =   3195
  92.       End
  93.       Begin VB.CheckBox LogonUI 
  94.          Caption         =   "&Logon UI"
  95.          BeginProperty Font 
  96.             name            =   "MS Sans Serif"
  97.             charset         =   0
  98.             weight          =   400
  99.             size            =   9.75
  100.             underline       =   0   'False
  101.             italic          =   0   'False
  102.             strikethrough   =   0   'False
  103.          EndProperty
  104.          Height          =   315
  105.          Left            =   120
  106.          TabIndex        =   3
  107.          Top             =   1200
  108.          Width           =   3135
  109.       End
  110.       Begin VB.TextBox UserName 
  111.          BeginProperty Font 
  112.             name            =   "System"
  113.             charset         =   0
  114.             weight          =   700
  115.             size            =   9.75
  116.             underline       =   0   'False
  117.             italic          =   0   'False
  118.             strikethrough   =   0   'False
  119.          EndProperty
  120.          Height          =   360
  121.          Left            =   1380
  122.          TabIndex        =   5
  123.          Top             =   1620
  124.          Width           =   2115
  125.       End
  126.       Begin VB.TextBox MailPassWord 
  127.          BeginProperty Font 
  128.             name            =   "System"
  129.             charset         =   0
  130.             weight          =   700
  131.             size            =   9.75
  132.             underline       =   0   'False
  133.             italic          =   0   'False
  134.             strikethrough   =   0   'False
  135.          EndProperty
  136.          Height          =   360
  137.          Left            =   1380
  138.          PasswordChar    =   "*"
  139.          TabIndex        =   7
  140.          Top             =   2040
  141.          Width           =   2115
  142.       End
  143.       Begin VB.CheckBox SendMapiDLG 
  144.          Caption         =   "&Send with MAPI Dialogs"
  145.          BeginProperty Font 
  146.             name            =   "MS Sans Serif"
  147.             charset         =   0
  148.             weight          =   400
  149.             size            =   9.75
  150.             underline       =   0   'False
  151.             italic          =   0   'False
  152.             strikethrough   =   0   'False
  153.          EndProperty
  154.          Height          =   315
  155.          Left            =   120
  156.          TabIndex        =   0
  157.          Top             =   60
  158.          Width           =   3255
  159.       End
  160.       Begin VB.Label Label1 
  161.          AutoSize        =   -1  'True
  162.          BackStyle       =   0  'Transparent
  163.          Caption         =   "&User Name:"
  164.          BeginProperty Font 
  165.             name            =   "MS Sans Serif"
  166.             charset         =   0
  167.             weight          =   400
  168.             size            =   9.75
  169.             underline       =   0   'False
  170.             italic          =   0   'False
  171.             strikethrough   =   0   'False
  172.          EndProperty
  173.          Height          =   240
  174.          Left            =   120
  175.          TabIndex        =   4
  176.          Top             =   1740
  177.          Width           =   1080
  178.       End
  179.       Begin VB.Label Label2 
  180.          AutoSize        =   -1  'True
  181.          BackStyle       =   0  'Transparent
  182.          Caption         =   "&Password:"
  183.          BeginProperty Font 
  184.             name            =   "MS Sans Serif"
  185.             charset         =   0
  186.             weight          =   400
  187.             size            =   9.75
  188.             underline       =   0   'False
  189.             italic          =   0   'False
  190.             strikethrough   =   0   'False
  191.          EndProperty
  192.          Height          =   240
  193.          Left            =   240
  194.          TabIndex        =   6
  195.          Top             =   2160
  196.          Width           =   945
  197.       End
  198.    End
  199.    Begin VB.CommandButton CancelBt 
  200.       Cancel          =   -1  'True
  201.       Caption         =   "Cancel"
  202.       Height          =   375
  203.       Left            =   1980
  204.       TabIndex        =   10
  205.       Top             =   2640
  206.       Width           =   1035
  207.    End
  208.    Begin VB.CommandButton OkBt 
  209.       Caption         =   "OK"
  210.       Default         =   -1  'True
  211.       Height          =   375
  212.       Left            =   720
  213.       TabIndex        =   9
  214.       Top             =   2640
  215.       Width           =   1035
  216.    End
  217. Attribute VB_Name = "MailOptFrm"
  218. Attribute VB_Creatable = False
  219. Attribute VB_Exposed = False
  220. Private Sub CancelBt_Click()
  221.     ' Unload the current form, and don't save changes.
  222.     Unload Me
  223. End Sub
  224. Private Sub Form_Load()
  225.     ' Setup initial values for the check boxes and edit fields.
  226.     UserName = VBMail.MapiSess.UserName
  227.     MailPassWord = VBMail.MapiSess.Password
  228.     NewSession = Abs(VBMail.MapiSess.NewSession)
  229.     LogonUI = Abs(VBMail.MapiSess.LogonUI)
  230.     DownloadMail = Abs(VBMail.MapiSess.DownloadMail)
  231.     SendMapiDLG = Abs(SendWithMapi)
  232.     RetRecip = Abs(ReturnRequest)
  233.     Select Case OptionType
  234.         Case conOptionMessage
  235.             Call SetupOptionForm(MessageOption)
  236.         Case conOptionGeneral
  237.             Call SetupOptionForm(GeneralOption)
  238.     End Select
  239. End Sub
  240. Private Sub Form_Unload(Cancel As Integer)
  241.     Select Case OptionType
  242.         Case conOptionMessage
  243.             Call SetupOptionForm(MessageOption)
  244.         Case conOptionGeneral
  245.             Call SetupOptionForm(GeneralOption)
  246.     End Select
  247. End Sub
  248. Private Sub OkBt_Click()
  249.     ' Save the user's changes.
  250.     ' Feature addition: Save values to an .INI file.
  251.     VBMail.MapiSess.UserName = UserName
  252.     VBMail.MapiSess.Password = MailPassWord
  253.     VBMail.MapiSess.NewSession = NewSession
  254.     VBMail.MapiSess.LogonUI = LogonUI
  255.     VBMail.MapiSess.DownloadMail = DownloadMail
  256.     SendWithMapi = SendMapiDLG
  257.     ReturnRequest = RetRecip
  258.     Unload Me
  259. End Sub
  260. Private Sub SetupOptionForm(BasePic As Control)
  261.     BasePic.Top = 0
  262.     BasePic.Left = 0
  263.     BasePic.Visible = True
  264.     BasePic.Enabled = True
  265.     OkBt.Top = BasePic.Height + 120
  266.     CancelBt.Top = BasePic.Height + 120
  267.     Me.Width = BasePic.Width + 120
  268.     Me.Height = OkBt.Top + OkBt.Height + 495
  269. End Sub
  270.