Results 1 to 2 of 2

Thread: Open Crystal Report file from VB automatically.

  1. #1
    Guest

    Post

    I've been trying to figure out a way to create a VB program that will automatically open a Crystal Report file when I click on that file from Windows Explorer. What I did was make a simple form with a Crystal Report Control on it. Then I associated the *.rpt file type with that program so that when I click on that file type, Windows will launch my program to try and open that Crystal Report file. I figure it must be some kind of DDE solution, I think. It can't be that difficult of a thing to do. I just don't know what I'm doing wrong.

    Thanks
    Mario Giannone

  2. #2
    Guru Aaron Young's Avatar
    Join Date
    Jun 1999
    Location
    Red Wing, MN, USA
    Posts
    2,177

    Post

    Do you use the Command Function to retrieve the Filename when your Application is Launched, as it would be passed as a Parameter, eg.
    Code:
    Private Sub Form_Load()
        Crystal1.ReportFileName = Command
        Crystal1.Action = 1
    End Sub
    ------------------
    Aaron Young
    Analyst Programmer
    [email protected]
    [email protected]

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