>> >>Thisform.lblTesting.Caption = 'ONE' >>ThisForm.lblTesting.Refresh >>Thisform.lblWidth.Caption = ALLTRIM(STR(Thisform.lblTesting.Width)) >> >>Thisform.lblTesting.Caption = 'ONE TWO' >>ThisForm.lblTesting.Refresh >>Thisform.lblWidth.Caption = ALLTRIM(STR(Thisform.lblTesting.Width)) >> >>Thisform.lblTesting.Caption = 'ONE TWO THREE' >>ThisForm.lblTesting.Refresh >>Thisform.lblWidth.Caption = ALLTRIM(STR(Thisform.lblTesting.Width)) >> >>Thisform.lblTesting.Caption = 'ONE TWO THREE FOUR' >>ThisForm.lblTesting.Refresh >>Thisform.lblWidth.Caption = ALLTRIM(STR(Thisform.lblTesting.Width)) >> >>Thisform.lblTesting.Caption = 'ONE TWO THREE FOUR FIVE' >>ThisForm.lblTesting.Refresh >>Thisform.lblWidth.Caption = ALLTRIM(STR(Thisform.lblTesting.Width)) >>>>
IF Thisform.m_seek(ALLTRIM(tcRx) + ALLTRIM(tcRefill) + "1","rx_claim","fullerx",1) && seeking to see if there is a TP claim record Thisform.lblRx.Caption = ALLTRIM(tcRx) + "-" + ALLTRIM(tcRefill) + translatewrd(" Previously billed to") Thisform.m_seek(rx_claim.plan_id,"plan_search","plan_id",1) && seeking in third_party_plans table to get TP name Thisform.lblIns1.Caption = "Primary: " + ALLTRIM(plan_search.plan_name) lnFirstTPP = rx_claim.plan_id Thisform.FontName = Thisform.lblIns1.FontName Thisform.FontSize = Thisform.lblIns1.FontSize lnWidth = Thisform.TextWidth(Thisform.lblIns1.Caption) + 20 *TMT 12/18/2015 Case# 110829 - Display the associated cardholder_id_no along with the third Party Plan IF SEEK(PADL(rx_claim.patient_id,5,"0")+PADL(rx_claim.plan_id,4,"0")+PADL(rx_claim.tp_order,2,"0"),"patient_third_party","plan_patnt") Thisform.lblPrimaryCardholderID.Caption = " / " + ALLTRIM(patient_third_party.cardholder_id_no) Thisform.lblPrimaryCardholderID.Left = Thisform.lblIns1.Left + lnWidth ENDIF *-- now check to see if there is another TPP for this refill IF Thisform.m_seek(ALLTRIM(tcRx) + ALLTRIM(tcRefill) + "2","rx_claim","fullerx",1) && seeking to see if there is a TP claim record Thisform.m_seek(rx_claim.plan_id,"plan_search","plan_id",1) && seeking in third_party_plans table to get TP name Thisform.lblIns2.Caption = "Secondary: " + ALLTRIM(plan_search.plan_name) lnSecondTPP = rx_claim.plan_id Thisform.FontName = Thisform.lblIns2.FontName Thisform.FontSize = Thisform.lblIns2.FontSize lnWidth = Thisform.TextWidth(Thisform.lblIns2.Caption) + 20 *TMT 12/18/2015 Case# 110829 - Display the associated cardholder_id_no along with the third Party Plan IF SEEK(PADL(rx_claim.patient_id,5,"0")+PADL(rx_claim.plan_id,4,"0")+PADL(rx_claim.tp_order,2,"0"),"patient_third_party","plan_patnt") Thisform.lblSecondaryCardholderID.Caption = " / " + ALLTRIM(patient_third_party.cardholder_id_no) Thisform.lblSecondaryCardholderID.Left = Thisform.lblIns2.Left + lnWidth ENDIF ELSE Thisform.lblIns2.Caption = "" Thisform.lblSecondaryCardholderID.Caption = '' ENDIFSo, I had to make sure the Forms text and size were the same as the text that I wanted to get the width for. Once I had the width, I was home free.