K
khanner
Never used to get this error msg till now. I suck t VBA any help PLEASE!!!
Public Function ArchiveResults()
Dim historical As DAO.Recordset
Set historical = CurrentDb.OpenRecordset("Tbl_HistoricalResults",
dbOpenDynaset)
Dim results As DAO.Recordset
Set results = CurrentDb.OpenRecordset("Tbl_Results", dbOpenDynaset)
historical.AddNew
historical("Run_Time").Value = results("Run_Time").Value
historical("CUSIP").Value = results("CUSIP").Value
historical("Group_Deal_Collateral").Value =
results("Group_Deal_Collateral").Value
historical("UPSIDE_FACTOR").Value = results("UPSIDE_FACTOR").Value
historical("DOWNSIDE_FACTOR").Value = results("DOWNSIDE_FACTOR").Value
historical("WA_Curr_LTV").Value = results("WA_Curr_LTV").Value
historical("WA_Trough_LTV").Value = results("WA_Trough_LTV").Value
historical("WA_Final_LTV").Value = results("WA_Final_LTV").Value
historical("WA_Peak2Trough").Value = results("WA_Peak2Trough").Value
historical("WA_Current2Trough").Value = results("WA_Current2Trough").Value
'Current loans
historical("NumLoans").Value = results("NumLoans").Value
historical("ValueLoans").Value = results("ValueLoans").Value
historical("CollatValue").Value = results("CollatValue").Value
historical("PctofPool").Value = results("PctofPool").Value
historical("AvgLTV").Value = results("AvgLTV").Value
historical("AvgSize").Value = results("AvgSize").Value
historical("ImplSev").Value = results("ImplSev").Value
'Delinquent loans
historical("DQNumLoans").Value = results("DQNumLoans").Value
historical("DQValueLoans").Value = results("DQValueLoans").Value
historical("DQCollatValue").Value = results("DQCollatValue").Value
historical("DQPctofPool").Value = results("DQPctofPool").Value
historical("DQAvgLTV").Value = results("DQAvgLTV").Value
historical("DQAvgSize").Value = results("DQAvgSize").Value
historical("DQImplSev").Value = results("DQImplSev").Value
historical("EstimatedLoss").Value = results("EstimatedLoss").Value
historical.Update
End Function
Public Function ArchiveResults()
Dim historical As DAO.Recordset
Set historical = CurrentDb.OpenRecordset("Tbl_HistoricalResults",
dbOpenDynaset)
Dim results As DAO.Recordset
Set results = CurrentDb.OpenRecordset("Tbl_Results", dbOpenDynaset)
historical.AddNew
historical("Run_Time").Value = results("Run_Time").Value
historical("CUSIP").Value = results("CUSIP").Value
historical("Group_Deal_Collateral").Value =
results("Group_Deal_Collateral").Value
historical("UPSIDE_FACTOR").Value = results("UPSIDE_FACTOR").Value
historical("DOWNSIDE_FACTOR").Value = results("DOWNSIDE_FACTOR").Value
historical("WA_Curr_LTV").Value = results("WA_Curr_LTV").Value
historical("WA_Trough_LTV").Value = results("WA_Trough_LTV").Value
historical("WA_Final_LTV").Value = results("WA_Final_LTV").Value
historical("WA_Peak2Trough").Value = results("WA_Peak2Trough").Value
historical("WA_Current2Trough").Value = results("WA_Current2Trough").Value
'Current loans
historical("NumLoans").Value = results("NumLoans").Value
historical("ValueLoans").Value = results("ValueLoans").Value
historical("CollatValue").Value = results("CollatValue").Value
historical("PctofPool").Value = results("PctofPool").Value
historical("AvgLTV").Value = results("AvgLTV").Value
historical("AvgSize").Value = results("AvgSize").Value
historical("ImplSev").Value = results("ImplSev").Value
'Delinquent loans
historical("DQNumLoans").Value = results("DQNumLoans").Value
historical("DQValueLoans").Value = results("DQValueLoans").Value
historical("DQCollatValue").Value = results("DQCollatValue").Value
historical("DQPctofPool").Value = results("DQPctofPool").Value
historical("DQAvgLTV").Value = results("DQAvgLTV").Value
historical("DQAvgSize").Value = results("DQAvgSize").Value
historical("DQImplSev").Value = results("DQImplSev").Value
historical("EstimatedLoss").Value = results("EstimatedLoss").Value
historical.Update
End Function