How Do You Pass Database Logon Information To A Crystal Report 10 At Runtime In VB6?
hi, i have project in VB6 and use Crystal Report 10 as my report. my backend database has password, so when i open my project and view the report, the report cannot loaded bec. of my password in database, so How can i pass database logon information to a Crystal Report 10 at runtime in VB6? i use crystal viewer of Crystal Report 10... waiting to your reply....
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
How To Pass Runtime Image To Crystal Report
Hi all,
I have came across a problem in my project.
I want to pass runtime image to Crystal Report through VB.I have saved the path of the image in Access .
I have searched related web through google,but I didn't get the help.
If you know something abt it plz if possible mail me.
Thanks
Amit.
Pass Table Name At Runtime To Crystal Report
Hi All,
I am using vb6 with crystal report 7. In my porject I am creating a temporary table at runtime to organise my report data, could any one tell me how to pass this temporary table to crystal report...is there any property or method of crystal report control using which i can pass on this tablename.....
Just to give a background I have created the desing of crystal report using the similar table so the field name and all the setting will remain same only the table name will be different..so i would like to know is there any way by which i can pass on this new table name to crystal report.
Thanks in advance.
Jignesh
How To Pass 2 Recordset To The Same Crystal Report From VB At Runtime?
I am using vb 6 & crystal report version 7. I had tried to pass 2 recordest to crystal report from vb at runtime by using data definition(TTX) files but it doest work. Is there any method or others way can complete this task?
i am new user for crystal report, hope someone can give me a help. Pls attached the coding sample as well. Thanks!
Crystal Report Database Connection Logon Failed Error
hi
i get log on failed when trying to connect to access database through
field explorer wizard database connection.
in the dialog box i m giving password which is the one to open access file so it is right?
otherwise if i dont assign password to access database file it works fine but with password it gives error .
and also what goes in jet database and jet database password textbox on dialog?
thanx in advance
nilesh
Write Code For Crystal Report Logon Server Access Database
Hi,
I have an application that connects to an access 97 database. The database is password protected, therefore I need to code the connection in my application. I have managed to write the code for vb to connect to the database. However I am having a problem with the reports because they are designed in crystal. Whenever I try to run the report, I get an error that says "File could not be open: Name of Query" at file location: Name of Query. I assume its because of the password protection. Is there a way to code the logon server properties in the code.
Here is the code that I use to open the report.
Private Sub cmdRun_Click()
Dim StrReport As String
Dim StrFormula As String
Const conquote = """"
Dim StrCaption As String
Dim year As String, year1 As String
Dim strSQL As String
On Error Resume Next
StrReport = strPath & "
ptAnnualFeesSummary.rpt"
StrCaption = "OSI - Annual Fees Report"
If Me.cboYear.Text = "" Or Me.cboYear.Text = "" Then
MsgBox "Please select a year range for the report", vbOKOnly + vbCritical
Exit Sub
End If
If Len(Me.cboYear.Text) > 0 And Len(Me.cboYear1.Text) > 0 Then
year = Me.cboYear.Text
year1 = Me.cboYear1.Text
StrFormula = "{qryAnnualFees.Year} = " & "'" & year & "'" & " to " & "'" & year1 & "'"
End If
Me.Text1.Text = StrFormula
With crptCrystal
'Set Source, Report name and Destination
.DataFiles(0) = _
strPath & "SupervisorOfInsurance97.mdb"
.ReportFileName = StrReport
.Destination = crptToWindow
.LogonServer ????????????????????????
.WindowTitle = StrCaption
.SelectionFormula = StrFormula
.WindowState = crptMaximized
' Print the report
.WindowShowRefreshBtn = True
.WindowShowProgressCtls = True
.PrintReport
End With
Exit Sub
error: MsgBox Err.Description, vbOKOnly
End Sub
How can I code in the logon server parameters???
Database Change Runtime In Crystal Report 8.5
hello friend
i want to connect with crystal report at runtime i am using Ms-access 2000 and VB 6.0
i have problem when i change database name or location my report can not be open or say view
I want code for this in vb
help me and get help
Changing Database Path At Runtime In Crystal Report
Sir,
I am using CRViewer Control and ICRDesigner control to create/show the Crystal report. My back-end is mdb(Access) database. I want to know the code to set the database path at runtime. Could anyone help me.
Changing Database Name And Location Runtime For Crystal Report
i m devloping one application in vb 6 and ms access , which uses 2 database. at runtime according to condition i want to fetch data from different database. i tried to changed datasource at runtime, it does not give any error but it gets data from the design time database only. my code is as below to change datasource.
Dim sql As String sql = "sElect * from Certificate"
Set adoRs = CreateObject("adodb.recordset")
adoRs.Open sql, "Provider=Microsoft.Jet.OLEDB.4.0;Password='' ;Data Source=" & App.Path
& "gramcommon.mdb;Persist Security Info=false", adOpenKeyset, adLockBatchOptimistic Me.Database.SetDataSource
adoRs adoRs.ActiveConnection Me.Database.AddADOCommand adoRs.ActiveConnection, adoRs.ActiveCommand
Me.Database.Verify Me.VerifyOnEveryPrint = True
pl. help me, if this way or any other way to change database of crystal report with .dsr file exten.
if possible pl mail me on meenxip@yahoo.com
Crystal Report Working With Runtime Relative Path Of Access DataBASE
I am Amit , Sys. Analysis , We r working in Vb last 3 years with Data reporting . Now we have to shift our projects to Crystal REPORTS 8 .
Tell Me How Can I Design Reports Using Without using Absolute Path of Access .mdb Database File i.e c:
ew.mdb or d:
ew.mdb .
At SETUP Time , User can Select Different Location tnhen these CR Reports Can not Work due to Absolute PAth at design time . HOW WE CAN DEFINE PATH OF DATABASE AT RUN TIME of CR8 or VB .Like (App.Path)
...... Please Reply ASAP.
--AMIT
Logon To SQL Server Using VB In Crystal Report
I am using SQL server, crystal report 9 and VB 6 to make a report program.
Now, I need to Logon to the server in the crystal report viewer using VB6.
Below is my current code
Code:Dim crystalApp As CRAXDRT.Application
Dim CRReport As CRAXDRT.Report
Set crystalApp = New CRAXDRT.Application
Set CRReport = crystalApp.OpenReport("Q:IT DeptReportProgramSalesReport.rpt")
frmGenReport.CRViewer.ReportSource = CRReport
frmGenReport.CRViewer.ViewReport
frmGenReport.CRViewer.Zoom 100
Set crystalApp = Nothing
Set CRReport = Nothing
Can I pass the logon information to the crystal report viewer?
What should I add?
Edited by - ustreddog on 5/4/2004 8:06:40 PM
Logon Failed For Crystal Report
Hi,
encountered a big problem here.
I have create a rpt with a crystalreportviewer on a aspx page. It runs well on my local machine. But when pushing it to my live server, (my database is on another machine), the following error occurred
CrystalDecisions.CrystalReports.Engine.LogOnException: Logon failed.
Can enlighten??
this is my codes
crpt = New CrystalReport4()
For Each myTable In crpt.Database.Tables
myLogin = myTable.LogOnInfo
myLogin.ConnectionInfo.ServerName = "server1"
myLogin.ConnectionInfo.DatabaseName = "abc"
myLogin.ConnectionInfo.UserID = "sa"
myLogin.ConnectionInfo.Password = "sa"
myTable.ApplyLogOnInfo(myLogin)
Next
CrystalReportViewer5.ReportSource = crpt
THANKS FOR ANY HELP RENDERED
Crystal Report Viewer: Logon Failed (VB 6.0)
Dear all,
There is an error message "Logon Failed" on one of the user's pc while he was trying to preview for certain reports, he could view the rest of the reports without any error message prompted. Besides, there is no problem for developer's pc and other users pc to view the reports. The system is written by using VB 6.0 and intergrated with CR IX. Does anyone could help?? Thanks.
Logon Problem On Calling Crystal Report
I had make a report on Crystal Report IX using ODBC Connection for the Oracle database and it's doing fine when i previewed, but when i want to call it from VB 6 i got this message
" [ORACLE][ODBC][ORA]ORA-01005:Null password given;logon denied "
I also tried using ADO for the report but it still asking for password when i call it from VB.
This is the command to call the report
code:
Dim crystal As CRAXDRT.Application
Dim report As CRAXDRT.report
CRViewer.DisplayBorder = False 'MAKES REPORT FILL ENTIRE FORM
CRViewer.DisplayTabs = False 'THIS REPORT DOES NOT DRILL DOWN, NOT NEEDED
CRViewer.EnableDrillDown = False 'REPORT DOES NOT SUPPORT DRILL-DOWN
CRViewer.EnableRefreshButton = False 'ADO RECORDSET WILL NOT CHANGE, NOT NEEDED
CRViewer.EnableCloseButton = True
Set crystal = New CRAXDRT.Application 'MANAGES REPORTS
Set report = crystal.OpenReport(rep_name) 'OPEN OUR REPORT
report.RecordSelectionFormula = strfilter
report.DiscardSavedData 'CLEARS REPORT SO WE WORK FROM RECORDSET
CRViewer.ReportSource = report 'LINK VIEWER TO REPORT
CRViewer.Height = Me.Height
CRViewer.Width = Me.Width
CRViewer.ViewReport 'SHOW REPORT
Problem In Crystal Report...LOGON FAILED
hi everybody..
I have a small issue in Crystal Reports...
I have developed a report in Crystal Report 9 and used SQL Server 2000 connecting by OLE DB provider.
Now when I am using visual basic to connect the database dynamically e.g. objReport.Database.LogOnServer "crdb_ado.dll", "myserver", "mydatabase", "sa", ""
I am getting the following error.
Logon Failed.
Datasource name not found
Is theere any other way or Ihave to use DSN only.
If I'm using ODBC then I have to refresh with new database name to all the reports whenever i install in other pc.
Please suggest me to resolve this issue.
It is very urgent...
Regards
Sania Imtiaz
How To Pass Format String To Crystal Report From VB And How To Use It In Crystal Report?
Hi,
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,
Soundar
Please Help Crystal Report 10 Logon Failed When SQL Three Tables Join
I am working on VB6 for crystal reports 10 Develop Edition , the database is MYSQL. i need three tables to create a report .it works fine in local LAN (any of the computers,windows),but when connecting by remote access through VPN ,an weird error comes out :Logon Failed Details:01000:[Microsoft][ODBC SQL Sever Driver][DBNETLIB]connectionopen(connect()).
but if i use only one table to create it no matter in LAN or VPN works perfectly .after googling.knowing that each table need User ID ,Password,DSN to login .but it didn't work for me .could it be possible that the SQL string is not so appropriate ?
anyone who can give me some hints or codes i would be greatly appreciate. thanks a lot in advance
here is my code:
Option Explicit
Const CONSTR = "Provider=SQLOLEDB;data Source=***;Initial Catalog=northwind; " & _
"User Id=***;Password=***"
Dim strSQL As String
Dim rs As New ADODB.Recordset
Dim conn As New ADODB.Connection
Dim crystal As CRAXDRT.Application 'LOADS REPORT FROM FILE
Dim report As CRAXDRT.report 'HOLDS REPORT
Dim CRXDATABASETABLE As CRAXDRT.DatabaseTable
Private Sub Form_Load()
'THIS CODE IS USED TO DISPLAY A CRYSTAL REPORTS 9 REPORT USING
'DATA PULLED FROM A MYSQL DATABASE USING ADO AND VISUAL BASIC 6
'YOU NEED REFERENCES TO: Microsoft ActiveX Data Objects 2.7 Library
' Crystal Reports 9 ActiveX Designer Run Time Library
'YOU NEED THE COMPONENT: Crystal Reports Viewer Control 9
'ADD THE CRVIEWER91 COMPONENT TO YOUR FORM AND NAME IT CRViewer.
CRViewer.EnableExportButton = True
CRViewer.DisplayBorder = False 'MAKES REPORT FILL ENTIRE FORM
CRViewer.DisplayTabs = False 'THIS REPORT DOES NOT DRILL DOWN, NOT NEEDED
CRViewer.EnableDrillDown = False 'REPORT DOES NOT SUPPORT DRILL-DOWN
CRViewer.EnableRefreshButton = False 'ADO RECORDSET WILL NOT CHANGE, NOT NEEDED
Dim strsql1 As String
Me.WindowState = 2
strsql1 = "select customer.country,customer.name,supplier.country,supplier.name,order.id,order.product from customer,supplier,order where customer.id='" & Trim(form.id1.Text) & "' and supplier.id='" & Trim(form.id2.Text) & "' and order.id='" & Trim(form.id3.Text) & "'"
If conn.State = adStateClosed Then _
conn.Open CONSTR
If rs.State = adStateOpen Then rs.Close
Set rs.ActiveConnection = conn
rs.Open strsql1, conn, adOpenKeyset, adLockOptimistic
Set crystal = New CRAXDRT.Application 'MANAGES REPORTS
Set report = crystal.OpenReport(App.Path & "order Report.rpt") 'OPEN OUR REPORT
For Each CRXDATABASETABLE In report.Database.Tables
CRXDATABASETABLE.ConnectionProperties.DeleteAll
CRXDATABASETABLE.ConnectionProperties.Add "DSN", "***"
CRXDATABASETABLE.ConnectionProperties.Add "user id", "***"
CRXDATABASETABLE.ConnectionProperties.Add "password", "***"
Next CRXDATABASETABLE
report.DiscardSavedData 'CLEARS REPORT SO WE WORK FROM RECORDSET
report.Database.SetDataSource rs 'LINK REPORT TO RECORDSET
CRViewer.ReportSource = report 'LINK VIEWER TO REPORT
CRViewer.ViewReport 'SHOW REPORT
Do While CRViewer.IsBusy 'ZOOM METHOD DOES NOT WORK WHILE
DoEvents 'REPORT IS LOADING, SO WE MUST PAUSE
Loop 'WHILE REPORT LOADS.
CRViewer.Zoom 100
rs.Close 'ALL BELOW HERE IS CLEANUP
conn.Close
Set conn = Nothing
Set crystal = Nothing
Set report = Nothing
End Sub
Private Sub Form_Resize() 'MAKE SURE REPORT FILLS FORM
CRViewer.Top = 0 'WHEN FORM IS RESIZED
CRViewer.Left = 0
CRViewer.Height = ScaleHeight
CRViewer.Width = ScaleWidth
Edited by - worldapart on 5/17/2006 1:55:04 AM
Pass A Value To Crystal Report 8
Hi,
This is a question regarding Crystal Report 8
i) There's a vb form with a textbox. User would input, say "ABC" in the textbox. Then, I want to pass the "ABC" into my Crystal Report details field.
Eg:
User only have to input the "ABC" once while the name would be retrieve from the database.
Report generated:
Name Class
Alex ABC
James ABC
Sandy ABC
Can somebody help ?
Pls advice and thanks in advance
pcPirate
Pass Value To Crystal Report
hi,
i've have a table (Access 97) that contain customer information and i need to display certain customer details.
in VB 6.0 form, a text box that allow me to type a customer code and a command button that use to show the report(crystal report 9)
how i pass the text box value to the report when i click the command button ?????? plz help................
thanks
Pass Formula From VB To Crystal Report
Can anyone explain to me how I can pass a formula from a VB6 application to Crystal Reports?
I want to select specific data from the database based off of a variable in vb.
For example: In the VB app, to create the recordset, I would say
SQL = Select * from tablename where dbField = '" & txtRegion & "';"
I only want to pass the results in the recordset to CR or pass a formula where Crystal Reports would give me the same info.
Thanks,
Sam
Pass Value From Vb Form To Crystal Report 9
Hi folks,
My apology if I have posted this in a wrong forum, which may be appropriately moved.
My post is this, I have a form in VB which allows the user to select a region from the combo. Based on the region selected the crystal report should display records [Acs 2003] for that relevant region. Iam just testing waters in CR so please be kind enough post the code & steps how to perform it or better a sample proj. I know there are somethings like parameterfield, formula field, variables in CR but I donot know how to use them.
Thanks in advance.
How Do I Pass A Crystal Report As Argument?
Im trying to pass a report to a function. If I define the argument as being CRAXDRT.Report none of the objects I have on my form are referenced anymore. Using Variant or Object does not work either. I can't actually use the name of the report either. Here's what I want to do:
VB Code:
Private Sub OneSub (param as Integer) Dim InvM1 as MyCRReport1Dim InvM2 as MyCRReport2Dim InvM3 as MyCRReport3 Select Case paramCase 0Call MyFunction(InvM1)Case 2Call MyFunction(InvM2)Case 3Call MyFunction(InvM3)End SelectEnd Sub Public Function MyFunction(InvMReport As ??) End Function
Any idea?
To Pass Parameter From Vb6 To Crystal Report
Hello Friends,
My problem is I want to accept value from user which I am nt storing in databasse. I am using inputbox to get value from user and then I want to print the same value in the crystal report. I am not using crystal report viewer, but I've used crstyal report's ocx and from there i am opening report by using printreport method of the crystal report's ocx control. plz help me.
below is my code which i m using to print report
VB Code:
With crStudList .Connect = strConn .ReportFileName = App.Path & "
eportsStudentList.rpt" .ReportTitle = "Student List" .WindowTitle = "Student List" '.SelectionFormula = "{tblStudent.RegistrationDate}>= DateValue (" & dtpFrom.Value & ") and {tblStudent.RegistrationDate}<= DateValue(" & dtpTo.Value & ")" .SelectionFormula = "{tblStudent.RegistrationDate}>=#" & Format(dStartDate, "dd/MM/yyyy") & "# and {tblStudent.RegistrationDate}<=#" & dEndDate & "#" .Destination = crptToPrinter .PrintReport End With
where crStudList the name of ocx control of crystal report
thanks
Pass Two Recordsets To Crystal Report
I have my code working fine for one ADO recordset, but I added
another query to the report and now I need to pass a second
recordset to the report before it gets created in vb. Here is my
code for one recordset. I thought if I changed the parameters I
could pass the second one but it didn't work.
VB Code:
oReport.Database.SetDataSource oRs1, 3, 1oReport.Database.SetDataSource oRs2, 3, 2
The second parameter of 3 is the datatag and the third is the tablenumber.
Any ideas on what I am doing wrong?
Thanks in advance for any assistance.
How I Can Pass ADO RecordSet To Crystal Report?
How I Can Pass ADO RecordSet to Crystal report?
IHave Crystal Report. Now I Want To Set Recordset as datasource, so I can put the records in crystal report which is in my record set? Please Give Me Brief example
How VB Pass Parameter To Crystal Report
how to pass Parameter to Seagate Crystal report by VB?
I want to pass One or More parameter to Crystal report to meet a certain critera
like i want to select some record by my application given date so report should be contains only those record sort by given date.
Fwd: How To Pass ADO Recordset To Crystal Report 7.2
---------Forwarded message---------
Date : Mon 04 Aug 10:40:24 2003
From : syed
Subject : How to Pass ADO Recordset to Crystal Report 7.2
Dear Friends
i am having problem with Hindi data. in the hindi data contains single qoutes in the string. so i was replace the string to "---" and when i am retriving this into vb again i convert into single quoutes through replace command in vb. but there is no facility in crystal report 7.2 for find andreplace the string through formula. so please suggest me its very urjent.
otherwise if i can pass ADO recordset to crystal report is there is possible then please tell me how it could be possible please
syed
How To Pass ADO Recordset To Crystal Report 7.2
Dear Friends
i am having problem with Hindi data. in the hindi data contains single qoutes in the string. so i was replace the string to "---" and when i am retriving this into vb again i convert into single quoutes through replace command in vb. but there is no facility in crystal report 7.2 for find andreplace the string through formula. so please suggest me its very urjent.
otherwise if i can pass ADO recordset to crystal report is there is possible then please tell me how it could be possible please
syed
........
S.M. Syed Sherfudeen
Scientific/Technical Assistant-'B' ,
NIC, Madhya Pradesh State Unit,
Computer Centre 'C' Wing Basement
Vindhyachal Bhavan,
Bhopal - 460 004,
Madhya Pradesh.
Ph. 0755-551265 ext.112
How To Pass A Parameter In Vb Using Crystal Report 9.0
hi,
i'm using vb 6.0 , access 98 & cr 9.0. plz help me how to pass a parameter using vb 6.0 .
in run time.
regards
chitkrish
vikramjb : post moved to the reporting section. Please post in the approriate forums.
Edited by - vikramjb on 12/22/2005 2:08:48 AM
How To Pass Recordset To Crystal Report From Vb
Hi Guys,
I am trying to pass recordset to Crystal Report 8.5 from VB 6.0.
I have created an Crystal Report file by using the Create New Connection option. This is done in my system.
When I install my project at the client machine, I want the report to take the new connection, i.e the System name and Database will change.
I am giving the code which I am currently using.
Set oReport = oApplication.OpenReport(App.Path & "ReportProjectSheet.rpt")
Me.Caption = mvarReportName
Set rstReport = oProject.GetProjectDetail(me.txtProjectNo.Text)
oReport.Database.Tables(1).SetDataSource rstReport, 3
The problem i am facing is that either the connection is not changing or report is not displaying.
Please it is very urgent....
How To Pass Values To Crystal Report From Vb
hai hai hai
I am using crystal report 7.I was just linking the table at desing time and displaying the values.Now what i need is i just have to know how to pass query or records from vb to crystal reports at runtime.I serached for it in this site but i cant find one .So can anybody help me hwo to know abt it
Nanree(Thanks In Our Language)
Ramya
Can I Pass Querry To Crystal Report?
Hi friends,
I am using Crystal Reports 4.6.1.0 and am new to it....
I want to generate a report using data from two tables!
Can Anybody explain me how should I pass a querry to Crystal report through VB 6!
Thanx in advance!
Save Log In In Crystal Report/ Pass From VB
I have made a report program using VB6 and crystal report 9.
When I run the program, it got an error saying that the log on to the database fail. However, I cannot use trust connection as the database has created a user login for access it. How can I pass this login (user name + password) from VB to crystal report to log on to the server?
How To Pass Parameters From VB6 To Crystal Report 8?
Good day everybody!
just like to find out whether is it possible for me to pass a parameter from Visual Basic 6 to Crystal Report 8 Professional version??
is it true that only the developer version of CR8 can do passing of parameters??
thanks for all your time!!
How To Pass Argument To Crystal Report Pro
Hi
I wanna know if Crystal Report Pro (came with VB 6) can receive Argument/Variable passed from VB ? I use the Crystal Report ActiveX Control to invoke the Preview Window of Report when the user press a command button. Seemingly we can't pass any Argument/variable to Crystal Report. I intend to preserve 2 fields (Not from database) in the report for the display of user keyin value at run-time. Besides, I wanna display the name of the Database from which the report retrived in the crystal report. How to do it, please ? Tnanx.
Pass Parameters In VB6 To Crystal Report 8.5
Hi Babu,
I hava a problem about pass a parameter in VB6 to Crystal Report 8.5 that need your helping. When I add Crystal Report 8.5 control in VB6 then I got a CrystalReport1 and Form1 . I want to design a form in VB incluses 2 textbox that allow user type StartDay and EndDay. User can click Preview button to view report. Can I type code in VB form or Form1? How do I pass parameter?Please give me a detail code.Thank you for your helping.
How To Pass Data To Crystal Report
Hi:
Here I have a simple question. In a crystal, how can I pass data to it , but not from Database. In the form I can create a text field then pass to it. In Datareport, I can create a label then pass to it.
But How can I do it in Crystal report. Should I create a formula first ??
In anybody know about it or have good tutorial about how to use Crystal report. It will be very helpful. Millions of thanks in Advance!!
Yeung
wky086
How To Pass SQL Command To Crystal Report
Hi;
here have a simpe question of crystal report.
IN adodc , I can pass SQL command by the follow command:
Adodc1.Datasource = "select * from Emp where SN = '+EmployNumber +'"
But how can i pass it to Crystal report.
I use CrystalReport1.Datasource = "select * from Emp where SN = '+EmployNumber +'" It comes with error message " need object"
If anybody know how to do it. Please help me.
millions of thanks in advance!!
wky086
How Do I Pass A Parameter Range To A Crystal Report (v8.5)?
Hi
I am using VB6 and Crystal 8.5 (the database is only compatible with this version of Crystal.
I need to pass a parameter range to my VB code, the parameter works fine in Crystal, but I cannot work out how to pass the parameter range in code.
All help very welcome!
Thanks
Blinking Nora
How To Pass Parameter Using Crystal Report Viewer
hi!
I have a report to which i am passing a parameter value custid
i was earlier using just the rdc control and showing the report and passing the parameter by
CrystalReport1.ParameterFields(0) = "custid;" & Combo2.Text & ";true"
now when i use crystal viewer using the foll. code
Dim app1 As CRAXDRT.Application
Dim rep As CRAXDRT.Report
Private Sub Form_Load()
Set app1 = New CRAXDRT.Application
Set rep = app1.OpenReport("c:sales1.rpt", 1)
With Form1
.Show
.CRViewer1.ReportSource = rep
.CRViewer1.ViewReport
End With
End Sub
the report prompts for a parameter
How can i pass the parameter to the report within this code so that the viewer does not prompt for any input
thanks in advance
Mukul
Form To Pass Parameters To Crystal Report
I have a form that works just fine passing parameters to the Crystal Report. However I have one parameter than needs to be 1/1/2002 (the 2002 needs to change based on current year ie in 2003 it should be 1/1/2003 without any user input. I use this for the start date in a year to date part of the report. Any suggestions how I can achieve this ?
Thanks for any and all help
Pass BLOB Parameter To Crystal Report
I would like to display the image from the local file system where I can pass the path or the whole image (in BLOB fieldType). But I found that I cannot set the parameter field type into BLOB (only can set String, Date, Time, etc). What can I do? I found that it works when the photo is stored in database only. Is there anybody can solve this problem?
How To Pass SQL Query To Crystal Report : Pl Help It Is Very Urgent
Following is the code I am passing to Crystal Report. I am using CR Ver
4.6
I have created Report with Tmp_Data table and table is empty .
Now I want data from OP_BAL table
for Ast_Code = '10060010001' .
Csql = "Select * from OP_BAL where Ast_Code = '10060010001'"
CrystalReport1.Connect = Gc.cnn &&
Connection to Access 97.
CrystalReport1.ReportFileName = "C:VBAssetSystemR_master.rpt"
CrystalReport1.WindowLeft = 0
CrystalReport1.WindowState = crptMaximized
CrystalReport1.SQLQuery = (Csql)
CrystalReport1.Action = 1
With advance Thanks
DVK
Pass In Crystal Report Parameters To Export
Hello,
I am having trouble passing in parameters to a crystal report in a vb6 app.
I have gotten this far but I am unsure of the syntax for inserting the parameter
Dim appl As New CRAXDRT.Application
Dim rep As CRAXDRT.report
Dim report As String
report = "t:invreportsMaruyoshiInvoice.rpt"
Set rep = appl.OpenReport(report, 1)
rep.EnableParameterPrompting = False
rep.ExportOptions.DiskFileName = "c: emppdf_report.pdf"
rep.ExportOptions.DestinationType = crEDTDiskFile
rep.ExportOptions.FormatType = crEFTPortableDocFormat
rep.Export False
But I need to pass in a parameter to the report. The report parameter is @invno
and the value will come from a textbox.
Any help will be greatly appreciated
How To Pass Image Path To Crystal Report 8 Through VB6
I am working on large-scale project entitled as MIS (Marketing information System). As I told you that I am using Vb 6 as front end, Ms Access as back end and Crystal report 8 as reporting tool.
1) In the project it is required to save dealer’s photo, and it should be shown in individual dealer’s detail report, which will include his/her image. I had taken Common dialog box control to select image and display it in image control.
2) The size of database is very large then, which will be useful from the following?
i. to store image to database?
(But it makes database larger in size which leads to slower access)
ii. Saving path of image in database
To keep database safe I want to try the second option first. Instead coding directly into project, I want test the logic into small program first. As we know that by use of common dialog control we can select image and show it in image control. Also same path can be stored in database. Also we can retrieve the path from database and show it image control.
Until here all things are ok. Now problem is that how to show the image in crystal report. Usually we pass the fields directly to crystal report by sending sql-query to it.
Edited by - Skiran on 11/3/2006 11:03:32 PM
|