473,686 Members | 3,199 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Run a function from "On Click" or "On Exit"

Good day, and thank you in advance for any assistance. I'm having trouble
with something that I'm trying for the first time.

Using Access 2000 - I want to run a function either on the click of a button
or on leaving a text box. For the immediate task, either will work as well
as the other. I think.

I'm just at the beginning of this, and the form has two text boxes - Text0
and Text1. The user input to Text0 is a dollar amount, in numbers. On either
leaving the text box or clicking a button, I want to run a function to
convert the numerical value to the dollar amount in words, and then put that
string into Text1. I copied a function for this purpose - it came from the
mvps.org Web site. The function is named "English".

I'm not sure if the function is being called. I get the following error
message, whether I use a command button's "On Click" event, or the text box
"On Exit" event -

The expression "On Exit" you entered as the event property setting
produced
the following error: Ambiguous name detected: English

Then it says -

*The expression may not result in the name of a macro, the name of a
user-defined
function or [Event Procedure].
*There may have been an error evaluating the function, event or macro.

I can't tell what is ambiguous. The function does use a variable named
"English" - is that possibly the conflict? I've never used a function,
except in a Saturday morning class a few years ago, so my troubleshooting
skills aren't of much use here. Please be gentle, and thank you.
Steve E.

May 2 '06 #1
2 4848
Presumably you are talking about this English() function:
http://www.mvps.org/access/modules/mdl0001.htm

The "ambiguous name" message means you have a couple of things in your
database that have the same name. Did you save this function in a module
named "English"? If so, try renaming the module to something else.

If it is not the module, there must be something else that has this name.

If nothing is visible, try compacting the database:
Tools | Database Utilities | Compact

--
Allen Browne - Microsoft MVP. Perth, Western Australia.
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

"Serious_Practi tioner" <Se************ ************@at t.net> wrote in message
news:fh******** ***********@bgt nsc05-news.ops.worldn et.att.net...
Good day, and thank you in advance for any assistance. I'm having trouble
with something that I'm trying for the first time.

Using Access 2000 - I want to run a function either on the click of a
button
or on leaving a text box. For the immediate task, either will work as well
as the other. I think.

I'm just at the beginning of this, and the form has two text boxes - Text0
and Text1. The user input to Text0 is a dollar amount, in numbers. On
either
leaving the text box or clicking a button, I want to run a function to
convert the numerical value to the dollar amount in words, and then put
that
string into Text1. I copied a function for this purpose - it came from the
mvps.org Web site. The function is named "English".

I'm not sure if the function is being called. I get the following error
message, whether I use a command button's "On Click" event, or the text
box
"On Exit" event -

The expression "On Exit" you entered as the event property setting
produced
the following error: Ambiguous name detected: English

Then it says -

*The expression may not result in the name of a macro, the name of a
user-defined
function or [Event Procedure].
*There may have been an error evaluating the function, event or macro.

I can't tell what is ambiguous. The function does use a variable named
"English" - is that possibly the conflict? I've never used a function,
except in a Saturday morning class a few years ago, so my troubleshooting
skills aren't of much use here. Please be gentle, and thank you.
Steve E.

May 2 '06 #2
I'll start looking. And yes, the code I'm using is the one at that URL.
Thank you.

Steve E.

"Allen Browne" <Al*********@Se eSig.Invalid> wrote in message
news:44******** *************** @per-qv1-newsreader-01.iinet.net.au ...
Presumably you are talking about this English() function:
http://www.mvps.org/access/modules/mdl0001.htm

The "ambiguous name" message means you have a couple of things in your
database that have the same name. Did you save this function in a module
named "English"? If so, try renaming the module to something else.

If it is not the module, there must be something else that has this name.

If nothing is visible, try compacting the database:
Tools | Database Utilities | Compact

--
Allen Browne - Microsoft MVP. Perth, Western Australia.
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

"Serious_Practi tioner" <Se************ ************@at t.net> wrote in
message
news:fh******** ***********@bgt nsc05-news.ops.worldn et.att.net...
Good day, and thank you in advance for any assistance. I'm having trouble
with something that I'm trying for the first time.

Using Access 2000 - I want to run a function either on the click of a
button
or on leaving a text box. For the immediate task, either will work as
well
as the other. I think.

I'm just at the beginning of this, and the form has two text boxes -
Text0
and Text1. The user input to Text0 is a dollar amount, in numbers. On
either
leaving the text box or clicking a button, I want to run a function to
convert the numerical value to the dollar amount in words, and then put
that
string into Text1. I copied a function for this purpose - it came from
the
mvps.org Web site. The function is named "English".

I'm not sure if the function is being called. I get the following error
message, whether I use a command button's "On Click" event, or the text
box
"On Exit" event -

The expression "On Exit" you entered as the event property setting
produced
the following error: Ambiguous name detected: English

Then it says -

*The expression may not result in the name of a macro, the name of a
user-defined
function or [Event Procedure].
*There may have been an error evaluating the function, event or
macro.

I can't tell what is ambiguous. The function does use a variable named
"English" - is that possibly the conflict? I've never used a function,
except in a Saturday morning class a few years ago, so my troubleshooting
skills aren't of much use here. Please be gentle, and thank you.
Steve E.


May 2 '06 #3

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

Similar topics

2
1867
by: John Smith | last post by:
I have more than 4,000 pieces of email in my Yahoo account. I would like to write a program to download them all. In order to write such a program, I need to know a few things. 1. After I fill out userid, password, and click on "login", what exactly is sent to Yahoo? 2. When I click on "next" to fetch the next mail, what exactly is sent to Yahoo?
1
1659
by: Bob Alston | last post by:
I am trying to highlight required data fields in a continuous form situation. Got it working for all but date fields. For date fields, I am trying setting default date to -1 (=12/29/1899) and then using this format: mm/dd/yyyy ;" Missing Date" Shows words "missing Date" for the default value. And if a good date is entered, the field displays with black text. What I want to do is make it easy to fix missing dates. Now, If i click
1
1584
by: Boni | last post by:
Dear all, I have a question about TreeView elements. is it possible to differentate double click on TreeNode itself from double click on "+" of this TreeNode? Thanks in advance, Boni
2
9926
by: Kikoz | last post by:
Hi all. I'm using one PC/XP Pro as my development environment. Its IIS has one default web site, of course, which is the site I'm working on. When some feature is finished I deploy it to my "production" site which is hosted somewhere else. Very common situation, I guess. This app uses email to notify customers of some particular events. Works on production, but sometimes I need to change something in the way those notifications work....
4
6501
by: MDW | last post by:
Hey all. I'm confused. I'm trying to add a single record into an Access 2000 database using ASP.Net. Here is the code: objConn = New OleDbConnection(strConnect) objConn.Open objCommand = New OleDbCommand("INSERT INTO LOGIN_MASTER (LOGIN_ID, PWD, F_NAME, L_NAME, TYPE_ID) VALUES ('" & strEmail & "','" & strPwd & "','" &
6
1524
by: Alan Silver | last post by:
Hello, I have a page that displays a data list with info from a database. The grid has the usual stuff, edit, update, delete etc. Below this I have a section where they can add a new entry to the list. This has some text boxes for the data, and a button to click when they are ready to submit. To the user, this looks like two separate forms, one containing a grid of existing data and one where they add new data.
2
1963
by: Benny Raymond | last post by:
I was looking through the options and only saw this type of default for XML and HTML - but what about C# forms and what not - is it possible to default these to View Code? Thanks, Benny
1
4677
by: ranabhavin2 | last post by:
Hi, on button click I want to open new window each time. Currently when I m click on button second time then my new window is replaced with my original window. We can do it in hyperlink by target="_blank". But what for button ? So, each time new popup window should be open. My code is as following :
8
2358
by: Grorange | last post by:
Writing ASP.NET pages, I have a need for client-side functions to prevent going to the server for every small change. I have a list of server side created checkboxes filled with a lot of information being presented in a form on my site. In a JavaScript setup function, I attach the following event handler (I know syntax is wrong, I just simplified it for purposes within this post): <for every checkbox>onchange = function() { ...
3
3336
by: ysakaed | last post by:
Hi I am trying to get the content of the iframe to replace the content inside a div here is the code i use. function changeContent(content) { var buf = content + "_2"; var iframe = document.getElementById(buf); document.getElementById(content).innerHTML = (iframe.contentDocument || iframe.contentWindow.document).documentElement.innerHTML; }
0
8514
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
1
8766
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8778
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7598
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6439
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 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 a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4307
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
2944
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
2205
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
1933
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.