Hi..

I have a table: PROFESSOR in ms access, that has 2 fields: "Name" and "Location". The table has 10 records.
And i have made a vb form with a combo box that will show a list of available locations from the database table, when it is dropped down.

So, the end user will select a location from the cbo on the form and i want that to be used as the basis of the report to be generated.

QUESTION:
========
1. How do i pass the value (i.e the location selected by the user) to the report designed ?

2. If i want the report to be generated based on the user's selection of "Location", then do i use the standard wizard which is popped up when the Crystal Report 11 designer module is added from the project exploere in vb6 ??

Pls answer the questions in order of them stated above.
Help will be surely appreciated...:cool:

some1 clear my doubts & issues ..please....

Hi..

I have a table: PROFESSOR in ms access, that has 2 fields: "Name" and "Location". The table has 10 records.
And i have made a vb form with a combo box that will show a list of available locations from the database table, when it is dropped down.

So, the end user will select a location from the cbo on the form and i want that to be used as the basis of the report to be generated.

QUESTION:
========
1. How do i pass the value (i.e the location selected by the user) to the report designed ?

2. If i want the report to be generated based on the user's selection of "Location", then do i use the standard wizard which is popped up when the Crystal Report 11 designer module is added from the project exploere in vb6 ??

Pls answer the questions in order of them stated above.
Help will be surely appreciated...:cool:

#1 You pass off your parameter value as a formula in the RecordSelection property.

#2 Don't design the report with a propmt for the parameter. You're going to pass off any record selection criteria via the RecordSelection property. You're trying to mix two techniques that don't mix.

Hi..and thanks for ur reply
I have a new situation here...with CR 11 and VB6

==============================================
CRYSTAL REPORT 11 Report Designer part
==============================================
I have designed my report in Crystal Report 11 product using the Report Designer. And i have NOT used the standard wizard that pops up for designing the reports.

STEP 1:
I have opened a blank report and used the Database Expert tool for connecting my MS ACCESS (.MDB) database file and also selected the tables that would be used in report generation.

STEP 2:
Dragged & dropped the fields from the Feild Explorer's database tables and placed it on the Report Designer window. Like this i have designed my reports.

STEP 3: Saved the report as .RPT extension


==============================================
Visual Basic 6 Code View part
==============================================
STEP 1:
In VB6 code, i have used the ".SQLQueryString" property

SYNTAX: ".SQLQueryString <string_variable>"
NOTE: the string variable contains the SQL query statement.

STEP 2:
setting report location:
SYNTAX: ".OpenReport(App.Path & "\ABC.rpt")"

STEP 3:
setting .MDB database location:
SYNTAX: ".Database.SetDataSource (App.Path & "\XYZ.mdb")"

STEP 4: There is some other code also. Main thing is that now my reports are being generated perfectly using the user selected item from a combo box's dropdownlist on a vb form window.


QUESTIONS:
========
1. I will be adding the CR11 Merge Modules to my setup builder, as given on the Business Objects site.
Now, if i do the things as stated above. Then will i be able to deploy & view my reports at the client's end/end-user's computer without
installing the Crystal Report 11 product there ??

Hi..and thanks for ur reply
I have a new situation here...with CR 11 and VB6

==============================================
CRYSTAL REPORT 11 Report Designer part
==============================================
I have designed my report in Crystal Report 11 product using the Report Designer. And i have NOT used the standard wizard that pops up for designing the reports.

STEP 1:
I have opened a blank report and used the Database Expert tool for connecting my MS ACCESS (.MDB) database file and also selected the tables that would be used in report generation.

STEP 2:
Dragged & dropped the fields from the Feild Explorer's database tables and placed it on the Report Designer window. Like this i have designed my reports.

STEP 3: Saved the report as .RPT extension


==============================================
Visual Basic 6 Code View part
==============================================
STEP 1:
In VB6 code, i have used the ".SQLQueryString" property

SYNTAX: ".SQLQueryString <string_variable>"
NOTE: the string variable contains the SQL query statement.

STEP 2:
setting report location:
SYNTAX: ".OpenReport(App.Path & "\ABC.rpt")"

STEP 3:
setting .MDB database location:
SYNTAX: ".Database.SetDataSource (App.Path & "\XYZ.mdb")"

STEP 4: There is some other code also. Main thing is that now my reports are being generated perfectly using the user selected item from a combo box's dropdownlist on a vb form window.


QUESTIONS:
========
1. I will be adding the CR11 Merge Modules to my setup builder, as given on the Business Objects site.
Now, if i do the things as stated above. Then will i be able to deploy & view my reports at the client's end/end-user's computer without
installing the Crystal Report 11 product there ??

Awaiting reply...

Hi..and thanks for ur reply
I have a new situation here...with CR 11 and VB6

==============================================
CRYSTAL REPORT 11 Report Designer part
==============================================
I have designed my report in Crystal Report 11 product using the Report Designer. And i have NOT used the standard wizard that pops up for designing the reports.

STEP 1:
I have opened a blank report and used the Database Expert tool for connecting my MS ACCESS (.MDB) database file and also selected the tables that would be used in report generation.

STEP 2:
Dragged & dropped the fields from the Feild Explorer's database tables and placed it on the Report Designer window. Like this i have designed my reports.

STEP 3: Saved the report as .RPT extension


==============================================
Visual Basic 6 Code View part
==============================================
STEP 1:
In VB6 code, i have used the ".SQLQueryString" property

SYNTAX: ".SQLQueryString <string_variable>"
NOTE: the string variable contains the SQL query statement.

STEP 2:
setting report location:
SYNTAX: ".OpenReport(App.Path & "\ABC.rpt")"

STEP 3:
setting .MDB database location:
SYNTAX: ".Database.SetDataSource (App.Path & "\XYZ.mdb")"

STEP 4: There is some other code also. Main thing is that now my reports are being generated perfectly using the user selected item from a combo box's dropdownlist on a vb form window.


QUESTIONS:
========
1. I will be adding the CR11 Merge Modules to my setup builder, as given on the Business Objects site.
Now, if i do the things as stated above. Then will i be able to deploy & view my reports at the client's end/end-user's computer without
installing the Crystal Report 11 product there ??

Awaiting reply...

That's the whole idea, isn't it? Run Time support for Crystal is free. You paid for crystal, now you get to distribute your applications with crystal reports as well. Happy hunting. Henry

I still didn't get u. R u asking me the question that whether it is correct or not....or are u clearly saying that the STEPS i have mentioned are correct. And henc ei can now focus on deploymnt part


That's the whole idea, isn't it? Run Time support for Crystal is free. You paid for crystal, now you get to distribute your applications with crystal reports as well. Happy hunting. Henry

I still didn't get u. R u asking me the question that whether it is correct or not....or are u clearly saying that the STEPS i have mentioned are correct. And henc ei can now focus on deploymnt part

You got it right. Work on your deployment.

I gr8tly appreciated ur help Henry buddy,

OK ..thank u so much for ur assistance. So i am confident enough that i can go ahead with the deployment stuff.

But....

Before that i have a particular report to make which refers to this new issue: (2nd topic)

"Crystal Report 11 and Visual Basic 6.0 sql query...."

Please read it and help me....Thanks in advance

I gr8tly appreciated ur help Henry buddy,

OK ..thank u so much for ur assistance. So i am confident enough that i can go ahead with the deployment stuff.

But....

Before that i have a particular report to make which refers to this new issue: (2nd topic)

"Crystal Report 11 and Visual Basic 6.0 sql query...."

Please read it and help me....Thanks in advance

I CAN'T FIND YOUR OTHER POST.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.