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 derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Error Message about referncing in VB Library??

Status
Not open for further replies.

romij29

Technical User
Nov 23, 2004
49
GB
Hello ALL,
Hope you'v all had a good day doing all that you do.
Need a little assistance with this problem
Just written a code in VBA and upon clicking the user form I created for the program to run I get a compilation error in the fff code:

Cannot jump to "txtYear" because it is in the linbrary "F3Dynamic" which is not currently referenced.

What doees this mean??F3Dynamic.Here is the bit of code used for my Run button on the user form.

BTW, txtYear is a txtbox labelled "Year" where the year needed for the macro to run is updated

Public Sub cmd_Update_Click()
Dim i As Integer, intRow As Integer

Workbooks("Squares_Control.xls").Sheets("Control").Range("I2:I95").Clear
intRow = 2
i = 0

'Inserts the name of a selected template(s) in column J
'for the macro to refer to
Do While Range("C" & i + 2) = "" = False
If lstCinemas.Selected(i) = True Then
Range("I" & intRow) = Range("B" & i + 2)
intRow = intRow + 1
End If
i = i + 1
Loop

'tests which tick boxes have been selected and calls the appropriate
'procedure to start copying the data
If Squares.Value = True Then
Squares_Macro (txtYear)------'This is the bit that flags up the error message above
Save

Else

MsgBox ("Please select at least one option"), vbCritical
End If
Squares_Update.Hide
End Sub

It also tells me that I have a compilation error where the word Squares_Macro is unambiguous.
Thanks,

Regards,

romij29
 
Try to use Me.txtYear

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ222-2244
 
Hello PHV,

Thanks for your reply..However tried Me.txtYear and nothing soo far...Still telling me its unambiguous with .txtYear highlighted
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top