VERSION 5.00
Object = "{831FDD16-0C5C-11D2-A9FC-0000F8754DA1}#2.0#0"; "mscomctl.ocx"
Object = "{5E9E78A0-531B-11CF-91F6-C2863C385E30}#1.0#0"; "msflxgrd.ocx"
Begin VB.Form frm_help 
   Caption         =   "Help"
   ClientHeight    =   6720
   ClientLeft      =   1395
   ClientTop       =   390
   ClientWidth     =   6705
   ControlBox      =   0   'False
   LinkTopic       =   "Form1"
   MaxButton       =   0   'False
   MinButton       =   0   'False
   PaletteMode     =   1  'UseZOrder
   ScaleHeight     =   6720
   ScaleWidth      =   6705
   ShowInTaskbar   =   0   'False
   Begin VB.CommandButton ssp_quit 
      Height          =   612
      Left            =   6000
      Style           =   1  'Graphical
      TabIndex        =   0
      Top             =   6060
      Width           =   612
   End
   Begin MSComctlLib.TabStrip tbs_Help 
      Height          =   375
      Left            =   0
      TabIndex        =   2
      Top             =   0
      Width           =   6735
      _ExtentX        =   11880
      _ExtentY        =   661
      MultiRow        =   -1  'True
      _Version        =   393216
      BeginProperty Tabs {1EFB6598-857C-11D1-B16A-00C0F0283628} 
         NumTabs         =   2
         BeginProperty Tab1 {1EFB659A-857C-11D1-B16A-00C0F0283628} 
            Caption         =   "Maintenance"
            ImageVarType    =   2
         EndProperty
         BeginProperty Tab2 {1EFB659A-857C-11D1-B16A-00C0F0283628} 
            Caption         =   "Translation"
            ImageVarType    =   2
         EndProperty
      EndProperty
   End
   Begin VB.Frame frm_tabHelp 
      Height          =   5655
      Index           =   1
      Left            =   0
      TabIndex        =   13
      Top             =   600
      Width           =   6615
      Begin MSFlexGridLib.MSFlexGrid grd_Trans 
         Height          =   3435
         Left            =   120
         TabIndex        =   16
         Top             =   180
         Width           =   6375
         _ExtentX        =   11245
         _ExtentY        =   6059
         _Version        =   393216
         Cols            =   7
         FixedCols       =   0
         AllowBigSelection=   0   'False
         SelectionMode   =   1
         AllowUserResizing=   1
      End
      Begin VB.Frame frm_TransMemo 
         Caption         =   "Memo for translation"
         Height          =   1812
         Left            =   120
         TabIndex        =   14
         Top             =   3720
         Width           =   6372
         Begin VB.TextBox txt_TransMemo 
            BackColor       =   &H00FFFFFF&
            Height          =   1452
            Left            =   180
            Locked          =   -1  'True
            MultiLine       =   -1  'True
            TabIndex        =   15
            Top             =   240
            Width           =   6012
         End
      End
   End
   Begin VB.Frame frm_tabHelp 
      Height          =   5655
      Index           =   0
      Left            =   480
      TabIndex        =   1
      Top             =   0
      Width           =   6615
      Begin VB.Frame frm_Main1 
         Caption         =   "Entity maintenance done by"
         Height          =   1332
         Left            =   120
         TabIndex        =   9
         Top             =   240
         Width           =   6372
         Begin VB.TextBox txt_Main3 
            BackColor       =   &H00FFFFFF&
            Height          =   288
            Left            =   180
            Locked          =   -1  'True
            TabIndex        =   12
            Top             =   900
            Width           =   2652
         End
         Begin VB.TextBox txt_Main2 
            BackColor       =   &H00FFFFFF&
            Height          =   288
            Left            =   180
            Locked          =   -1  'True
            TabIndex        =   11
            Top             =   600
            Width           =   5532
         End
         Begin VB.TextBox txt_Main1 
            BackColor       =   &H00FFFFFF&
            Height          =   288
            Left            =   180
            Locked          =   -1  'True
            TabIndex        =   10
            Top             =   300
            Width           =   5532
         End
      End
      Begin VB.Frame frm_MainMemo 
         Caption         =   "Memo for maintenance"
         Height          =   2352
         Left            =   120
         TabIndex        =   7
         Top             =   3120
         Width           =   6372
         Begin VB.TextBox txt_MainMemo 
            BackColor       =   &H00FFFFFF&
            Height          =   1932
            Left            =   120
            Locked          =   -1  'True
            MultiLine       =   -1  'True
            TabIndex        =   8
            Top             =   240
            Width           =   5655
         End
      End
      Begin VB.Frame frm_Main2 
         Caption         =   "Backup person for maintenance"
         Height          =   1332
         Left            =   120
         TabIndex        =   3
         Top             =   1620
         Width           =   6372
         Begin VB.TextBox txt_Main4 
            BackColor       =   &H00FFFFFF&
            Height          =   288
            Left            =   180
            Locked          =   -1  'True
            TabIndex        =   6
            Top             =   300
            Width           =   5532
         End
         Begin VB.TextBox txt_Main5 
            BackColor       =   &H00FFFFFF&
            Height          =   288
            Left            =   180
            Locked          =   -1  'True
            TabIndex        =   5
            Top             =   600
            Width           =   5532
         End
         Begin VB.TextBox txt_Main6 
            BackColor       =   &H00FFFFFF&
            Height          =   288
            Left            =   180
            Locked          =   -1  'True
            TabIndex        =   4
            Top             =   900
            Width           =   2652
         End
      End
   End
End
Attribute VB_Name = "frm_help"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit

Private Sub Form_Load()

MouseOff

If gl_CodePage <> 1252 And gl_CodePage <> 0 Then ChangeCharset Me

ssp_quit.Picture = LoadResPicture(RES_QUIT, 1)
    
    ' NEW 22.1.2005 remove SSTab begin
    Call InitTabStrip(tbs_Help, frm_tabHelp)
    ' NEW 22.1.2005 remove SSTab end

Getcsts
GetInfos

    ' NEW 22.1.2005 remove SSTab begin
    Call SetTabStripVisible(tbs_Help, frm_tabHelp, True)
    ' NEW 22.1.2005 remove SSTab end

MouseOn

End Sub
Private Sub Getcsts()

Dim ls_Req As String
Dim ll_Statement As Long
Dim li_Status As Integer
Dim ls_Field As String, ls_Text As String

On Error GoTo suite

ls_Req = "EXEC Screen_Csts 'help', '" & gut_LangLogin.Code & "'"
If SQLSubmit(gl_Environment, gl_Database, ll_Statement, ls_Req) Then
    li_Status = SQL_SUCCESS
Else
    li_Status = SQL_ERROR
End If
grd_Trans.Row = 0
Do While li_Status = SQL_SUCCESS Or li_Status = SQL_SUCCESS_WITH_INFO
    li_Status = SQLFetch(ll_Statement)
    If li_Status = SQL_SUCCESS Or li_Status = SQL_SUCCESS_WITH_INFO Then
        ls_Field = ODBCData(ll_Statement, 1)
        ls_Text = ODBCData(ll_Statement, 2)
        Select Case ls_Field
        Case "title": Caption = ls_Text
        Case "frm_Main1": frm_Main1.Caption = ls_Text
        Case "frm_Main2": frm_Main2.Caption = ls_Text
        Case "c0"
            grd_Trans.Col = 0
            grd_Trans.Text = ls_Text
        Case "c1"
            grd_Trans.Col = 1
            grd_Trans.Text = ls_Text
        Case "c4"
            grd_Trans.Col = 4
            grd_Trans.Text = ls_Text
        Case "lbl_MainMemo"
            frm_MainMemo.Caption = ls_Text
        Case "lbl_TransMemo"
            frm_TransMemo.Caption = ls_Text
        End Select
    End If
Loop
li_Status = SQLFreeStatement(ll_Statement, SQL_DROP)
Exit Sub

suite:
li_Status = SQLFreeStatement(ll_Statement, SQL_DROP)
StdError
End Sub
Private Sub GetInfos()

Dim ls_Req As String
Dim ll_Statement As Long
Dim li_Status As Integer
Dim li_Count As Integer
Dim li_Count2 As Integer

On Error GoTo suite

ls_Req = "EXEC Help_Sel '" & gs_TableName & "'"
If SQLSubmit(gl_Environment, gl_Database, ll_Statement, ls_Req) Then
    li_Status = SQLFetch(ll_Statement)
    If li_Status = SQL_SUCCESS Or li_Status = SQL_SUCCESS_WITH_INFO Then
        txt_Main1 = ODBCData(ll_Statement, 1)
        txt_Main2 = ODBCData(ll_Statement, 2)
        txt_Main3 = ODBCData(ll_Statement, 3)
        txt_Main4 = ODBCData(ll_Statement, 4)
        txt_Main5 = ODBCData(ll_Statement, 5)
        txt_Main6 = ODBCData(ll_Statement, 6)
        txt_MainMemo = ODBCMemoGet(ll_Statement, 7)
        txt_TransMemo = ODBCMemoGet(ll_Statement, 8)
    End If
End If
li_Status = SQLFreeStatement(ll_Statement, SQL_DROP)
ls_Req = "EXEC Help_Sel2 '" & gs_TableName & "'"
If SQLSubmit(gl_Environment, gl_Database, ll_Statement, ls_Req) Then
    li_Count = 1
    grd_Trans.ColWidth(0) = 800
    grd_Trans.ColWidth(1) = 1200
    grd_Trans.ColWidth(2) = 1000
    grd_Trans.ColWidth(3) = 800
    grd_Trans.ColWidth(4) = 1200
    grd_Trans.ColWidth(5) = 1000
    grd_Trans.ColWidth(6) = 800
    li_Status = SQL_SUCCESS
    Do While li_Status = SQL_SUCCESS Or li_Status = SQL_SUCCESS_WITH_INFO
        li_Status = SQLFetch(ll_Statement)
        If li_Status = SQL_SUCCESS Or li_Status = SQL_SUCCESS_WITH_INFO Then
            grd_Trans.Rows = li_Count + 1
            grd_Trans.Row = li_Count
            For li_Count2 = 0 To 6
                grd_Trans.Col = li_Count2
                grd_Trans.Text = ODBCData(ll_Statement, li_Count2 + 1)
            Next li_Count2
            li_Count = li_Count + 1
        End If
    Loop
End If
li_Status = SQLFreeStatement(ll_Statement, SQL_DROP)
Exit Sub

suite:
li_Status = SQLFreeStatement(ll_Statement, SQL_DROP)
StdError
End Sub

Private Sub ssp_quit_Click()

MouseOff
Unload Me
MouseOn

End Sub


' NEW 22.1.2005 remove SSTab begin
Private Sub InitTabStrip(ByRef ao_tbStrip As MSComctlLib.TabStrip, ByRef ao_tabs As Object)
Dim lo_Object As Object
    For Each lo_Object In ao_tabs
        Select Case ao_tbStrip.Placement
            Case tabPlacementLeft
                Call lo_Object.Move(ao_tbStrip.left + ao_tbStrip.Width, ao_tbStrip.top)
            Case tabPlacementTop
                Call lo_Object.Move(ao_tbStrip.left, ao_tbStrip.top + ao_tbStrip.Height)
            Case tabPlacementRight
                Call lo_Object.Move(ao_tbStrip.left - lo_Object.Width, ao_tbStrip.top)
            Case tabPlacementBottom
                Call lo_Object.Move(ao_tbStrip.left, ao_tbStrip.top - lo_Object.Height)
        End Select
    Next
    
    For Each lo_Object In ao_tbStrip.Tabs
        lo_Object.Key = "_" & lo_Object.Index - 1
    Next
End Sub

Private Sub UpdateTabStrip(ByRef ao_tbStrip As MSComctlLib.TabStrip, ByRef ao_tabs As Object)
Dim lo_Object As Object
    For Each lo_Object In ao_tabs
        lo_Object.Visible = (lo_Object.Index = CLng(Mid(ao_tbStrip.SelectedItem.Key, 2)))
    Next
End Sub

Private Sub SetTabStripVisible(ByRef ao_tbStrip As MSComctlLib.TabStrip, ByRef ao_tabs As Object, ByVal ab_Visible As Boolean)
    ao_tbStrip.Visible = ab_Visible

    If ab_Visible Then
        Call UpdateTabStrip(ao_tbStrip, ao_tabs)
    Else
        Dim lo_Object As Object
        ' hide all tabs
        For Each lo_Object In ao_tabs
            lo_Object.Visible = False
        Next
    End If
End Sub

Private Sub tbs_Help_Click()
    MouseOff
    Call UpdateTabStrip(tbs_Help, frm_tabHelp)
    MouseOn
End Sub
' NEW 22.1.2005 remove SSTab end

