home *** CD-ROM | disk | FTP | other *** search
/ Computerworld 1996 March / Computerworld_1996-03_cd.bin / idg_cd3 / utility / ssetup26 / choice1.fr_ / CHOICE1.FRM (.txt)
Encoding:
Visual Basic Form  |  1995-07-27  |  3.9 KB  |  138 lines

  1. VERSION 2.00
  2. Begin Form Form3 
  3.    BackColor       =   &H00C0C0C0&
  4.    BorderStyle     =   1  'Fixed Single
  5.    Caption         =   "Choose directory..."
  6.    ClientHeight    =   1368
  7.    ClientLeft      =   1140
  8.    ClientTop       =   1500
  9.    ClientWidth     =   6276
  10.    ControlBox      =   0   'False
  11.    Height          =   1692
  12.    Left            =   1092
  13.    LinkMode        =   1  'Source
  14.    LinkTopic       =   "Form3"
  15.    MaxButton       =   0   'False
  16.    MinButton       =   0   'False
  17.    ScaleHeight     =   1368
  18.    ScaleWidth      =   6276
  19.    Top             =   1224
  20.    Width           =   6372
  21.    Begin CommandButton Commande2 
  22.       Caption         =   "&Abort"
  23.       Height          =   375
  24.       Left            =   4680
  25.       TabIndex        =   1
  26.       Top             =   600
  27.       Width           =   1455
  28.    End
  29.    Begin CommandButton Commande3 
  30.       Caption         =   ">>"
  31.       Height          =   375
  32.       Left            =   4080
  33.       TabIndex        =   4
  34.       Top             =   600
  35.       Width           =   375
  36.    End
  37.    Begin TextBox Texte1 
  38.       Height          =   375
  39.       Left            =   120
  40.       TabIndex        =   3
  41.       Top             =   600
  42.       Width           =   3855
  43.    End
  44.    Begin CommandButton Commande1 
  45.       Caption         =   "OK"
  46.       Height          =   375
  47.       Left            =   4680
  48.       TabIndex        =   0
  49.       Top             =   120
  50.       Width           =   1455
  51.    End
  52.    Begin Label Etiquette1 
  53.       BackColor       =   &H00C0C0C0&
  54.       Caption         =   "Choose destination directory:"
  55.       Height          =   375
  56.       Left            =   120
  57.       TabIndex        =   2
  58.       Top             =   120
  59.       Width           =   4335
  60.    End
  61. Sub Commande1_Click ()
  62. UserPath$ = Texte1.Text
  63. If (UserPath$ = "") Then
  64. If (iLanguage% = LANGUAGE_FRENCH) Then
  65. MsgBox "Veuillez indiquer un r
  66. pertoire de destination!"
  67. MsgBox "Please give a destination directory!"
  68. End If
  69. Texte1.SetFocus
  70. Exit Sub
  71. End If
  72. szTest$ = Right$(UserPath$, 1)
  73. If (szTest$ <> "\") Then
  74.  UserPath$ = UserPath$ + "\"
  75. End If
  76. a% = IsFileName(UserPath$, FILENAME_DIRWITHSLASH, CHECK_ROOTDIRSEXIST)
  77. If (a% = 0) Then
  78. If (iLanguage% = LANGUAGE_FRENCH) Then
  79. MsgBox "D
  80. , ce r
  81. pertoire n' est pas valable: Veuillez indiquer un nom de r
  82. pertoire comme C:\ANCIEN\NOUVEAU"
  83. MsgBox "Sorry, this directory is not valid: Give a dos directory name like C:\OLDDIR\NEWDIR"
  84. End If
  85. Texte1.SetFocus
  86. Exit Sub
  87. End If
  88. UserPath$ = UCase$(UserPath)
  89. DirCanClose% = 1
  90. bIsSetupOK% = 1
  91. bUserAbort% = 0
  92. Unload Form3
  93. End Sub
  94. Sub Commande2_Click ()
  95. If (iLanguage% = LANGUAGE_FRENCH) Then
  96. a% = MsgBox("Etes vous certain de vouloir abandonner l' installation?", 36)
  97. a% = MsgBox("Are you sure you wish to cancel this installation?", 36)
  98. End If
  99. If (a% = 6) Then
  100. DirCanClose% = 1
  101. bIsSetupOK% = 0
  102. bUserAbort% = 1
  103. Unload Form3
  104. End If
  105. End Sub
  106. Sub Commande3_Click ()
  107. Dim sTemp As String * 256
  108. sTemp$ = String$(256, 0)
  109. Mid$(sTemp$, 1, Len(Texte1.Text)) = Texte1.Text
  110. Call SetupBrowseDir(Form3.hWnd, sTemp$)
  111. iZero% = InStr(sTemp$, Chr$(0))
  112. szTemp$ = Left$(sTemp$, iZero% - 1)
  113. Texte1.Text = szTemp$
  114. Texte1.SetFocus
  115. Texte1.SelStart = 0
  116. Texte1.SelLength = Len(Texte1.Text)
  117. End Sub
  118. Sub Form_Load ()
  119. DirCanClose% = 1
  120. Form3.Move (Screen.Height / 2) - (Height / 2), (Screen.Width / 2) - (Width / 2), Width, Height
  121. If (iLanguage% = LANGUAGE_FRENCH) Then
  122. Etiquette1.Caption = "Indiquez le r
  123. pertoire dans lequel vous souhaitez installer " + szProductName$
  124. Commande2.Caption = "&Abandonner"
  125. Etiquette1.Caption = "Choose destination directory for " + szProductName$
  126. Commande2.Caption = "&Abort"
  127. End If
  128. sTemp$ = szWinDir$ + szDefaultDir$
  129. Texte1.Text = sTemp$
  130. 'Texte1.SetFocus
  131. End Sub
  132. Sub Texte1_Change ()
  133. If (Len(Texte1.Text) < 3) Then
  134. Commande1.Enabled = 0
  135. Commande1.Enabled = 1
  136. End If
  137. End Sub
  138.