473,388 Members | 1,326 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,388 software developers and data experts.

How To Export an ACCESS Report With Filte

Hey Friends

I need to export an Access Report using a filter.

I am using the method OutputTo

m_pDoCmd->OutputTo(
3, // asOutputReport
COleVariant(strReportName), // <report name>
COleVariant(_T("HTML (*.html)")), // acFormatHTML
COleVariant(_T(strHtmlFileName)), // <report name> + .html
COleVariant((short)0, VT_I2), // autostart ?
COleVariant(_T("")));

I found that there is another method

ie

OpenReport which allows to apply a filter but it do not give me an object of
Access.Report

Is there any way so that we can combine and Export a Report with a filter ?

Plz Help

How To Export an ACCESS Report With Filter
Nov 12 '05 #1
2 8092
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Syntax of Jet 3.6 & 4 of OpenReport:

OpenReport(ReportName, View, FilterName, WhereCondition, WindowMode,
OpenArgs)

Put the Filter in the WhereCondition parameter, e.g.:

State='MA'

Like a WHERE clause in SQL.

But, this won't export the report to an HTML page. If I were
exporting a report to an HTML page & wanted to filter the data I'd put
some VBA code in the report's OnOpen event procedure that would "ask"
for filter criteria from the user, or pick up the criteria from some
form/table/query.

MGFoster:::mgf
Oakland, CA (USA)

-----BEGIN PGP SIGNATURE-----
Version: PGP for Personal Privacy 5.0
Charset: noconv

iQA/AwUBP8GdmYechKqOuFEgEQKxqgCfW4Da1yzx3iy2yLO+fl/0ev47MRAAoOTz
3VDAq8ZP/5lhwMnwQjQBx6Oq
=kmc/
-----END PGP SIGNATURE-----

Vikrant wrote:
Hey Friends

I need to export an Access Report using a filter.

I am using the method OutputTo

m_pDoCmd->OutputTo(
3, // asOutputReport
COleVariant(strReportName), // <report name>
COleVariant(_T("HTML (*.html)")), // acFormatHTML
COleVariant(_T(strHtmlFileName)), // <report name> + .html
COleVariant((short)0, VT_I2), // autostart ?
COleVariant(_T("")));

I found that there is another method

ie

OpenReport which allows to apply a filter but it do not give me an object of
Access.Report

Is there any way so that we can combine and Export a Report with a filter ?

Plz Help

How To Export an ACCESS Report With Filter


Nov 12 '05 #2
Thanks
You are Perfectly right
Thanks

MGFoster <me@privacy.com> wrote in message news:<c4*******************@newsread1.news.pas.ear thlink.net>...
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Syntax of Jet 3.6 & 4 of OpenReport:

OpenReport(ReportName, View, FilterName, WhereCondition, WindowMode,
OpenArgs)

Put the Filter in the WhereCondition parameter, e.g.:

State='MA'

Like a WHERE clause in SQL.

But, this won't export the report to an HTML page. If I were
exporting a report to an HTML page & wanted to filter the data I'd put
some VBA code in the report's OnOpen event procedure that would "ask"
for filter criteria from the user, or pick up the criteria from some
form/table/query.

MGFoster:::mgf
Oakland, CA (USA)

-----BEGIN PGP SIGNATURE-----
Version: PGP for Personal Privacy 5.0
Charset: noconv

iQA/AwUBP8GdmYechKqOuFEgEQKxqgCfW4Da1yzx3iy2yLO+fl/0ev47MRAAoOTz
3VDAq8ZP/5lhwMnwQjQBx6Oq
=kmc/
-----END PGP SIGNATURE-----

Vikrant wrote:
Hey Friends

I need to export an Access Report using a filter.

I am using the method OutputTo

m_pDoCmd->OutputTo(
3, // asOutputReport
COleVariant(strReportName), // <report name>
COleVariant(_T("HTML (*.html)")), // acFormatHTML
COleVariant(_T(strHtmlFileName)), // <report name> + .html
COleVariant((short)0, VT_I2), // autostart ?
COleVariant(_T("")));

I found that there is another method

ie

OpenReport which allows to apply a filter but it do not give me an object of
Access.Report

Is there any way so that we can combine and Export a Report with a filter ?

Plz Help

How To Export an ACCESS Report With Filter

Nov 12 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

16
by: David Lauberts | last post by:
Hi Wonder if someone has some words of wisdom. I have a access 2002 form that contains 2 graph objects that overlay each other and would like to export them as a JPEG to use in a presentation....
7
by: Pat | last post by:
I would like to send the Print Preview of a MS Access form to a Snapshot file. The form contains an OLE graph. BACKGROUND A snapshot of a report is possible. If I could I would use a report to...
6
by: Robin Cushman | last post by:
Hi all, I need some help -- I'm working with an A2K database, using DAO, and am trying to read records into a Crystal Report and then export it to a folder on our network as an Excel...
3
by: Jorge Cecílio | last post by:
Hi! I would like to export some MS-Access reports output to pdf. However, the only possibility offered by Access (afaik) for me to export formatted output is snp (snapshot) (I use MS-Office...
2
by: jpodesta | last post by:
I am working on a trade processing project for my company. I would like to export a report directly to .csv format. I have looked all over in the groups for a way to do this. Appearently something...
0
by: Leonard Danao | last post by:
Anyone have any ideas as to why this is happenning. There are no other versions of Crystal installed aside from the one that came with vs2003 enterprise. the error happens when the...
0
by: Henry | last post by:
I have written an ASP/VB.Net application via VS 2003 (Crystal V9) that uses MS Access 2000 as its database. I can export reports that have no linked sub reports for printing. However, I'm unable...
1
by: ellenh | last post by:
I have read postings on the similar subject including the posting from 2003 shown below. This process works fine to display a single page snapshot report in PowerPoint. I need to display...
3
by: yovation | last post by:
Hi, I have a 3 table database. 1 parent 1 child 1 child of child I would like to get the data into excel as 1 sheet (similar to a grouped report).
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.