home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Source Code / Visual Basic Source Code.iso / vbsource / pini10 / form1.frm (.txt) < prev    next >
Encoding:
Visual Basic Form  |  1995-01-07  |  3.4 KB  |  105 lines

  1. VERSION 2.00
  2. Begin Form Form1 
  3.    Caption         =   "Form1"
  4.    ClientHeight    =   3840
  5.    ClientLeft      =   1095
  6.    ClientTop       =   1485
  7.    ClientWidth     =   7305
  8.    Height          =   4245
  9.    Left            =   1035
  10.    LinkTopic       =   "Form1"
  11.    ScaleHeight     =   3840
  12.    ScaleWidth      =   7305
  13.    Top             =   1140
  14.    Width           =   7425
  15.    Begin CommandButton Command2 
  16.       Cancel          =   -1  'True
  17.       Caption         =   "Cancel"
  18.       Height          =   420
  19.       Left            =   3780
  20.       TabIndex        =   4
  21.       Top             =   3240
  22.       Width           =   1770
  23.    End
  24.    Begin CommandButton Command1 
  25.       Caption         =   "Write WIN.INI"
  26.       Height          =   420
  27.       Left            =   1350
  28.       TabIndex        =   1
  29.       Top             =   3240
  30.       Width           =   1770
  31.    End
  32.    Begin Label Label6 
  33.       BackStyle       =   0  'Transparent
  34.       Caption         =   "Testing=1...2...3..."
  35.       ForeColor       =   &H00FF0000&
  36.       Height          =   285
  37.       Left            =   540
  38.       TabIndex        =   7
  39.       Top             =   2430
  40.       Width           =   1770
  41.    End
  42.    Begin Label Label5 
  43.       BackStyle       =   0  'Transparent
  44.       Caption         =   "[PINI]"
  45.       ForeColor       =   &H00FF0000&
  46.       Height          =   285
  47.       Left            =   540
  48.       TabIndex        =   6
  49.       Top             =   2160
  50.       Width           =   1770
  51.    End
  52.    Begin Label Label4 
  53.       BackStyle       =   0  'Transparent
  54.       Caption         =   "Clicking on the ""Write WIN.INI"" button will write a new section called ""[PINI]"" in your WIN.INI file.  It will look like this:"
  55.       Height          =   420
  56.       Left            =   270
  57.       TabIndex        =   5
  58.       Top             =   1485
  59.       Width           =   6765
  60.    End
  61.    Begin Label Label2 
  62.       BackStyle       =   0  'Transparent
  63.       Caption         =   "Device="
  64.       ForeColor       =   &H00FF0000&
  65.       Height          =   285
  66.       Left            =   540
  67.       TabIndex        =   3
  68.       Top             =   1080
  69.       Width           =   825
  70.    End
  71.    Begin Label Label1 
  72.       BackStyle       =   0  'Transparent
  73.       Caption         =   "The following is found as the ""Device"" entry under the ""[Windows]"" section in the WIN.INI file.  Only one line of code is necessary to read or write to any INI file using PINI.BAS!"
  74.       Height          =   690
  75.       Left            =   270
  76.       TabIndex        =   2
  77.       Top             =   270
  78.       Width           =   6765
  79.    End
  80.    Begin Label Label3 
  81.       BackColor       =   &H00FF0000&
  82.       BackStyle       =   0  'Transparent
  83.       Caption         =   "ReadPINIString(""WIN.INI"",""Windows"",""Device"")"
  84.       ForeColor       =   &H00FF0000&
  85.       Height          =   285
  86.       Left            =   1350
  87.       TabIndex        =   0
  88.       Top             =   1080
  89.       Width           =   5415
  90.    End
  91. Option Explicit
  92. Sub Command1_Click ()
  93.     If WritePINIString("WIN.INI", "PINI", "Testing", "1...2...3...") Then
  94.         MsgBox ("Write successfull!")
  95.     Else
  96.         MsgBox ("Write NOT successfull!")
  97.     End If
  98. End Sub
  99. Sub Command2_Click ()
  100.     End
  101. End Sub
  102. Sub Form_Load ()
  103.     Label3.Caption = ReadPINIString("WIN.INI", "Windows", "Device")
  104. End Sub
  105.