Results 1 to 5 of 5

Thread: Crystal report pro

  1. #1

    Thread Starter
    Frenzied Member met0555's Avatar
    Join Date
    Jul 2006
    Posts
    1,385

    Crystal report pro

    hi

    well my problem is, My database is in My document folder the crystal report read the data from there, i also connected my programe with the same database. but the pro is the database that i attached to the programe ,when u add a new data in it it don't add it on the database that is in my document , he add it in other project folder. so how can i make this thing work??

  2. #2
    Frenzied Member pnish's Avatar
    Join Date
    Aug 2002
    Location
    Tassie, Oz
    Posts
    1,918

    Re: Crystal report pro

    Your program needs to tell the report where the database is located, have a look at this post... http://www.vbforums.com/showthread.php?t=423542
    Pete

    No trees were harmed in the making of this post, however a large number of electrons were greatly inconvenienced.

  3. #3

    Thread Starter
    Frenzied Member met0555's Avatar
    Join Date
    Jul 2006
    Posts
    1,385

    Re: Crystal report pro

    ok, do i just have to write this code ?visual basic code:--------------------------------------------------------------------------------
    VB Code:
    1. Dim crApp As CRAXDRT.Application
    2.     Dim crDB As CRAXDRT.DatabaseTable
    3.     Dim Report As CRAXDRT.Report
    4.  
    5.     Set Report = crApp.OpenReport("c:\myreport.rpt")
    6.     Set crDB = Report.Database.Tables(n)
    7.     crDB.Location = App.Path & "\myDB.mdb"
    8.     Report.ViewReport
    if it's where in a button click, or in the crystal report viewr.
    and i'm using vb.net 2005 is it the correct code for it?

    tanks

  4. #4
    Frenzied Member pnish's Avatar
    Join Date
    Aug 2002
    Location
    Tassie, Oz
    Posts
    1,918

    Re: Crystal report pro

    This code is VB6 using CR9, but it should be similar for VB.Net.
    Pete

    No trees were harmed in the making of this post, however a large number of electrons were greatly inconvenienced.

  5. #5

    Thread Starter
    Frenzied Member met0555's Avatar
    Join Date
    Jul 2006
    Posts
    1,385

    Re: Crystal report pro

    sorry but this code didn't workk on vb.net

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