• stored parameter

    Author
    Topic
    #475727

    Am using Access db with VB 6 and Crystal Reports. CR9 does not play nice with OS 7 64bit, all reports cause the program to crash. And when using CR XI, the newer version of the report writer, in three of the reports on name tags, this is the error msg ‘Can not find QE property’.

    The form and report use a Union All Select query.

    Code:
    SELECT FirstName, LastName, MaidenName, ClassYear, ClassPhoto, 
         ClassYear as SortYear, Lastname AS SortName, 1 AS SortOrder
    FROM Members
    WHERE NumAttend>0 
    UNION ALL SELECT Spouse, LastName, Null, Null, Null, Classyear, Lastname, 2
    FROM Members 
    WHERE NumAttend>1
    ORDER BY SortYear, SortName, SortOrder

    If the code is commented in the form and the report, the name tags print without photos.

    This code in either the form

    Code:
    Private Sub crSection_Format(ByVal pFormattingInfo As Object)
        On Error GoTo ErrHandle
    
        Set crSection.ReportObjects("Classmate").FormattedPicture = _
            LoadPicture(Report.Sections("DetailSection3").ReportObjects("PicFile").Value)
    End Sub 

    or in the report

    Code:
    Private Sub DetailSection1_Format(ByVal pFormattingInfo As Object)
      Set crNameTagsAdhesive.Classmate.FormattedPicture = _
        LoadPicture(crNameTagsAdhesive.PicFile.Value)
    End Sub
    

    creates the error.

    Thought a stored procedure might work but my understanding is the procedure is entered into the design view in Access which does not show up when using a Union All Select parameter.

    I’m stumped. Any ideas would be great.

    Viewing 0 reply threads
    Author
    Replies
    • #1273901

      Can you clarify a few things please? What is OS 7 64-bit? Is it Windows 7 64-bit? Also, how are the photos stored? The SELECT statement suggests it is stored in an Access table, but the more usual solution is to store the file name and path in a text field and dynamically link to the photo that way. Unfortunately, I’m not familiar with Crystal Reports – I’ve never found a reporting need that couldn’t be handled with the Access reports capability. Finally, I don’t believe a stored procedure would help you – for one thing they only are useful if your data is being stored in SQL Server. If I were faced with your situation, I would end up redesigning the forms and reports in Access and not use VB6 or Crystal, but I realize that may not be an option. Hopefully someone with Crystal experience can offer some suggestions.

      • #1273918

        The Operating System is indeed Windows 7 64-bit. The photos are placed in a directory and the path is stored in an Access database.

        Your suggestion to redesign is not an option. but thanx for your input.

    Viewing 0 reply threads
    Reply To: stored parameter

    You can use BBCodes to format your content.
    Your account can't use all available BBCodes, they will be stripped before saving.

    Your information: