Hi - I'm getting the dreaded error 2448 "You can't assign a value to this object". (Have reviewed the forums but can't find an applicable solution.)
This occurrs when I try and asign a value to a control in the parent form of the current subform:
Private Sub SetForecastWarning()
If DSum("useForecast", "Phase", "projID=[Forms]![Project]![projID]") = -1 Then
Me.Parent![ForecastGen] = -1
End If
End Sub
I've also tried [Forms]![Project]![ForecastGen] = -1
Any ideas why I can't assign a value to the field "ForecastGen" in this manner?
Note:
In another similar thread, Bob Larson writes: You can't set a value for a bound text box until the LOAD event. The Open event is too early as the recordset has not yet been loaded.
This sub is run from the "Form_Current" event, and occurs when I try and open the parent form. Could this be the problem? If so, can anyone suggest a workaround?
Many thanks.
This occurrs when I try and asign a value to a control in the parent form of the current subform:
Private Sub SetForecastWarning()
If DSum("useForecast", "Phase", "projID=[Forms]![Project]![projID]") = -1 Then
Me.Parent![ForecastGen] = -1
End If
End Sub
I've also tried [Forms]![Project]![ForecastGen] = -1
Any ideas why I can't assign a value to the field "ForecastGen" in this manner?
Note:
In another similar thread, Bob Larson writes: You can't set a value for a bound text box until the LOAD event. The Open event is too early as the recordset has not yet been loaded.
This sub is run from the "Form_Current" event, and occurs when I try and open the parent form. Could this be the problem? If so, can anyone suggest a workaround?
Many thanks.
Last edited: