Ask Experts Questions for FREE Help !
Ask
    mcleyn's Avatar
    mcleyn Posts: 48, Reputation: 1
    Junior Member
     
    #1

    Jun 2, 2009, 06:27 AM
    Undefined Function
    I have a form called, frmDetail, which is one of my main forms.
    Inside the frmDetail I have a drop down box with a list of different choices.
    All of the choices inside the combo box are different forms.
    Once the user clicks a form from the drop down box it is taken from a query, called "qryReport" and then opened up.
    For example I have a form in the drop down box called "frmCALetter" Once the user clicks this the Letter appears.

    Whenever I try to open any of the forms or the qryReport I get the error:
    "Undefined Function 'GetLongProjectType' in expression".

    Now I have copied the qryReport and frmDetail from a previous database and they have worked fine up until when I am trying to open these forms in the drop down box.

    The GetLongProjectType comes from my original database in the qryReport, SQL View. Shown here:

    SELECT GetLongProjectType([ProjectType]) AS LongProjectType, GetRegionalProgramOfficer([Province]) AS RegionalProgramOfficer, GetHQProgramOfficer([Province]) AS HQProgramOfficer, GetRegionalOfficeAddress([Province]) AS RegionalOfficeAddress, GetRegionalOfficeTelephone([Province]) AS RegionalOfficeTelephone, tblMain.ProjectCode, tblMain.Province, tblMain.ProjectType, tblMain.ProjectNumber, tblMain.OrganizationName, tblMain.ProjectTitle, tblMain.EventDate, tblMain.ProjectDuration, tblMain.DateReceived, tblMain.ContactFirstName, tblMain.ContactLastName, tblMain.ContactTitle, tblMain.ContactAddressLine1, tblMain.ContactAddressLine2, tblMain.ContactTelephone, tblMain.ContactFax, tblMain.ContactEmail, tblMain.Website, tblMain.SigningSuffix, tblMain.SigningFirstName, tblMain.SigningLastName, tblMain.SigningTitle, tblMain.SigningTelephone, tblMain.SigningEmail, tblMain.TaxNumber, tblMain.ProjectLocation, tblMain.ProjectDescription, tblMain.DateProjectApproved, tblMain.TotalCostOfProject, tblMain.AmountRequested, tblMain.AmountApproved, tblMain.AmountFromPartners, tblMain.LetterOfApprovalNumber, tblMain.DateCASignedByED, tblMain.DateCASignedByProp, tblMain.CAStart, tblMain.CAEnd, tblMain.Status, tblMain.StatusComment, tblMain.SigningAddressLine1, tblMain.SigningAddressLine2, tblMain.SigningTelephone, tblMain.SigningFax, tblMain.SigningEmail
    FROM tblMain;

    However I have copied the same SQL here into my new qryReport in my new database. And I am still getting the same problem.
    Do you have any idea what the problem is or anything I can do?
    ScottGem's Avatar
    ScottGem Posts: 64,966, Reputation: 6056
    Computer Expert and Renaissance Man
     
    #2

    Jun 2, 2009, 06:42 AM

    Your GET... functions are user defined functions. They are VBA code that was setup in the previous database. You have to copy the module that contains those functions as well.
    mcleyn's Avatar
    mcleyn Posts: 48, Reputation: 1
    Junior Member
     
    #3

    Jun 2, 2009, 06:55 AM
    Quote Originally Posted by ScottGem View Post
    Your GET... functions are user defined functions. They are VBA code that was setup in the previous database. You have to copy the module that contains those functions as well.
    OK thank you very much. Could you explaing how I copy the module so the query will work?
    mcleyn's Avatar
    mcleyn Posts: 48, Reputation: 1
    Junior Member
     
    #4

    Jun 2, 2009, 07:01 AM
    Quote Originally Posted by ScottGem View Post
    Your GET... functions are user defined functions. They are VBA code that was setup in the previous database. You have to copy the module that contains those functions as well.
    My apologies for the quote asking you how to copy the module, I have figured it out. Thank you very much for your help indeed.

Not your question? Ask your question View similar questions

 

Question Tools Search this Question
Search this Question:

Advanced Search

Add your answer here.


Check out some similar questions!

No why intercept, slope undefined [ 3 Answers ]

I'm having trouble helping someone with there homework queation: find the equation of the line that has no y intercept, has an x intercept of 4, and who's slope is undefined y+mx+b since b is y intercept and there is none that is 0 and disappears so next I used the points (4,0) to plug into...

TypeError: browser is undefined [ 1 Answers ]

Hi I get this erra when I'm on fire fox it come s on evry time I try to access a site does anyone know how to fix this thanks TypeError: browser is undefined

Undefined slope [ 2 Answers ]

If a line has an undefined slope, what can you say about the horizontal coordinates of each of the points on the line?


View more questions Search