Report Header Printing Error

Hello,

       I am having a problem with the OnPrint event handler in my
report header section.  My code is below:

Private Sub ReportHeader_Print(Cancel As Integer, PrintCount As
Integer)
  Dim ClientName As String

  ClientName = CStr(Me.BusName)
  .
  .
End Sub

I am getting runtime error 2465 - Can't find the field BusName
referred to in your expression.

When I type Me. and wait for the list of properties and methods,
BusName is on the list and it compile with no errors.

What am I doing wrong?   Is the problem because I am attempting to
access this value while in the ReportHeader and not in the detail
section?

J

0
Joe
10/8/2007 6:15:19 AM
access 16762 articles. 2 followers. Follow

1 Replies
476 Views

Similar Articles

[PageSpeed] 3

Try using this instead:

ClientName = Cstr(Me!BusName)

using the BANG operator to refer to the FIELD name and not the control name.
-- 

Bob Larson
Super Moderator -  Access World Forums
Access VIP on Utter Access
____________________________________
Access 2000, 2003, 2007, SQL Server 2000, Crystal Rpts 10/XI, VB6
WinXP, Vista


"Joe" wrote:

> Hello,
> 
>        I am having a problem with the OnPrint event handler in my
> report header section.  My code is below:
> 
> Private Sub ReportHeader_Print(Cancel As Integer, PrintCount As
> Integer)
>   Dim ClientName As String
> 
>   ClientName = CStr(Me.BusName)
>   .
>   .
> End Sub
> 
> I am getting runtime error 2465 - Can't find the field BusName
> referred to in your expression.
> 
> When I type Me. and wait for the list of properties and methods,
> BusName is on the list and it compile with no errors.
> 
> What am I doing wrong?   Is the problem because I am attempting to
> access this value while in the ReportHeader and not in the detail
> section?
> 
> J
> 
> 
0
Utf
10/8/2007 6:26:01 AM
Reply:

Similar Artilces:

Printing reprot from a form for the record viewed
I would like to print a report (sort of an invoice) from a form where i am entering the final data for the invoice. but the report is generated for the entire table. for time being i am printing the form. but the actual report must have a different format and some more additional informations. So i want help to print the report only for the record viewed in the form and that i should be able to give the print commond from the form itself through the command button.thanks Try this link on "How To Print A Single Record from a Microsoft Access Form into a Report"http://www.databasedev.c...

Access "Write Conflict" Error -- record changed by another user
A table with 2 fields in which the data are correlated (but not coupled) are populated by ComboBoxes with sources from a separate table with the correlated information in the same records. Specifically, Company Name and Stock symbol. The form used to enter and edit information in the master table allows the selection of unrelated Company Name and Stock Symbol. Using a RecordSet, ToDo Loop, and an UPDATE query, I have "sort of" accomplished the job. Changing the selection of the Company Name generates the above error message. Clicking the "Drop Changes" button pr...

Need more Reports
GP does not provide detailed reports itself. reports such as sales by customer, best selling items, inventory valuation and so... Also the reports that it provides are not in good design and format (not useful). Is there any report package from third party that can be purchased or there is any other solution to get in depth reports and analysis? Sure Since Great Plains cannot possibly be all things to all people, get to know the layout of the Great Plains database and where all of the data is stored. Then roll your own reports using the native Report Writer, SQL Reporting Services, Cryst...

Customized CRM Report with Reporting Services
I have written a customized report in Reporting Services using SQL Server 2005. I need to use a date as one of my query parameters. I am using three parameters, one being UserName, 2) Customer, and 3) Date. I want the report to filter on the username, then customer, then date in order to provide a specific report for 1 customer and 1 date only. I changed the select for the date to: Select Distinct Convert (varchar, new_tripdate,101) in order to cut the time out of view. When I run the report, I first select the username, then I am provided with a list of customers for that user, but the...

Sales Report #3
Hi All Is there any sales report to show detailes like Store-total Sales-Cash Sales-Credit-Span-customer- Change Item/customer -Discount. Cash Sales-Credit-Span: is tender type. Change Item/customer : like one customer change item and total amount for backing item 200$ (e.g). Is there any one he have report like that? Thanks for help M. Own ...

W-2 Tax Reporting Figures Not Accurate
I use Money to monitor all of my financial situations. This year, I decided to see how it did with supplying tax information. "Poorly" is the answer. I would expect the 'Tax Line Manager / W-2 / Your salary' and the 'Tax Software Report / W-2 / Your salary' to show a figure that matches my 'W-2 / Box 1' statement information. They do not. The reason is that the 'W-2 / Box 1' statement figure has pre-tax retirement contributions subtracted from the wages. When I enter my paycheck information into Money, I categorize retirement contributions no...

Excel 2007 error "some chart types cannot be combined with other chart types. Select a different chart types"
This is a multi-part message in MIME format. ------=_NextPart_000_000E_01C75210.F27A6390 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Hi, I have installed Excel 2007, and I can't create any chart, the message=20 "Some chart types cannot be combined with other chart types. Select a = different chart types" keeps poping up, are there any settings that i have miss out? thank you regards kh ------=_NextPart_000_000E_01C75210.F27A6390 Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quo...

Blank networth reports
Hi, Whenever I run the net worth reports, I get the hourglass for a second or two, then loading but it never renders. Other reports (Transactions, loans, cap gains, etc.) run fine. I converted from Quicken. In microsoft.public.money, <anonymous@discussions.microsoft.com> wrote: >Hi, Whenever I run the net worth reports, I get the >hourglass for a second or two, then loading but it never >renders. Other reports (Transactions, loans, cap gains, >etc.) run fine. Perhaps customize the report to a different time frame, and then reset the report? Tried all dates. >...

Error searching an additional mailbox
Greetings, I have several users, who, in addition to their own mailbox, mount a second mailbox for storage of certain emails. Recently, several of these users have tried to do searchs on one of the folders in that mailbox and receive a dialog box stating There are too many Find Public Folders dialogs open. You must close them in order to use the Advanced Find. Do you want to close them now? These are all Outlook 2002 users running against an Exchane 5.5 server. Anyone seen this problem before? K ...

Installing CRM 1.2 error
I am installing CRM 1.2 on a SBS2003 vertual server with SQL2005 using an existing database. I get an error after selecting the existing database: Microsoft CRM Setup could not finr a valid organisation on the specified database. You need to have at least one organisation before installing Microsoft CRM. Microsoft CRM 1.2 does not work with SQL Server 2005. SQL Server 2005 is supported for Microsoft CRM 3.0 Frank Lee Workopia, Inc. http://www.workopia.com/Links.htm "Kryton" wrote: > I am installing CRM 1.2 on a SBS2003 vertual server with SQL2005 using an > existing...

eXtender SOP Reports
Hello. We are using a modified version of the eXtender SOP Blank Packing Slip Form. It was modified years ago by an outside consultant. For the first time, we need to use the "Print Customer Item" option, and notice this does not work on our modified report (it works fine on the non-modified version of the same eXtender report). I am being a little lazy here and hoping someone can tell me how to turn this "feature" off or on in modifier :) Thank you, in advance. M. ...

Keeping Page Title but not printing it
We are using certain pages as formal letters that need to be printed out. I would like to have the page title to organize, but when the page prints, I do not want the page Title to print. I can't image there is no way to do that... Thoughts? -- dwayner79 > We are using certain pages as formal letters that need to be printed > out. I would like to have the page title to organize, but when the > page prints, I do not want the page Title to print. I can't image > there is no way to do that... NO, there is no way to achieve what you want. A workaro...

Reports are not being shown MM07
Hi, pals! When I try to see the Monthly Reports (any month) in MM07, I get a popup saying: ------------------------------------------------------------- "File Download Do you want to open or save this file? Name: moneygen.htm Type: Firefox Document, 1,03KB From: C:\Users\yadayada [open] [Save] [Cancel] -------------------------------------------------------------- If I click OPEN, it opens the report in Firefox (!), while the Money windows says: "Navigation to the webpage was canceled. What you can try: - Retype the address" Anyone has seen it before? How to make Money o...

#Name? prints on a report when date shows up on preview
Access 2003 SP 2 Windows XP SP 2 I have created a report (rptFuelmanByForeman) that is based on a Query (qryFuelmanByForeman). I have created a form to select (or enter) a date range that then filters the report based on that date range and populates transactions between those dates. I have created two text boxes on the report that display the start date (txtStartDT) and end date (txtEndDT) entered in the date select form. The control source on the date boxes on the report is "=Forms.frmFuelmanByForeman.txtEndDate" & "...txtStartDate". In Preview mode, the dates d...

Saving Reports
Hi, Is there a simple way to save advanced reports for use on a monthly or weekly basis. I can produce a dynamic report but can't find a way to save this as a template so it can be run on a regular basis. Having to select all the criterea each time you want to run the report is a little annoying, I must be missing something here...? Thanks Nik Once you select all the required criteria for your search, you could click on the 'Save As' button to save the search results with some specific names. For other users to view this search result, go to the 'Saved Views' tab, ...

Printing in excel #6
I am working on a bid sheet in excel. The problem I am having is there are parts of the sheet I may or may not want to print. If one section requires, say 4 each of three items, I will want to print that, but if another sections requires no items in the selection list, I don't want to print that. This may happen 5 times a day, I don't want to set teh print area each time. Some of these options are side by side and not above or below each other on the spread sheet. I was looking for something that says, "if = 0", do not print. Thanks One way would be to create for ...

In a report, is there any way a record will change color if it's different from the previous record
Hi, I am working on a project where I need to color code the report so it will distinguish if the previous record is different from the current record. Because the record will have many similar record, so I am trying to group the record so it's easier to look. In a report, is there any way a record will change color if it's different from the previous record. Thanks for your help. richiecheng@gmail.com wrote: >Hi, I am working on a project where I need to color code the report so >it will distinguish if the previous record is different from the >current record. Because...

Launching Reports from the Submit Order Button in 4.0
My client has several retail locations and they are using CRM in conjunction with their POS system. Therefore, CRM Orders has received a lot of customization to make it as slim, trim, and "Mouse-Click-Free" as possible. In the spirit of reducing even more mouse clicks, they have asked if we could launch a custom report (Basically the Order Report, renamed "Order Receipt") when the "Submit Order" button (re-named by Scribe's CRM to GP Integration) is clicked. The Receipt would render and then be printed for the cusomter. The report is context sensitive...

To view, specifically Units in one report
I have report with a Reporting Tree (9 Unit), when the report is generated, I select only two unit, but I need that the drill down show one report with these unit only If you want multiple units in a single report you will need to use the column layout with unit restrictions on multiple columns Leslie "Pedro" wrote: > I have report with a Reporting Tree (9 Unit), when the report is generated, I > select only two unit, but I need that the drill down show one report with > these unit only Leslie; Each Column layout have the unit restrictions Thanks :-) "Lesl...

small business reports ...
Dear all Hope this is the right group. Can Mone 2002 create a Trial Balance report? Is there a list of reports availabe in 2006 (Small Business edition) that is accessible somewhere, as I have not been able to locate any such list, and is a Trial Balance one of them. While I am happy using Money and have been for some time, when it comes to reviewing my files the person doing so is a certified accountant and Quick Books user and would like me to convert, I have continued to resist however he continues to press for these accounting reports. Can Money 2002 and or 2006 Small Business ...

Reporting Error ==> very urgent
Hi All, We have installed CRM 4.0 for our organization. We ahd our CRM and SQL on different servers and decided to use Mcirosoft Outlook client. The problem is when we try to generate reports we are unable to get any reports. We always getting an error stating "REPORTING ERROR REPORT CANT BE DISPLAYED" it also stats that to contact Microsoft for details. We are struck with this error for 3 days and the issue is bulging in alarming propositions. Kindly advice me to resolve and overcome this issue. Thanks a lot in advance. elays - ...

format the "date" button for a header
I need to insert a date in my header but not in the short format currently provided by pressing the "date" button. Is there a forumala etc that I can use that will change the format of this particular date without going through computer settings and chaning the "standard" date option. (much like how you can format a normal cell to show the date in whatever format you require You can use this macro: Public Sub DateInHeader() Dim ws As Worksheet For Each ws In ActiveWindow.SelectedSheets ws.PageSetup.LeftHeader = Format(Date, "dd m...

Report writer
Hello, I am trying to add the transaction distribution details onto a copy of the PM Blank Document in Report Writer in GP 9. Would you pls advise as I can add the fields containing the data but the data is not appearing on the report. Thanks your comments are appreciated. -- chj@jup Once you were done modifying the report, did you give access to the mdoified report under Security? -- Lyle U chj wrote: > Hello, > > I am trying to add the transaction distribution details onto a copy > of the PM Blank Document in Report Writer in GP 9. Would you pls > advise as I c...

VC6 -> VC2003 STL compiler error
Hello, I'm having problems porting STL to VC2003. If anyone could please help me convert this code that compiles fine with VC6 to compile with VC2003, I'd be grateful: class StrBuffer: private std::vector<_TCHAR> { typedef std::vector<_TCHAR> Base; public: LPTSTR operator&() { return Base::begin(); // <-- compiler error // The above line's error is: // error C2440: 'return' : cannot convert from 'std::vector<_Ty>::iterator *' to 'LPTSTR' // with // [ // _T...

Loan Accounts in Reports
Bugs are in reports, the loan that I pay to my car is divided in 2, principal and interest, but in reports I can't show the two at same time, the reports show only the interest that I'm paying. The budget have the same problem with loans, it shows values that don't exists, I start a new budget, put all the values correctly and finalize it, when I go to budget home there are values that I not put there. There is some fix to those bugs? ...