想在winform中實現點擊報表A中的某個字段,將字段的值傳給另外一個報表B,并顯示新的報表b,請各位大蝦米指點指點下。

解决方案 »

  1.   

    This can be accomplished through the use of the hyperlink feature in the Crystal Reports Designer along with a parameter field:
    1. Create a second report with a parameter field for the customer name and insert this parameter into a selection formula. For example:
    {table.customerNames} = {?MyCustomer}
    2. In the main report, right click on the "customerNames" field select "Format Field".
    3. On the "Hyperlink" tab, check on the "A website on the Internet" option and in the Hyperlink Information box, click on the "X+2" button and type:
    "HTTP://<serverName>/virtualDirectory/subreportName.rpt?prompt0="+{table.customerNames} with the quotes. 
    4. Then save the formula and save the report. 
    Now when the report is run, you can click on the field and see the resulting customer details in the second report.
    我用WinForm试,HyperLink to 'report object'和 Hyperlink to 'file'不行,不知道是不是我的crystal report 版本有问题。