I have several Subs (13 in total) in a module that are all working individually.
The way they are designed to work is in sequential order.
Here is an example: Sub 1 do something, Sub 2 other thing…Sub 13 display final result
My issue is…Let’s say I change some value in sub 4, Now I have to click through 5 to 13 to get the intended result. So, Now that everything is working, to make life simpler I am creating a MASTER button that will just run all the subs.
Below is a sample of one of my working sub and the master-sub (error-91)
EXACT ERROR MESSAGE: [BASIC runtime error.
‘91’
Object variable not set]
Sub Calculate_ALL_Entries
DownPay_In_Percent
End Sub
REM…1. CALCULATE THE DOWNPAYMENT PERCENTAGE
Sub DownPay_In_Percent(oEvent as Object)
dim oForm as Object
dim oSubForm as Object
dim tempP_SalesPrice as double
dim tempDownPay as double
dim tempDownPay_P as double
oForm = oEvent.Source.Model.Parent
REM...// oForm = ThisComponent.Drawpage.Forms.getByName("subfrm_PropertyCal")
tempP_SalesPrice = oForm.getByName("txtP_SalesPrice").currentvalue
tempDownPay = oForm.getByName("txtCal_DownPay").currentvalue
tempDownPay_P = (tempDownPay / tempP_SalesPrice) * 100
oForm.getByName("txtCal_DownPay_P").text = tempDownPay_P
oForm.Columns.GetByName( "Cal_DownPay_P" ).updatedouble(tempDownPay_P,3) 'Use 1 to 17 here '
REM...// MsgBox("Down payment % is "& tempDownPay_P)
End Sub