CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3
  1. #1
    Join Date
    Nov 2001
    Location
    Singapore.
    Posts
    7

    Crystal Report Parameters

    Hi,

    I have a problem with the parameters passing.

    Suppose you have a report that contains three sub reports. These sub reorts are linked to the main report columns. But the main report requires two string parameters to be passed.

    How can I pass parameter values to the report. Currently I am using the Report.ReplaceSelectionFormula property to do but it is not the correct way to do things :-)

    So Can you guide me on how to do it ?

    Thanks,
    Krogoth!


    FSM

  2. #2
    Join Date
    Sep 2001
    Posts
    49

    Re: Crystal Report Parameters

    Not sure exactly what you are saying but to pass a parameter to Crytal Reports from VB, you use the ParameterFields property

    Dim objReport As CRPEAuto.Report
    ojReport.ParameterFields("ParameterName").SetCurrentValue (Value)

    Of course, the ParameterName is the name of the parameter you named in the report.



  3. #3
    Join Date
    Nov 2001
    Posts
    4

    Re: Crystal Report Parameters

    I am using Visual Basic 6 and Crystal Reports 6.
    The Crystal 6 Report Engine is added in the project reference area.
    When I try to do the following:
    dim objReport as CRPEAuto.Report

    ...it does not give me the "CRPEAuto" option. All I see are "CR" options.
    Does this code utilize a later Crystal Report engine?

    Thanks to anyone who may answer. It is appreciated!


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured