Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
  HOME    TRACKER    Visual Basic

Crystal Report Grand Total

i have a group. i want to a insert sum of 2 field at the footer of this group. there is another formula field on footer of this group which subtract sum of feild1 from sum of field2. problem is that i want to take grand total of these 3 field. grand total of field1 and field come correct but grand total of formula field not coming. how can i take grand total of calculated formula in group foooter.

thanks a lot!

View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread
Use Subreport Summaries To Perform A Report Grand Total
hi!, I'm mauricio. My problem is:
I have a report with many subreports in it (7), all the subreports are on a group (defined by a workorder number), each one of these subreports has a total (sum). I wish to perform a grand total in that parent group (WO#) using the sum of each subreport total. Is this possible?, thanks in advance.

[Resolved}DataReport With Sub Total And Grand Total With Out DataEnvironment
rsTotals.Open " SELECT Account_Type, Tax_Type, SUM(Payment)AS Total " _
              & " FROM tbl_TransDetails " _
              & " WHERE Entry_Date = # " & Date & " # GROUP BY Account_Type, Tax_Type ", _
                dbCCP, adOpenDynamic, adLockOptimistic, adCmdText

With rptSumTotals
       Set .DataSource = rsTotals
          .Sections("Section1").Controls.Item("txtAccounttype").DataMember = ""
         .Sections("Section1").Controls.Item("txtAccounttype").DataField = rsTotals.Fields("Account_Type").Name
          .Sections("Section1").Controls.Item("txtTaxtype").DataMember = ""
         .Sections("Section1").Controls.Item("txtTaxtype").DataField = rsTotals.Fields("Tax_Type").Name
          .Sections("Section1").Controls.Item("txtTotal").DataMember = ""
         .Sections("Section1").Controls.Item("txtTotal").DataField = rsTotals.Fields("Total").Name
   'for sub total
           .Sections("Section7").Controls.Item("fnSumTT").DataMember = "" 'rsTotals
         .Sections("Section7").Controls.Item("fnSumTT").DataField = rsTotals!Total
      'for grand total
          .Sections("Section5").Controls.Item("fnGTotal").DataMember = "" 'rsTotals
        .Sections("Section5").Controls.Item("fnGTotal").DataField = rsTotals!Total
giving error: its looking for payment values instead of Total values. so not able to find.
i placed Function control in Group footer section for sub totals and for grand total in Report footer section.
i am not using Data Environment as Data Source.
SQL is good, with out sub and Grand total i am able to print report with Total. after adding Those two function controls i am getting error.
If i assign rsTotals as DataMember "Type Missmatch error"

Help Me, Thanks in advance

Edited by - sreddy on 3/24/2005 9:25:02 AM

Grand Total
Ok i use a special field record number to get a grand total of field but if nothing is selected it still shows up as 1 and not 0. What can i do to change that?

Grand Total Help!
hello ,please help cannot get the correct grand total .

this is the currrent code:
Code: Set rs = New ADODB.Recordset
    strSQL = "select Department, Count(*)as DetCount, SUM(OtHours) As OtHours from Overtime where OvertimeDate BETWEEN #" & start & "# and #" & enddate & "# Group by Department"
rs.Open strSQL, conDataConnection, adOpenStatic, adLockOptimistic

While Not rs.EOF
        If IsNull(rs("OtHours").Value) Then
            total = total + 0
            total = total + rs("OtHours").Value
        End If
'set the database source in rs
   rptalldept.Sections("Section5").Controls.Item("Label15").Caption = Format(total, "#,##0.00") grand total field
   rptalldept.Sections("Section4").Controls.Item("Label19").Caption = start
   rptalldept.Sections("Section4").Controls.Item("Label21").Caption = enddate
   Set rptalldept.DataSource = rs
    'then set the field
    rptalldept.Sections("section1").Controls.Item("Text4").DataField = "Department"
    rptalldept.Sections("section1").Controls.Item("Text13").DataField = "OtHours"

thanks for help.

Edited by - monchichi on 1/16/2008 9:03:52 PM

Grand Total Of 5 Tables
I want to display the subtotal of 4 tables on each label. But it is displaying the subtotal of only first table. How can I display the subtotal of all tables together and then GrandTotal. Please help me to solve this problem. You can find the picture attached:

The code which I have written is:


Set conServer = New ADODB.Connection
With conServer
.Provider = "Microsoft.Jet.OLEDB.4.0"
.ConnectionString = "Data Source=" & App.Path & "Estimation.mdb;Persist Security Info=False"
End With

Dim rstTmp As ADODB.Recordset
Set rstTmp = New ADODB.Recordset
Dim item As ListItem, count As Integer, Total, grandtotal As Integer

With rstTmp
.ActiveConnection = conServer
.CursorType = adOpenStatic
.LockType = adLockReadOnly
.Open "SELECT * FROM PreliminariesDetail"
End With

If GetRowsOk(rstTmp) Then
Total = 0
While Not rstTmp.EOF
Total = Total + rstTmp.Fields("Amount")
For count = 1 To rstTmp.Fields.count - 1
With item
On Error Resume Next
.SubItems(count - 1) = rstTmp.Fields(count)
End With
frmSummary.lblPreliminariesTotal.Caption = Total
End If


*** I am writing the same above mentioned code for another table, with different table name i.e. "PilingDetail" and so on. Is this a right way, or I should do it in another way??? Please help me ***


With rstTmp
.ActiveConnection = conServer
.CursorType = adOpenStatic
.LockType = adLockReadOnly
.Open "SELECT * FROM PilingDetail"
End With

If GetRowsOk(rstTmp) Then
Total = 0
While Not rstTmp.EOF
Total = Total + rstTmp.Fields("Amount")
For count = 1 To rstTmp.Fields.count - 1
With item
On Error Resume Next
.SubItems(count - 1) = rstTmp.Fields(count)
End With
frmSummary.lblPreliminariesTotal.Caption = Total
End If


*** Please correct the code, and tell me that what is the best way to display the subtotal of all 4 tables together.


Add A New Column After The Row Grand Total
By using Crystal Designer, I created a crosstab report to show the number employees in every department. The summarized column contain 2 different sum field, "foreign" and "local".
         JAN      FEB    
Department           Grand Total
ProductionA Foreign      [20] [30]    [ 50]
     Local [60] [50] [110]
ProductionB Foreign [30] [35] [ 65]
     Local [55] [50] [105]

As we can c, the crosstab report will auto generate a grandtotal field for my summarized column. Now, my question is: How could I change the Grand Total into the "Average No. of Workers". the formula should look like this:

Any idea? ^_^

Getting Grand Total From Data Grid ?
Hi, I want to get a total from data grid in one column of data grid (of a day) so how to get it ? ps I also want to know how to sort datagrid list ? by any field, thank for your help in advance

Seagate Reports Groups Grand Total

i have calculate a formula with subtotal of a group and another database field. now i want to make grand total at last with this formula field.

Display Grand Total Field At Datareport
how to display the grand total field at the datareport??actually i already have the grand total result,just that i can get the report display i wish to have.

i post the image file for the report i wish to have.

thanks for help

Edited by - monchichi on 6/29/2007 8:35:16 PM

Hiding Grand Total From Pivot Table Using VBA
Does anyone know how to hide the Grand Total column and/or row from a pivot using VBA in excel? I know how to remove it manually by using the pivot table wizard but I need to hide with VBA code in the macro when it is run.

Any help will be appreciated.

Storing The Cell Address Of Subtotals In Order To Generate Grand Total Figure

With the help of you guys, I was recently able to enable a Sub to generate subtotals in a range of data (without the use of EXCEL worksheet function, 'SUBTOTAL').

My next dilemma is generating a row beneath all of the subtotalled data, which is a GRAND TOTAL of each individual SUBTOTAL figure.

The code I have to genereate the subtotals is as follows:

Code:Sub stotal()
Dim iRow As Integer
iRow = 1 'Start at row 1
'add a new line in sheet at each change in value for Col A.
'this will allow room for subtotals to be added
Do Until IsEmpty(ActiveCell)
    If ActiveCell.Value <> ActiveCell.Offset(1, 0).Value Then
        ActiveCell.Offset(1, 0).Select
        Selection.Insert Shift:=xlDown
        ActiveCell.Offset(0, 2).Range("A1:P1").Select
        ActiveCell.Offset(1, -2).Select
        Call AddUp(iRow) 'Calculate and fill in the subtotals
        iRow = ActiveCell.Row 'Save the starting point of the next series of numbers to be added up
        ActiveCell.Offset(1, 0).Select
    End If
End Sub

Private Sub AddUp(X As Integer)
Dim iCol As Integer
Dim tblone As Range
Dim tblcount As Integer

iCol = 3

'set the current region for tblone, to determine the number of lines to be summed
'in subtotal
Set tblone = Worksheets("Reconciliation").Cells(X, 1).CurrentRegion

tblcount = tblone.Rows.Count

Cells(tblcount + 1, iCol).FormulaR1C1 = "=SUM(R" & X & "C" & iCol & ":R" & tblcount & "C" & iCol & ")"

End Sub

Now, my thinking at the moment, is that each time a new line is inserted for a subtotal, the address of this cell is stored. At the completion of all subtotal rows being inserted, the GRANDTOTAL cell is the sum of each stored address, displayed something like:

Code:ActiveCell.FormulaR1C1 = "=SUM("addressone"+"addresstwo"+"addressthree"+" . . . etc. ")"

Now, the question is: How do I get each subtotalled address to be stored and then totalled as a GRANDTOTAL.

I am assuming that this is the best way to do this task, but someone may know an easier/quicker way.

I have attached the Worksheet that I am working with, just to give an idea of the data.

Thanks in advance,


PAGE TOTAL In Crystal Report

I want to calculate and print PAGE TOTAL of numeric fields in crystal report8.5. How can I do it? Help is appreciated.

Crystal Reports - Report Total
I'm trying to get a report total of field that's already totaled in a group. In my group footer I have a formula field - GrpTot1
Sum ({OrderDets.UnitSellPrice}, {OrderHdr.OrderNum}) - Sum ({OrderDets.UnitCost}, {OrderHdr.OrderNumber})
But when I try to do a report total - Sum ({GrpTot1}) I get 'Summary/Running Total Field cannot be created'. If I right click on the field, it doesn't give me the option to Total. How do I get an over all total????

Crystal Report Total Error
I want a report which shows the "quantity" of particular type of item &
their Total Quantity in a detail section.

Item code:001
grn quantity:11
inv quantity:
isi quantity:15
iso quantity:
Total Quantity:26

When i preview the report,the "total Quantity" field in Detail Section
shows 0(zero) in 1st record.In the next line it shows the sum correctly.
i want to remove the 1st record in the total quantity field.

working details:
I have created 4 sub-reports to select particular type of inventory
(ex:grn,inv,isi,iso) & using the formula to store the quantity in
formula: Shared numberVar grn :=Sum ({Table1.qty}, {Table1.itemcode}) ;

In Main Report i sum all the 4 sub-report values using the formula
numberVar total := {@vgrn} + {@vinv} + {@visi} + {@viso};
but it does not give me correct result.

How To Do Pagewise Total In Crystal Report 8.5
how can i calculate pagewise total in Crystal reports8.5. for example my report contains 5 pages i need one page toal at bottom of that page and that total should be carry forward to next page at the top of next page and so on. please help


Adding Some Values To Running Total In Crystal Report 8.5
I m creating Account Ledger Report in Crystal Report 8.5.
I have put DATE , DESCRIPTION , DEBIT & CREDIT fields from Tbl_Ledger
and for balance i have created a Formula (RemBal) and write the code Tbl_Ledger.Debit - Tbl_Ledger.Credit

This (RemBal) has put it in Running Total.
I also have a formulafiled LASTBALANCE which value is = 500

I want to add that LastBalance value in Running Total but it effects on all rows.

How can i do this ?

Please help me

thanks in advance

Total Summary In The Page Footer In Crystal Report 8.5
I want to know how I can put in the page Footer ina Crystal Report 8.5 Report, a Total summary for page.... I don'nt know if I need to build a formula to accomplishment this..

Thanks for advance for you help


How To Display Comma(,) For Total While Adding,Searching,Printing Using Crystal Report
Hai Friends,

    Good Morning.

While Adding a record, i am in need of my total to be displayed as 11,20,990.80 like that. for that i used, Code:'" & Val(Format(Trim(Textnetamt), "#####0.00")) & " '. While adding a record its showing me comma's but its displaying as 1,120,990.80 which i want that to be displayed as 11,20,990.80 (as this is our format of specification for the totals).

    Also, while searching its not displaying comma's for me.

And Another major problem is with Printing Crystal Report.

Can any one rectify me.

I hope , in printing, we have to do some coding for Customizing in the Format Field of the Net Amount Text.

is that so,

help needed



Crystal Reports Cross-Tab: Suppressing Row Grand Totals At Runtime
I have a cross-tab which is either going to be populated with percentages or currency values (depending upon user selection). When currency values are being loaded into the cross-tab I would like it to show row grand totals, but in those cases where percentage numbers are being loaded into the cross-tab I would like to suppress row grand totals. I have a field in the table the cross-tab is derived from which contains either a "N" for currency fields and a "P" for percentage fields.


Unable To Open The Crystal Report Exported In Crystal Report Format
Sub: Unable to open the Crystal report exported in Crystal Report Format

1)    I have used Oracle Native connection, while designing the report.
2)    I have passed the record set to the report at run time.
3)    Exported the report to Crystal Report Format, But I could n’t able to open report, while opening , the report asks for OLEDB information, even though I used Native connection at design time.
4)    In Crystal Report 8.5, connect driver property, but I am using crystal reports XI and in Visual Basic 6.0, Is there any method or property to convert the connection?. As I have to export report to crystal format and emailed to user, so that user can open it.
Any assistance in this regard is highly appreciated

The code is as follows:
Public Sub Aging_REPORT(strSQL As String, sReportName As String, sDestFileName As String, ReportTitle As String)

On Error GoTo Err
Dim CrAppl As CRAXDRT.Application
Dim crrep As CRAXDRT.Report

Dim rsCrystal As ADODB.Recordset
    Set CrAppl = New CRAXDRT.Application
    Set crrep = CrAppl.OpenReport(sReportName) 'Opens the report
   Set rsCrystal = New ADODB.Recordset
    rsCrystal.Open strSQL, Conn, adOpenStatic, adLockReadOnly
     With crrep
    .Database.LogOnServer "crdb_oracle.dll", strServerName, "", strUserName, strPassword
     .ReportTitle = ReportTitle
     .Database.SetDataSource rsCrystal, 3 'LINK REPORT TO RECORDSET
     .VerifyOnEveryPrint = True
     End With
   With crrep.ExportOptions
    .DestinationType = crEDTDiskFile
    .FormatType = crEFTCrystalReport
    .DiskFileName = sDestFileName
   End With
   crrep.Export (False)
    Set crrep = Nothing
    Set CrAppl = Nothing
    Exit Sub
 MsgBox Err.Description

End Sub


Crystal Reports Total
Hello all

I am trying to create a running total field in crystal reports where the total does not include the current record.

i.e. the total of all records except the current record.

I need this so that I can take a percentage of the running total so far and then add the result to the running total.

If I use the normal running total field then I create a circular reference i.e. the percentag running total calculation includes the running total and then increments the running total and crystal bombs out.

Any ideas??

Access Report - Total Sub Report

I have a report that contains a sub-report. I'm trying to show a total in my main report report footer based on the sub-report, but no luck.

I've found an article (208835) on the MS website, but this doesn't work, it's either me or it's not correct?

Can someone tell me how to do this?

So far I have a textbox which contains the following: -


But when run it shows #Name?

And this is from following the MS Article!

Any help much appreciated.


Total In Vb Report
Hi Im trying tog et the total of 4 fields in a report. I have shipping, drum chg, fuel chg, which only have one response and i can do that with a sql statement but when i try to add ext price wich usually has more than one response it adds the total of (shipping, fuel, and drum) to each field it adds of ext price.

Im using vb report designer and its pulling from access.

hope this makes sence

Crystal Reports: Get Total Hours This Month

Originally Posted by MKoslof

If this works, go with it. Good luck.

My thoughts exactly! Thanks for your help.

Edit by Mkoslof: I have split this thread from the original thread since we are dealing with a seperate Crystal formula issue. And, it is easier to read which posts are dealing with the current issue. The other issue has been resolved. Thanks

Crystal Reports: Get Total Hours This Month
Using the following formula, I managed to pull out the total hours per Employee trained this month:

if Month({Employee Training.FINISHDATE}) = Month(CurrentDate) and
Year({Employee Training.FINISHDATE}) = Year(CurrentDate) Then
Sum ({Employee Training.HOURS}, {Employee Training.FINISHDATE}, "monthly")

Can someone help me get the total of that formula? I need to know the grand total of trained hours this month (for all employees) and can't sum on a summary field.

My report looks kind of like this:

PHP Code:

EmplID          Hrs YTD          Hrs This Month
-------         --------         ---------------
92191           3.50               1.0
92929           15                 12
92922           2                  0 

I want the have the total Hrs YTD and the total HRs This Month in the report it would look like:

PHP Code:

EmplID          Hrs YTD          Hrs This Month
-------         --------         ---------------
92191           3.50               1.0
92929           15                 12
92922           2                  0

Total Hrs:      20.50              13.0 

Adding A Total To A Report
I would like to add a TOTAL to the bottom of a report where the TOTAL gets calculated through a Query. I select the Ab| section of the toolboax add it to the report and it creates an unbound object. The inside of the unbound frame looks like this : =[qryTotal]![Sum of Amount]. When I run the report Access 2000 asks me "ENTER PARAMETER VALUE" for QryTotal???? is not recognizing the value. What am I doing wrong?

How To Place A Total In A Report?
I have a table (tblPO) which contains these fields:

1. ItemNo
2. PONo
3. SubTot

Now, I have a query that states:

SELECT Sum([subtot]) AS Total

The thing is, I don't know how to combine it with the aforementioned 3 (ItemNo, PONO, SubTot) and how to display only one Total in the report.

What I like as a result would be on the attached image. Any suggestions would be appreciated. Thanks.

How To Pass Format String To Crystal Report From VB And How To Use It In Crystal Report?

I am working on VB 6.0 and using crystal report 7 as reporting tool.
In report, some clients are asking 3 decimal places(Eg. 2000.500) while other clients are asking 2 decimal places(Eg. 2000.50) for numeric fields.
I want to pass the amount of decimal places for numeric fields to crystal report from VB.
How should I implement this using VB.
Pls any one can help me?

Thanks in vance,

How To Replace Crystal Report Control With Crystal Report Designer

I want to replace crystal report control with crystal report designer in vb. report files are ready.
and parameters have passed by crystal report control to the actual repors which are made in segate crystal report.
now i want to keep the re[prt files as it is. but instead of control,
i want to use designer.

plesae help me


Crystal Reports : Total Of A Field In Multiple Columns

I have created one report with multiple columns (Right click on Details section -> Select 'Format Section' from popup menu -> Check mark the field 'Format with Multiple Columns').

'Weight' field is in both columns. Now i want the total of Weight in each column on every page.

Please help me with this issue

Access - Show Total From Sub-Report

I have a main report that contains a sub-report.

I want to show a total for the sub-report in my main report's report footer, but to date haven't been able to do so.

Does anyone know if this is possible and if so how?


Data Report, Page Total Possible?
I know that the function control can't be placed on the page footer section. Just wondering if there's a way around this restriction so I can get the total for the page.

e.g. A long list of values, no grouping, and for every page the total for that page only. At the end of the report would be the grand total = sum of all OR sum of page totals.

I hope it's possible. Thanks for your time.

Problem On Total. VB Data Report
I hav a problem.Please try to solve it.

I wants a data report which will show report as under :

Pay Slip

Designation : XXXXXXXXXXX
1. Earning

Basic         : 6000
Da        : 3000
other        : 600
Gross Salary    : 9600

2. Dedictions

EPF        : 2000
HRA        : 500
Net Deduction    :2500

Net Salary        =7100
1. Earning

Basic         : 5000
Da        : 2000
other        : 500
Gross Salary    : 7500

2. Dedictions

EPF        : 1000
HRA        : 500
Net Deduction    :1500

Net Salary        =6000

Now problem is that Gross salary is coming 9600 for all case, same also in Net deduction & Net Salary.Only frm ist record is taking

My Program is as under

Private Sub DataReport_Initialize()
Dim sn As Integer, gross As String, kk As Double

If rs.State = 1 Then
End If

rs.Open ("Select a.emp_id,,a.desig,a.scale,b.bp,b.da,b.other,,c.ptax from emp a,earning b,deduction c where a.emp_id=b.emp_id and a.emp_id=c.emp_id "), adoConnection, adOpenKeyset, adLockOptimistic
Set Payslip.DataSource = rs 'Bind Data Report
Payslip.Sections("Details").Controls("lbldate").Caption = LTrim(Month_Year)
Payslip.Sections("Details").Controls("gross").Caption = gross

With Payslip.Sections("Details")
        .Controls("emp_id").DataField = rs("emp_id").Name
        .Controls("name").DataField = rs("Name").Name
        .Controls("desig").DataField = rs("desig").Name
        .Controls("bp").DataField = rs("bp").Name
        .Controls("da").DataField = rs("da").Name
        .Controls("other").DataField = rs("other").Name
        .Controls("gross").Caption = gross

        .Controls("pf").DataField = rs("pf").Name
        .Controls("other1").DataField = rs("other1").Name
       .Controls("gross1").Caption = rs("gross1").Name
End With

End Sub

Please solve my problem.


Page Total In A Data Report
Hi! Deke, Could you please suggest a method to calculate Page Total in a Data Report
Thanks in Advance for any suggestions

Data Report Field Total
im using a dsn-less connection on my application. and im using data report without data environment. my problem is how am i going to make a running computation (sum) for a certain field in ms access database. below is the sql im using

Set rs = cs.Execute("select * from truck_hist where truck='" & CmbTruck.Text & "' and body='" & TxtBodyNo.Text & "' and date>=#" & Calendar1.Value & "# and date<=#" & Calendar2.Value & "# order by date asc")

now i want to make a running total for price field with the above condition. can somebody help me?

How To Get Running Total In Data Report
I want to print total of previous pages at the top of current page. just like a running total in crystal reports

Crystal Report ActiveX Vs Crystal Report Wrapper.bas
When print a report via Visual Basic, is it recommended to use the methods and properties of the ActiveX or using the functions provided by the wrapper, such as PEOpenPrintJob and etc.? If there's no diff in using both, then I have a question. There is a PEClosePrintJob function in the wrapper, however, there isn't any methods or properties in the ActiveX to perform such function. What will happen if PEOpenPrintJob (called by ActiveX's ReportFileName) is executed x times but the print job is not closed at all?



Connecting SQL Db From Crystal Report (through VB Crystal Report Control)
VB -> Crystal Report -> SQL database
I need to use VB to call CR (Crystal REport) to access data in an SQL server.

1) Over at the SQL server, I have created a login account, login ID = "RMS", and password = "9999".
2) I have created a ODBC - System DSN (in the control panel), with the login ID, password as in (1).
3) I have run-time CR installed on the client PC.
4) At the click of a button in my VB application, the CR (.rpt) will open (via Crystal Report Control in VB) and retrieves data from the SQL server database through the System DSN created in (2).

MY VB application FAILS to open up a CR file (.rpt) No error message though.

I realise that the VB CAN only open the CR (.rpt) when the PASSWORD in (1) is LEFT BLANK.

It seems that I have to Hardcode the password somewhere.
1) HOw do I pass the password to CR so that the CR will not fail to display itself?

Really appreciate your good karma!

Thanks in advance!

Crystal Report... How To Print Crystal Report Using PrintDocument??
Hi.. I need help greatly... there's an issue which required me to make use of the PrintDOcument Object to print this crystal report..Instead of the pre defined printer button on the crystal report viewer..???Can anyone teach me HOW to print crystal report using the print document??it just seems to can't capture the crystal report for printing.... ANd how do i make use of the PrintPage Event???

Need Help With Project... How To Make An Income, Expenses And Total Report Section?
Hello. I am a Student Programmer in need of urgent help. I am busy with a project that needs to be handed in by 17 Aug 2001. I need help creating a reports section for a stand-alone accounting app. This section must include your current balance and total amount of income and expenses.

How do I write a SQL query for this and then link it to my application?

Any help will be greatly appreciated.

Thank You

Accessing Main Report Field From Sub Report In Crystal Report 8.5
Hi there,

is it possible to access a field that is in a main report from the subreport. The sub report and main report uses different Sql
statment. How could i achive this.

The reason i need this is because, i would like a value to appear
in a fieldA in the subreport, if the value in fildmain in main repoert is equals to 10.

any suggestions....

Thank You...

regards ....

How To Dynamically Change The Login Info Of A Crystal Report Using Crystal Query File

How can I dynamically change the login information of a Crystal Report that uses a Crystal Query File (*.qry) to retreivee it's data using VB.NET?

It works fine when the report is built on regular table links generated within the Report Designer, I simply use the following :

Dim myLogonInfo As New CrystalDecisions.Shared.TableLogOnInfo()
myLogonInfo.ConnectionInfo.ServerName = UCase(SelectedDB.GetName) & "_ODBC"
myLogonInfo.ConnectionInfo.DatabaseName = UCase(SelectedDB.GetName)
myLogonInfo.ConnectionInfo.UserID = UCase(usr)
myLogonInfo.ConnectionInfo.Password = UCase(pwd)



But when the Data is retreive using a query file it crashes.
Any ideas?


Grand Prix 3 Jam Files
The graphics files in GP3 are called Jam files. does anyone have any code to open them in VB?

Pivot Table Grand Totals
I have created a Pivot table in Excel to extract information and am wanting to check automatically check the Totals I started with match those I finished with. Is there a way to get the Grand Total value without having to search for the Totals Cell. eg something like: Test Value = PT.ColumnGrandTotal.Value

Once again thank you for any advise you can supply.


Edited by - RobbbH on 1/3/2007 4:04:16 AM

In Crystal Report, Report Is Viewed But Doesnot View Next Page Or Not Any Message Display!
in crystal report, report is viewed but doesn't view next page or not any message display! and surprisingly page no is increased infinitely (up to no limit!, I have checked up to 400+) but next page was not displayed! if I print report , only 1st page is print!

In this report , I have attached 6 subreports!

I hope anybody reply about my problem

Storing And Retriving Images From Access Databse Through VB Data Report Or Crystal Report
hi friends
    i have a problem that i have a database of some 8000 students in which there is a field called "photo" which stores the photograph. it is stored as BLOB field. now i want to retrive it in my report. i'm getting very much difficulties in it. can i have a help from master minds to resove the same. it will be very much helpful to me.
    my e-mail id:
  ur suggestions r welcome. anybody can mail me. hoping for the best.

Crystal Report Crosstab Report Criteria Selection Using Access 2000
Hi there
I there anyone with an idea on how i can filter crosstab Report done in Crystal Report 8.5.. I'm trying to get data btw two dates for instance 05/01/04 and 05/31/04 but the following code doesn't do that. I'm using access 2000 database. Pls assist.

fMainForm.CrystalReport1.ReportSource = crptReport
fMainForm.CrystalReport1.ReportFileName = "F:OutGrowerReportsGLdelivered.rpt"
fMainForm.CrystalReport1.SelectionFormula = "Wdate" >= " & {CrossTabData.WDate} =" & "'" & CDate(DTPicker2.Value) & " AND Wdate" <= " & {CrossTabData.WDate}=" & "'" & CDate(DTPicker2.Value) & "'"
fMainForm.CrystalReport1.WindowState = crptMaximized
fMainForm.CrystalReport1.PageZoom (100)

or is there another better way to do this.

Help With Report - Easy One For People Familiar With Crystal Reports, Data Report Et Al
Till date, I have worked only with the Data Report
Utility that is dovetailed with the Data Environment
Designer, for the purpose of generating reports in my
applications. Shamefully, I am completely nescient of
Crystal Reports. I would want someone to kindly take
time to read my query and provide me a clue as to the
solution. The problem, I surmise, would be
interstingly simple for the creed of programmers who
are familiar with reporting softwares like Crystal

I have a table in MS-Access 2000 and its called
'Holidays'. The Holidays table has the following

What's Logon Parameter To Oracle Server With Vb To Print Report With Crystal Report
Hi all,

How to write a log on parameter to oralce server with using vb to print a report that using crystal report

is it crystalreport1.connect = "Dsn=servername;uid=username;pwd=password"

and how to use the selectionformula

Copyright 2005-08, All rights reserved