473,378 Members | 1,084 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,378 software developers and data experts.

cannot use function in access report

232 100+
access 2007
  1. i created the report
  2. went to view code option
  3. copy pasted the code of function code on new module
but when i call the function in report it gives error enter parameter value but even after providing value it prints
?error
i tried to use it in query too just for testing purpose but it also gives error "undefined function convertcurrencytoenglish"
it seems that my report or query cannot connect with module
i read many tutorials but the problem still exists
should i have to install visual basic on my system?
i used many functions in excell but in access it gives above mentioned errors

kindly help
thanks in advance
May 26 '12 #1

✓ answered by Stewart Ross

I am assuming that you have not altered the A2007 Trust Centre settings from their defaults, which prevent VBA code from running.

To set Access 2007 to enable VBA code without restriction you need to alter the Trust Centre settings. This is a bit involved as the settings are buried several menus down.

Click on the multi-coloured Office button at the top left of the Access window, then click the Access Options button on the lower right of the Office menu. Select Trust Centre from the Access Options menu, then click the Trust Center Settings button.

Click on the Macro Settings option on the trust center's left side menu, then select Enable all macros (the option which is marked 'not recommended; potentially dangerous code can run)'. Click on OK to close the macro options menu, and Ok again to close the Trust Center menu.

Close and restart the database for the change to take effect.

-Stewart

1 2305
Stewart Ross
2,545 Expert Mod 2GB
I am assuming that you have not altered the A2007 Trust Centre settings from their defaults, which prevent VBA code from running.

To set Access 2007 to enable VBA code without restriction you need to alter the Trust Centre settings. This is a bit involved as the settings are buried several menus down.

Click on the multi-coloured Office button at the top left of the Access window, then click the Access Options button on the lower right of the Office menu. Select Trust Centre from the Access Options menu, then click the Trust Center Settings button.

Click on the Macro Settings option on the trust center's left side menu, then select Enable all macros (the option which is marked 'not recommended; potentially dangerous code can run)'. Click on OK to close the macro options menu, and Ok again to close the Trust Center menu.

Close and restart the database for the change to take effect.

-Stewart
May 26 '12 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: Nicola | last post by:
Hi Everyone, I am new to programming and would like to know how to open an access Report from within vb 6. I am trying to write a program to organise cross stitch threads. I have found out how...
8
by: Mike MacSween | last post by:
tblCourses one to many to tblEvents. A course may have an intro workshop (a type of event), a mid course workshop, a final exam. Or any combination. Or something different in the future. At...
8
by: lauren quantrell | last post by:
When I open an Access form I can have no recordset specified, then in the form's OnOpen event I can do something like: Me.paramaters = "@SomeColumn = 22)" Me.recordsource = "dbo.sproc123" But I...
4
by: Greg Teets | last post by:
I am running an Access report from VB via ADO. The report has a field that shows the time it was run. Is it possible to return the data from this field to VB when the report runs? Or to find...
4
by: dkelly925 | last post by:
I have an Access Report that I am trying to enter an "If Statement" that when a certain field exceeds a certain number of lines or a certain number of characters that field is not visible and...
4
by: vbie | last post by:
For some reason, I cannot open an Access report in "design" mode anymore. This didn't happen before. However, I can open the design mode of the form, query, table in the same database. Please...
1
by: maccount | last post by:
I'm having a simple problem (or at least I believe it to be), one that has stumped me. I have a simple text box in my Access Report, page header. Dmin("ppID", "qry001") This report is based on...
0
by: accessdumbie | last post by:
We have a small amount of information in a Word Document that I would like to print in an Access Report. We have the location of the document for each individual record stored in a hyperlink field...
0
by: nilesh tayde | last post by:
how can i pass parameter to print access report by giving parameter as Report File Name,Query,PrinterName,Number of copies to be print my code is Function fPrintRemoteReport(strMDB As...
0
by: rmurgia | last post by:
I am trying to create an Access report programmatically. So far I have been able to accomplish everything except the following: 1) I cannot determine the code to create a Page Footer Set...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
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: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
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?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

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.