home *** CD-ROM | disk | FTP | other *** search
/ Programming Tool Box / SIMS_2.iso / code / cdspy / f_search.frm < prev    next >
Text File  |  1995-02-27  |  4KB  |  142 lines

  1. VERSION 2.00
  2. Begin Form F_Search 
  3.    BorderStyle     =   3  'Fixed Double
  4.    ClientHeight    =   1620
  5.    ClientLeft      =   1815
  6.    ClientTop       =   1770
  7.    ClientWidth     =   3225
  8.    Height          =   2025
  9.    Left            =   1755
  10.    LinkTopic       =   "Form1"
  11.    ScaleHeight     =   1620
  12.    ScaleWidth      =   3225
  13.    Top             =   1425
  14.    Width           =   3345
  15.    Begin CommandButton Cmd_Abbruch 
  16.       BackColor       =   &H00C0C0C0&
  17.       Caption         =   "&Abbruch"
  18.       FontBold        =   0   'False
  19.       FontItalic      =   0   'False
  20.       FontName        =   "Arial"
  21.       FontSize        =   9.75
  22.       FontStrikethru  =   0   'False
  23.       FontUnderline   =   0   'False
  24.       Height          =   375
  25.       Left            =   1670
  26.       TabIndex        =   2
  27.       Top             =   1080
  28.       Width           =   1365
  29.    End
  30.    Begin TextBox Txt_Stichwort 
  31.       FontBold        =   0   'False
  32.       FontItalic      =   0   'False
  33.       FontName        =   "Arial"
  34.       FontSize        =   9.75
  35.       FontStrikethru  =   0   'False
  36.       FontUnderline   =   0   'False
  37.       Height          =   390
  38.       Left            =   180
  39.       MaxLength       =   50
  40.       TabIndex        =   0
  41.       Top             =   450
  42.       Width           =   2835
  43.    End
  44.    Begin CommandButton Cmd_Suche 
  45.       BackColor       =   &H00C0C0C0&
  46.       Caption         =   "&Suche"
  47.       FontBold        =   0   'False
  48.       FontItalic      =   0   'False
  49.       FontName        =   "Arial"
  50.       FontSize        =   9.75
  51.       FontStrikethru  =   0   'False
  52.       FontUnderline   =   0   'False
  53.       Height          =   375
  54.       Left            =   180
  55.       TabIndex        =   1
  56.       Top             =   1080
  57.       Width           =   1365
  58.    End
  59.    Begin Line Line1 
  60.       X1              =   180
  61.       X2              =   3000
  62.       Y1              =   960
  63.       Y2              =   960
  64.    End
  65.    Begin Label Label1 
  66.       AutoSize        =   -1  'True
  67.       Caption         =   "Suchbegriff:"
  68.       FontBold        =   0   'False
  69.       FontItalic      =   0   'False
  70.       FontName        =   "Arial"
  71.       FontSize        =   9.75
  72.       FontStrikethru  =   0   'False
  73.       FontUnderline   =   0   'False
  74.       Height          =   240
  75.       Left            =   180
  76.       TabIndex        =   3
  77.       Top             =   180
  78.       Width           =   1020
  79.    End
  80. End
  81. Option Explicit
  82. Option Compare Text
  83.  
  84. Sub Cmd_Abbruch_Click ()
  85.   Unload Me
  86. End Sub
  87.  
  88. Sub Cmd_Suche_Click ()
  89.   GM_Searchtext$ = (Txt_Stichwort.Text)
  90.   If Trim$(GM_Searchtext$) = "" Then Exit Sub
  91.   If Me.Caption = GCM_STICHWORTSUCHE Then
  92.     screen.MousePointer = 11 ' Sanduhr
  93.     GM_Searchtitle$ = "Stichwortsuche - " & GM_Searchtext$
  94.     Dim FrmSti As New F_Stichtext
  95.     On Error Resume Next
  96.     FrmSti.Show
  97.     If Err = 364 Then ' Keine EintrΣge gefunden
  98.       Me.SetFocus
  99.       screen.MousePointer = 0 ' Default
  100.       Exit Sub
  101.     End If
  102.     screen.MousePointer = 0 ' Default
  103.     Unload Me
  104.   Else
  105.     screen.MousePointer = 11 ' Sanduhr
  106.     GM_Searchtitle$ = "Titeltextsuche - " & GM_Searchtext$
  107.     Dim FrmNew As New F_Titletext
  108.     On Error Resume Next
  109.     FrmNew.Show
  110.     If Err = 364 Then ' Keine EintrΣge gefunden
  111.       Me.SetFocus
  112.       screen.MousePointer = 0 ' Default
  113.       Exit Sub
  114.     End If
  115.     screen.MousePointer = 0 ' Default
  116.     Unload Me
  117.   End If
  118.   'Txt_Stichwort.SetFocus
  119. End Sub
  120.  
  121. Sub Form_Load ()
  122.   Me.Move (screen.Width - Me.Width) / 2, (screen.Height - Me.Height) / 3
  123.   
  124. End Sub
  125.  
  126. Sub Form_Resize ()
  127. Show3d Me
  128. End Sub
  129.  
  130. Sub Txt_Stichwort_GotFocus ()
  131.   Txt_Stichwort.SelStart = 0
  132.   Txt_Stichwort.SelLength = Len(Txt_Stichwort.Text)
  133. End Sub
  134.  
  135. Sub Txt_Stichwort_KeyPress (KeyAscii As Integer)
  136.   If KeyAscii = 13 Then
  137.     KeyAscii = 0
  138.     Cmd_Suche = True
  139.   End If
  140. End Sub
  141.  
  142.