Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Unable to display controltipstext on all listboxes 1

Status
Not open for further replies.

44nato44

Programmer
Dec 12, 2008
115
NL
Hi

I have numerouse list boxes which will display controltip text if certain conditions are met in a table (Please see code below)

The controltip text is shown on some boxes but my lstKPI and lstSLA for some reason they are not shown. The form produces error code 0 which I have ignorred for now as the form worked until I came down to lstSLA and lstKPI.

I am not sure if the controltip text has a limit of some sort, or maybe other things I need to think of ?

Hope anybody has an idea what I can look for ?

Thanks

Code :

' ****
' This function checks if the field needs to show if the field has been
' requested for approval
' ****

Dim rst As DAO.Recordset
Dim rstRebilling As DAO.Recordset
Dim strsql As String
Dim db As DAO.Database
Set db = CurrentDb()
Dim varnewval As String
Dim lngHighlight As Long
Dim NewValHlpTxt(10)
Dim e, i, p As Integer
Dim Countermethodofmeasure, CounterProductName, CounterServiceUnitDepartment As Byte
Dim CounterProductCode, CounterActive, CounterServiceDefinition, CounterTermsOfDelivery As Byte
Dim CounterServicelevelsKPITargets, CounterCOT, CounterFurtherSpecifications, CounterOperationalQuestionsAndComplaints As Byte
Dim CounterServiceWindowAvailability, CounterCostOfService, CounterLOB, CounterSLA, Counter3rdParty, CounterGlobalProductName As Byte
Dim CounterSubProduct, CounterSubUnitDep, CounterExternPCC, CounterValueDating, CounterServiceLevel, CounterTargets As Byte
Dim CounterContactAvailability, CounterSubProductDefinition
Dim lstboxAddChain, lstboxDelChain, lstboxAddRebil, lstboxDelRebil, lstboxAddSLARec, lstboxDelSLARec, lstboxAddKPIRec, lstboxDelKPIRec

lstboxAddRebil = ""
lstboxDelRebil = ""
lstboxAddChain = ""
lstboxDelChain = ""
lstboxAddSLARec = ""
lstboxDelSLARec = ""
lstboxAddKPIRec = ""
lstboxDelKPIRec = ""


' Set all fields to white background

Forms!FRM_PC_ProductAdmin!txtProductCode.BackColor = vbWhite
Forms!FRM_PC_ProductAdmin!txtProductName.BackColor = vbWhite
Forms!FRM_PC_ProductAdmin!txtGlbProductName.BackColor = vbWhite
Forms!FRM_PC_ProductAdmin!txtServiceWinAvailability.BackColor = vbWhite
Forms!FRM_PC_ProductAdmin!txtCostofService.BackColor = vbWhite
Forms!FRM_PC_ProductAdmin!txtMethodofService.BackColor = vbWhite
Forms!FRM_PC_ProductAdmin!cboServiceUnitDepartment.BackColor = vbWhite
Forms!FRM_PC_ProductAdmin!txtServiceDefinition.BackColor = vbWhite
Forms!FRM_PC_ProductAdmin!txtTermsofDelivery.BackColor = vbWhite
Forms!FRM_PC_ProductAdmin!txtCOT.BackColor = vbWhite
Forms!FRM_PC_ProductAdmin!txtFurtherSpecification.BackColor = vbWhite
Forms!FRM_PC_ProductAdmin!txtLOB.BackColor = vbWhite
Forms!FRM_PC_ProductAdmin!txtQuestionComplaints.BackColor = vbWhite
Forms!FRM_PC_ProductAdmin!txtContactAvailability.BackColor = vbWhite
Forms!FRM_PC_ProductAdmin!cbo3rdParty.BackColor = vbWhite
Forms!FRM_PC_ProductAdmin!cboSubProdCode.BackColor = vbWhite
Forms!FRM_PC_ProductAdmin!cboSubUnitDep.BackColor = vbWhite
Forms!FRM_PC_ProductAdmin!cboBuitenPCC.BackColor = vbWhite
Forms!FRM_PC_ProductAdmin!txtValueDating.BackColor = vbWhite
Forms!FRM_PC_ProductAdmin!txtServiceLevel.BackColor = vbWhite
Forms!FRM_PC_ProductAdmin!txtTargets.BackColor = vbWhite
Forms!FRM_PC_ProductAdmin!txtSubProductDefinition.BackColor = vbWhite
Forms!FRM_PC_ProductAdmin!LstlblRebillingCode.BackColor = vbWhite
Forms!FRM_PC_ProductAdmin!LstChain.BackColor = vbWhite
Forms!FRM_PC_ProductAdmin!LstSLA.BackColor = vbWhite
Forms!FRM_PC_ProductAdmin!LstKPI.BackColor = vbWhite

' Set all fields to black text

Forms!FRM_PC_ProductAdmin!txtProductCode.ForeColor = vbBlack
Forms!FRM_PC_ProductAdmin!txtProductName.ForeColor = vbBlack
Forms!FRM_PC_ProductAdmin!txtGlbProductName.BackColor = vbWhite
Forms!FRM_PC_ProductAdmin!txtServiceWinAvailability.ForeColor = vbBlack
Forms!FRM_PC_ProductAdmin!txtCostofService.ForeColor = vbBlack
Forms!FRM_PC_ProductAdmin!txtMethodofService.ForeColor = vbBlack
Forms!FRM_PC_ProductAdmin!cboServiceUnitDepartment.ForeColor = vbBlack
Forms!FRM_PC_ProductAdmin!txtServiceDefinition.ForeColor = vbBlack
Forms!FRM_PC_ProductAdmin!txtTermsofDelivery.ForeColor = vbBlack
Forms!FRM_PC_ProductAdmin!txtCOT.ForeColor = vbBlack
Forms!FRM_PC_ProductAdmin!txtFurtherSpecification.ForeColor = vbBlack
Forms!FRM_PC_ProductAdmin!txtLOB.ForeColor = vbBlack
Forms!FRM_PC_ProductAdmin!txtQuestionComplaints.ForeColor = vbBlack
Forms!FRM_PC_ProductAdmin!txtContactAvailability.ForeColor = vbBlack
Forms!FRM_PC_ProductAdmin!cbo3rdParty.ForeColor = vbBlack
Forms!FRM_PC_ProductAdmin!cboSubProdCode.ForeColor = vbBlack
Forms!FRM_PC_ProductAdmin!cboSubUnitDep.ForeColor = vbBlack
Forms!FRM_PC_ProductAdmin!cboBuitenPCC.ForeColor = vbBlack
Forms!FRM_PC_ProductAdmin!txtValueDating.ForeColor = vbBlack
Forms!FRM_PC_ProductAdmin!txtServiceLevel.ForeColor = vbBlack
Forms!FRM_PC_ProductAdmin!txtTargets.ForeColor = vbBlack
Forms!FRM_PC_ProductAdmin!txtSubProductDefinition.ForeColor = vbBlack
Forms!FRM_PC_ProductAdmin!LstlblRebillingCode.ForeColor = vbBlack
Forms!FRM_PC_ProductAdmin!LstChain.ForeColor = vbBlack
Forms!FRM_PC_ProductAdmin!LstSLA.ForeColor = vbBlack
Forms!FRM_PC_ProductAdmin!LstKPI.ForeColor = vbBlack

'Resetting all control texts

Forms!FRM_PC_ProductAdmin!txtMethodofService.ControlTipText = "No Updates Requested"
Forms!FRM_PC_ProductAdmin!txtProductName.ControlTipText = "No Updates Requested"
Forms!FRM_PC_ProductAdmin!txtGlbProductName.ControlTipText = "No Updates Requested"
Forms!FRM_PC_ProductAdmin!cboServiceUnitDepartment.ControlTipText = "No Updates Requested"
Forms!FRM_PC_ProductAdmin!txtProductCode.ControlTipText = "No Updates Requested"
Forms!FRM_PC_ProductAdmin!txtLOB.ControlTipText = "No Updates Requested"
Forms!FRM_PC_ProductAdmin!txtServiceDefinition.ControlTipText = "No Updates Requested"
Forms!FRM_PC_ProductAdmin!txtSubProductDefinition.ControlTipText = "No Updates Requested"
Forms!FRM_PC_ProductAdmin!txtTermsofDelivery.ControlTipText = "No Updates Requested"
Forms!FRM_PC_ProductAdmin!txtServiceLevel.ControlTipText = "No Updates Requested"
Forms!FRM_PC_ProductAdmin!txtCOT.ControlTipText = "No Updates Requested"
Forms!FRM_PC_ProductAdmin!txtFurtherSpecification.ControlTipText = "No Updates Requested"
Forms!FRM_PC_ProductAdmin!txtQuestionComplaints.ControlTipText = "No Updates Requested"
Forms!FRM_PC_ProductAdmin!txtContactAvailability.ControlTipText = "No Updates Requested"
Forms!FRM_PC_ProductAdmin!txtServiceWinAvailability.ControlTipText = "No Updates Requested"
Forms!FRM_PC_ProductAdmin!txtCostofService.ControlTipText = "No Updates Requested"
Forms!FRM_PC_ProductAdmin!cbo3rdParty.ControlTipText = "No Updates Requested"
Forms!FRM_PC_ProductAdmin!cboSubProdCode.ControlTipText = "No Updates Requested"
Forms!FRM_PC_ProductAdmin!cboSubProdCode.ControlTipText = "No Updates Requested"
Forms!FRM_PC_ProductAdmin!cboSubUnitDep.ControlTipText = "No Updates Requested"
Forms!FRM_PC_ProductAdmin!cboBuitenPCC.ControlTipText = "No Updates Requested"
Forms!FRM_PC_ProductAdmin!txtValueDating.ControlTipText = "No Updates Requested"
Forms!FRM_PC_ProductAdmin!txtServiceLevel.ControlTipText = "No Updates Requested"
Forms!FRM_PC_ProductAdmin!txtTargets.ControlTipText = "No Updates Requested"
Forms!FRM_PC_ProductAdmin!LstlblRebillingCode.ControlTipText = "No Updates Requested"
Forms!FRM_PC_ProductAdmin!LstChain.ControlTipText = "No Updates Requested"
Forms!FRM_PC_ProductAdmin!LstSLA.ControlTipText = "No Updates Requested"
Forms!FRM_PC_ProductAdmin!LstKPI.ControlTipText = "No Updates Requested"

' Calling up all records in the approval table which matches the current
' record on screen

strsql = "SELECT * FROM TBL_Approval WHERE RecID = " & Forms!FRM_PC_ProductAdmin!txtID.value
Set rst = db.OpenRecordset(strsql, dbOpenDynaset)

On Error GoTo ErrorHandler

Countermethodofmeasure = 0
CounterProductName = 0
CounterServiceUnitDepartment = 0
CounterProductCode = 0
CounterActive = 0
CounterServiceDefinition = 0
CounterTermsOfDelivery = 0
CounterServicelevelsKPITargets = 0
CounterCOT = 0
CounterFurtherSpecifications = 0
CounterOperationalQuestionsAndComplaints = 0
CounterContactAvailability = 0
CounterServiceWindowAvailability = 0
CounterCostOfService = 0
CounterLOB = 0
CounterSLA = 0
Counter3rdParty = 0
CounterGlobalProductName = 0
CounterSubProduct = 0
CounterSubUnitDep = 0
CounterExternPCC = 0
CounterValueDating = 0
CounterServiceLevel = 0
CounterTargets = 0
CounterSubProductDefinition = 0

' Checking users group, if they are allowed to edit records

If gvCredGrp = "ProdCatAdmin" Or gvCredGrp = "ProdCatPortfolio" Then
Forms!FRM_PC_ProductAdmin!btnEditProduct.Visible = True
Else
Forms!FRM_PC_ProductAdmin!btnEditProduct.Visible = False
End If

' This is the color of the field it will be if the field is set for approval
' Currently its ABN Green

lngHighlight = RGB(0, 128, 128)


' Updating the form to see if there are any updates waiting to be approved.

If rst.EOF = True Then

Else
Do While Not rst.EOF

If rst("DestCol") <> "Active" Then
varnewval = rst("NewVal")

' Clearing Array
For p = 0 To 2
NewValHlpTxt(p) = ""
Next

e = 0
i = 80
Do While Len(varnewval) > 80
Do While i > 59
If Right(Left(varnewval, i), 1) = " " Then
NewValHlpTxt(e) = Left(varnewval, i)
e = e + 1
varnewval = Right(varnewval, Len(varnewval) - i)
Exit Do
End If
i = i - 1
Loop
Loop
NewValHlpTxt(e) = varnewval
End If

Select Case rst("DestCol")

Case "methodofmeasure"
Countermethodofmeasure = Countermethodofmeasure + 1
Forms!FRM_PC_ProductAdmin!txtMethodofService.BackColor = lngHighlight
Forms!FRM_PC_ProductAdmin!txtMethodofService.ForeColor = vbWhite
If Countermethodofmeasure < 2 Then
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtMethodofService.ControlTipText = "Requested Change:" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtMethodofService.ControlTipText = "Requested Change:" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
Else
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtMethodofService.ControlTipText = "Requested Change(" & Countermethodofmeasure & "):" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtMethodofService.ControlTipText = "Requested Change(" & Countermethodofmeasure & "):" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
End If

Case "ProductName"
CounterProductName = CounterProductName + 1
Forms!FRM_PC_ProductAdmin!txtProductName.BackColor = lngHighlight
Forms!FRM_PC_ProductAdmin!txtProductName.ForeColor = vbWhite
If CounterProductName < 2 Then
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtProductName.ControlTipText = "Requested Change:" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtProductName.ControlTipText = "Requested Change:" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
Else
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtProductName.ControlTipText = "Requested Change(" & CounterProductName & "):" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtProductName.ControlTipText = "Requested Change(" & CounterProductName & "):" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
End If

Case "GlobalProductName"
CounterGlobalProductName = CounterGlobalProductName + 1
Forms!FRM_PC_ProductAdmin!txtGlbProductName.BackColor = lngHighlight
Forms!FRM_PC_ProductAdmin!txtGlbProductName.ForeColor = vbWhite
If CounterProductName < 2 Then
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtGlbProductName.ControlTipText = "Requested Change:" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtGlbProductName.ControlTipText = "Requested Change:" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
Else
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtGlbProductName.ControlTipText = "Requested Change(" & CounterGlobalProductName & "):" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtGlbProductName.ControlTipText = "Requested Change(" & CounterGlobalProductName & "):" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
End If

Case "ServiceUnitDepartment"
CounterServiceUnitDepartment = CounterServiceUnitDepartment + 1
Forms!FRM_PC_ProductAdmin!cboServiceUnitDepartment.BackColor = lngHighlight
Forms!FRM_PC_ProductAdmin!cboServiceUnitDepartment.ForeColor = vbWhite
If CounterServiceUnitDepartment < 2 Then
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!cboServiceUnitDepartment.ControlTipText = "Requested Change:" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!cboServiceUnitDepartment.ControlTipText = "Requested Change:" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
Else
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!cboServiceUnitDepartment.ControlTipText = "Requested Change(" & CounterServiceUnitDepartment & "):" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!cboServiceUnitDepartment.ControlTipText = "Requested Change(" & CounterServiceUnitDepartment & "):" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
End If

Case "ProductCode"
CounterProductCode = CounterProductCode + 1
Forms!FRM_PC_ProductAdmin!txtProductCode.BackColor = lngHighlight
Forms!FRM_PC_ProductAdmin!txtProductCode.ForeColor = vbWhite
If CounterProductCode < 2 Then
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtProductCode.ControlTipText = "Requested Change:" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtProductCode.ControlTipText = "Requested Change:" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
Else
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtProductCode.ControlTipText = "Requested Change(" & CounterProductCode & "):" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtProductCode.ControlTipText = "Requested Change(" & CounterProductCode & "):" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
End If

Case "SLA"

Case "LOB"
CounterLOB = CounterLOB + 1
Forms!FRM_PC_ProductAdmin!txtLOB.BackColor = lngHighlight
Forms!FRM_PC_ProductAdmin!txtLOB.ForeColor = vbWhite
If CounterLOB < 2 Then
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtLOB.ControlTipText = "Requested Change:" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtLOB.ControlTipText = "Requested Change:" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
Else
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtLOB.ControlTipText = "Requested Change(" & CounterLOB & "):" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtLOB.ControlTipText = "Requested Change(" & CounterLOB & "):" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
End If

Case "Active"
CounterActive = CounterActive + 1
Forms!FRM_PC_ProductAdmin!lblReqdeActive.Visible = True

Case "ServiceDefinition"
CounterServiceDefinition = CounterServiceDefinition + 1
Forms!FRM_PC_ProductAdmin!txtServiceDefinition.BackColor = lngHighlight
Forms!FRM_PC_ProductAdmin!txtServiceDefinition.ForeColor = vbWhite
If CounterServiceDefinition < 2 Then
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtServiceDefinition.ControlTipText = "Requested Change:" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtServiceDefinition.ControlTipText = "Requested Change:" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
Else
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtServiceDefinition.ControlTipText = "Requested Change(" & CounterServiceDefinition & "):" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtServiceDefinition.ControlTipText = "Requested Change(" & CounterServiceDefinition & "):" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
End If

Case "SubProductDefinition"
CounterSubProductDefinition = CounterSubProductDefinition + 1
Forms!FRM_PC_ProductAdmin!txtSubProductDefinition.BackColor = lngHighlight
Forms!FRM_PC_ProductAdmin!txtSubProductDefinition.ForeColor = vbWhite
If CounterSubProductDefinition < 2 Then
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtSubProductDefinition.ControlTipText = "Requested Change:" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtSubProductDefinition.ControlTipText = "Requested Change:" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
Else
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtSubProductDefinition.ControlTipText = "Requested Change(" & CounterSubProductDefinition & "):" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtSubProductDefinition.ControlTipText = "Requested Change(" & CounterSubProductDefinition & "):" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
End If

Case "Termsofdelivery"
CounterTermsOfDelivery = CounterTermsOfDelivery + 1
Forms!FRM_PC_ProductAdmin!txtTermsofDelivery.BackColor = lngHighlight
Forms!FRM_PC_ProductAdmin!txtTermsofDelivery.ForeColor = vbWhite
If CounterTermsOfDelivery < 2 Then
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtTermsofDelivery.ControlTipText = "Requested Change:" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtTermsofDelivery.ControlTipText = "Requested Change:" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
Else
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtTermsofDelivery.ControlTipText = "Requested Change(" & CounterTermsOfDelivery & "):" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtTermsofDelivery.ControlTipText = "Requested Change(" & CounterTermsOfDelivery & "):" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
End If

Case "ServicelevelsKPITargets"
CounterServicelevelsKPITargets = CounterServicelevelsKPITargets + 1
Forms!FRM_PC_ProductAdmin!txtServiceLevel.BackColor = lngHighlight
Forms!FRM_PC_ProductAdmin!txtServiceLevel.ForeColor = vbWhite
If CounterServicelevelsKPITargets < 2 Then
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtServiceLevel.ControlTipText = "Requested Change:" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtServiceLevel.ControlTipText = "Requested Change:" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
Else
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtServiceLevel.ControlTipText = "Requested Change(" & CounterServicelevelsKPITargets & "):" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtServiceLevel.ControlTipText = "Requested Change(" & CounterServicelevelsKPITargets & "):" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
End If

Case "COT"
CounterCOT = CounterCOT + 1
Forms!FRM_PC_ProductAdmin!txtCOT.BackColor = lngHighlight
Forms!FRM_PC_ProductAdmin!txtCOT.ForeColor = vbWhite
If CounterCOT < 2 Then
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtCOT.ControlTipText = "Requested Change:" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtCOT.ControlTipText = "Requested Change:" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
Else
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtCOT.ControlTipText = "Requested Change(" & CounterCOT & "):" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtCOT.ControlTipText = "Requested Change(" & CounterCOT & "):" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
End If

Case "FurtherSpecifications"
CounterFurtherSpecifications = CounterFurtherSpecifications + 1
Forms!FRM_PC_ProductAdmin!txtFurtherSpecification.BackColor = lngHighlight
Forms!FRM_PC_ProductAdmin!txtFurtherSpecification.ForeColor = vbWhite
If CounterFurtherSpecifications < 2 Then
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtFurtherSpecification.ControlTipText = "Requested Change:" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtFurtherSpecification.ControlTipText = "Requested Change:" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
Else
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtFurtherSpecification.ControlTipText = "Requested Change(" & CounterFurtherSpecifications & "):" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtFurtherSpecification.ControlTipText = "Requested Change(" & CounterFurtherSpecifications & "):" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
End If

Case "Operationalquestionsandcomplaints"
CounterOperationalQuestionsAndComplaints = CounterOperationalQuestionsAndComplaints + 1
Forms!FRM_PC_ProductAdmin!txtQuestionComplaints.BackColor = lngHighlight
Forms!FRM_PC_ProductAdmin!txtQuestionComplaints.ForeColor = vbWhite
If CounterOperationalQuestionsAndComplaints < 2 Then
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtQuestionComplaints.ControlTipText = "Requested Change:" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtQuestionComplaints.ControlTipText = "Requested Change:" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
Else
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtQuestionComplaints.ControlTipText = "Requested Change(" & CounterOperationalQuestionsAndComplaints & "):" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtQuestionComplaints.ControlTipText = "Requested Change(" & CounterOperationalQuestionsAndComplaints & "):" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
End If

Case "ContactAndAvailability"
CounterContactAvailability = CounterContactAvailability + 1
Forms!FRM_PC_ProductAdmin!txtContactAvailability.BackColor = lngHighlight
Forms!FRM_PC_ProductAdmin!txtContactAvailability.ForeColor = vbWhite
If CounterContactAvailability < 2 Then
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtContactAvailability.ControlTipText = "Requested Change:" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtContactAvailability.ControlTipText = "Requested Change:" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
Else
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtContactAvailability.ControlTipText = "Requested Change(" & CounterContactAvailability & "):" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtContactAvailability.ControlTipText = "Requested Change(" & CounterContactAvailability & "):" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
End If



Case "ServiceWindowAvailability"
CounterServiceWindowAvailability = CounterServiceWindowAvailability + 1
Forms!FRM_PC_ProductAdmin!txtServiceWinAvailability.BackColor = lngHighlight
Forms!FRM_PC_ProductAdmin!txtServiceWinAvailability.ForeColor = vbWhite
If CounterServiceWindowAvailability < 2 Then
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtServiceWinAvailability.ControlTipText = "Requested Change:" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtServiceWinAvailability.ControlTipText = "Requested Change:" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
Else
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtServiceWinAvailability.ControlTipText = "Requested Change(" & CounterServiceWindowAvailability & "):" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtServiceWinAvailability.ControlTipText = "Requested Change(" & CounterServiceWindowAvailability & "):" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
End If

Case "CostOfService"
CounterCostOfService = CounterCostOfService + 1
Forms!FRM_PC_ProductAdmin!txtCostofService.BackColor = lngHighlight
Forms!FRM_PC_ProductAdmin!txtCostofService.ForeColor = vbWhite
If CounterCostOfService < 2 Then
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtCostofService.ControlTipText = "Requested Change:" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtCostofService.ControlTipText = "Requested Change:" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
Else
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtCostofService.ControlTipText = "Requested Change(" & CounterCostOfService & "):" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtCostofService.ControlTipText = "Requested Change(" & CounterCostOfService & "):" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
End If

Case "3rdParty"
Counter3rdParty = Counter3rdParty + 1
Forms!FRM_PC_ProductAdmin!cbo3rdParty.BackColor = lngHighlight
Forms!FRM_PC_ProductAdmin!cbo3rdParty.ForeColor = vbWhite
If Counter3rdParty < 2 Then
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!cbo3rdParty.ControlTipText = "Requested Change:" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!cbo3rdParty.ControlTipText = "Requested Change:" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
Else
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!cbo3rdParty.ControlTipText = "Requested Change(" & Counter3rdParty & "):" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!cbo3rdParty.ControlTipText = "Requested Change(" & Counter3rdParty & "):" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
End If

Case "SubProduct"
CounterSubProduct = CounterSubProduct + 1
Forms!FRM_PC_ProductAdmin!cboSubProdCode.BackColor = lngHighlight
Forms!FRM_PC_ProductAdmin!cboSubProdCode.ForeColor = vbWhite
If CounterSubProduct < 2 Then
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!cboSubProdCode.ControlTipText = "Requested Change:" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!cboSubProdCode.ControlTipText = "Requested Change:" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
Else
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!cboSubProdCode.ControlTipText = "Requested Change(" & CounterSubProduct & "):" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!cboSubProdCode.ControlTipText = "Requested Change(" & CounterSubProduct & "):" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
End If

Case "SubServiceUnitDepartment"
CounterSubUnitDep = CounterSubUnitDep + 1
Forms!FRM_PC_ProductAdmin!cboSubUnitDep.BackColor = lngHighlight
Forms!FRM_PC_ProductAdmin!cboSubUnitDep.ForeColor = vbWhite
If CounterSubUnitDep < 2 Then
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!cboSubUnitDep.ControlTipText = "Requested Change:" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!cboSubUnitDep.ControlTipText = "Requested Change:" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
Else
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!cboSubUnitDep.ControlTipText = "Requested Change(" & CounterSubUnitDep & "):" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!cboSubUnitDep.ControlTipText = "Requested Change(" & CounterSubUnitDep & "):" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
End If

Case "ExternPCC"
CounterExternPCC = CounterExternPCC + 1
Forms!FRM_PC_ProductAdmin!cboBuitenPCC.BackColor = lngHighlight
Forms!FRM_PC_ProductAdmin!cboBuitenPCC.ForeColor = vbWhite
If CounterExternPCC < 2 Then
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!cboBuitenPCC.ControlTipText = "Requested Change:" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!cboBuitenPCC.ControlTipText = "Requested Change:" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
Else
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!cboBuitenPCC.ControlTipText = "Requested Change(" & CounterExternPCC & "):" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!cboBuitenPCC.ControlTipText = "Requested Change(" & CounterExternPCC & "):" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
End If

Case "ValueDating"
CounterValueDating = CounterValueDating + 1
Forms!FRM_PC_ProductAdmin!txtValueDating.BackColor = lngHighlight
Forms!FRM_PC_ProductAdmin!txtValueDating.ForeColor = vbWhite
If CounterValueDating < 2 Then
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtValueDating.ControlTipText = "Requested Change:" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtValueDating.ControlTipText = "Requested Change:" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
Else
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtValueDating.ControlTipText = "Requested Change(" & CounterValueDating & "):" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtValueDating.ControlTipText = "Requested Change(" & CounterValueDating & "):" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
End If

Case "ServiceLevel"
CounterServiceLevel = CounterServiceLevel + 1
Forms!FRM_PC_ProductAdmin!txtServiceLevel.BackColor = lngHighlight
Forms!FRM_PC_ProductAdmin!txtServiceLevel.ForeColor = vbWhite
If CounterServiceLevel < 2 Then
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtServiceLevel.ControlTipText = "Requested Change:" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtServiceLevel.ControlTipText = "Requested Change:" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
Else
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtServiceLevel.ControlTipText = "Requested Change(" & CounterServiceLevel & "):" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtServiceLevel.ControlTipText = "Requested Change(" & CounterServiceLevel & "):" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
End If

Case "Targets"
CounterTargets = CounterTargets + 1
Forms!FRM_PC_ProductAdmin!txtTargets.BackColor = lngHighlight
Forms!FRM_PC_ProductAdmin!txtTargets.ForeColor = vbWhite
If CounterTargets < 2 Then
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtTargets.ControlTipText = "Requested Change:" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtTargets.ControlTipText = "Requested Change:" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
Else
If NewValHlpTxt(0) = "" Then
Forms!FRM_PC_ProductAdmin!txtTargets.ControlTipText = "Requested Change(" & CounterTargets & "):" & Chr(13) & "System Message - All text has been request to be Removed"
Else
Forms!FRM_PC_ProductAdmin!txtTargets.ControlTipText = "Requested Change(" & CounterTargets & "):" & Chr(13) & NewValHlpTxt(0) & Chr(13) & NewValHlpTxt(1) & Chr(13) & NewValHlpTxt(2)
End If
End If


Case "Rebilling"
Forms!FRM_PC_ProductAdmin!LstlblRebillingCode.BackColor = lngHighlight
Forms!FRM_PC_ProductAdmin!LstlblRebillingCode.ForeColor = vbWhite

If Left(rst("OldVal"), 21) = "Insert Rebilling Code" Then
lstboxAddRebil = lstboxAddRebil & Mid(rst("OldVal"), 22, Len(rst("OldVal")) - 21) & Chr(13)
End If

If Left(rst("OldVal"), 25) = "Removal of Rebilling Code" Then
lstboxDelRebil = lstboxDelRebil & Mid(rst("OldVal"), 26, Len(rst("OldVal")) - 25) & Chr(13)
End If

Forms!FRM_PC_ProductAdmin!LstlblRebillingCode.ControlTipText = "Requested Rebilling code to be Delete:" & Chr(13) & lstboxDelRebil & Chr(13) & "Requested Rebilling code to be Added:" & Chr(13) & lstboxAddRebil

Case "Chain"
Forms!FRM_PC_ProductAdmin!LstChain.BackColor = lngHighlight
Forms!FRM_PC_ProductAdmin!LstChain.ForeColor = vbWhite

If Left(rst("OldVal"), 12) = "Insert Chain" Then
lstboxAddChain = lstboxAddChain & Mid(rst("OldVal"), 13, Len(rst("OldVal")) - 12) & Chr(13)
End If

If Left(rst("OldVal"), 16) = "Removal of Chain" Then
lstboxDelChain = lstboxDelChain & Mid(rst("OldVal"), 18, Len(rst("OldVal")) - 17) & Chr(13)
End If

Forms!FRM_PC_ProductAdmin!LstChain.ControlTipText = Left("Requested Chain(s) to be Delete:" & Chr(13) & lstboxDelChain & Chr(13) & "Requested Chain(s) to be Added:" & Chr(13) & lstboxAddChain, 10)

Case "SLA Record"
Forms!FRM_PC_ProductAdmin!LstSLA.BackColor = lngHighlight
Forms!FRM_PC_ProductAdmin!LstSLA.ForeColor = vbWhite

If Left(rst("OldVal"), 10) = "Insert SLA" Then
lstboxAddSLARec = lstboxAddSLARec & Right(rst("OldVal"), Len(rst("OldVal")) - 9) & Chr(13)
End If

If Left(rst("OldVal"), 10) = "Remove SLA" Then
lstboxDelSLARec = lstboxDelSLARec & Right(rst("OldVal"), Len(rst("OldVal")) - 9) & Chr(13)
End If

Forms!FRM_PC_ProductAdmin!LstSLA.ControlTipText = "Requested SLA record(s) to be Delete:" & Chr(13) & lstboxDelSLARec & Chr(13) & "Requested SLA Record(s) to be Added:" & Chr(13) & lstboxAddSLARec

Case "KPI Record"
Forms!FRM_PC_ProductAdmin!LstKPI.BackColor = lngHighlight
Forms!FRM_PC_ProductAdmin!LstKPI.ForeColor = vbWhite

If Left(rst("OldVal"), 10) = "Insert KPI" Then
lstboxAddKPIRec = lstboxAddKPIRec & Right(rst("OldVal"), Len(rst("OldVal")) - 11) & Chr(13)
End If

If Left(rst("OldVal"), 10) = "Remove KPI" Then
lstboxDelKPIRec = lstboxDelKPIRec & Right(rst("OldVal"), Len(rst("OldVal")) - 11) & Chr(13)
End If

Forms!FRM_PC_ProductAdmin!LstKPI.ControlTipText = "Requested KPI record(s) to be Delete:" & Chr(13) & lstboxDelKPIRec & Chr(13) & "Requested KPI Record(s) to be Added:" & Chr(13) & lstboxAddKPIRec

End Select

rst.MoveNext
Loop
End If
MsgBox Forms!FRM_PC_ProductAdmin!LstKPI.ControlTipText
' closing off

db.Close
Set db = Nothing
ErrorHandler:
Select Case Err.Number
Case 0
MsgBox "Error 0"
Case 2176
MsgBox Err.Number & Chr(16) & Err.Description
Case Else
Call TriActisErrMsg
End Select
 
How are ya 44nato44 . . .

Is there any other control on top of the listbox? It only takes the smallest piece of an adjacent control touching the listbox to force the listbox to the rear. In this condition the listbox can't receive mouse movement and must be selected first ... instead of hovering.

In any case,
[ol][li]Open the form in design view.[/li]
[li]Select the listbox, then [blue]Menubar[/blue] - [blue]Format[/blue] - [blue]Bring To Front[/blue].[/li]
[li]Save, close then reopen the form.[/li]
[li]Perform your testing ...[/li][/ol]
[blue]Your Thoughts? . . .[/blue]

See Ya! . . . . . .

Be sure to see faq219-2884 [blue]Worthy Reading![/blue] [thumbsup2]
Also faq181-2886 [blue]Worthy Reading![/blue] [thumbsup2]
 
Perfect.. thanks a lot it worked perfectly
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top