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

Custom Events / Application properties ?

Hi,

I have a function that needs to run whenever a user clicks on any
textbox, listbox or combobox on any input forms in my application
(there are many forms).

Background (in case someone has a better suggestion):
The forms are all unbound and the datatype and inputmasks are built on
the fly.
If the user clicks on the control, the cursor is positioned at the end
of the inputmask. They find this bothersome and wish the cursor to be
positioned at the beginning. Fine, no problem for that part. I create
a function that sets SelStart = 0 for the control clicked on.

Hopeful question:
Is there any way to call this function without putting a line of code
on the click event of every control on all of these forms? Maybe using
a class module to create a customized application level event? Can you
create application events? Can you create custom properties for
controls - like "StartPosition" for example and then set that property
upon opening the application?

Thanks for your input,
April
Nov 13 '05 #1
3 1761
April,

Open your form im design view. Hold down the Shift Key and use the lasso and
also individual picks until you have selected all the controls you want to
execute the function. Open properties to the Events tab. Type the following in
the OnEnter event:

=NameOfYourFunction

All the controls you selected on your form will now execute your function. You
can do the same thing to other forms.

--
PC Datasheet
Your Resource For Help With Access, Excel And Word Applications
re******@pcdatasheet.com
www.pcdatasheet.com

"April" <Pr*************@hushmail.com> wrote in message
news:54**************************@posting.google.c om...
Hi,

I have a function that needs to run whenever a user clicks on any
textbox, listbox or combobox on any input forms in my application
(there are many forms).

Background (in case someone has a better suggestion):
The forms are all unbound and the datatype and inputmasks are built on
the fly.
If the user clicks on the control, the cursor is positioned at the end
of the inputmask. They find this bothersome and wish the cursor to be
positioned at the beginning. Fine, no problem for that part. I create
a function that sets SelStart = 0 for the control clicked on.

Hopeful question:
Is there any way to call this function without putting a line of code
on the click event of every control on all of these forms? Maybe using
a class module to create a customized application level event? Can you
create application events? Can you create custom properties for
controls - like "StartPosition" for example and then set that property
upon opening the application?

Thanks for your input,
April

Nov 13 '05 #2

"April" <Pr*************@hushmail.com> wrote in message
news:54**************************@posting.google.c om...
The forms are all unbound and the datatype and inputmasks are built on
the fly.

What are you, a Martian?
Nov 13 '05 #3
On Tue, 06 Jul 2004 16:40:22 GMT, "PC Datasheet" <no****@nospam.spam> wrote:
=NameOfYourFunction


=NameOfYourFunction()
Wayne Gillespie
Gosford NSW Australia
Nov 13 '05 #4

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

Similar topics

4
by: Steve Amey | last post by:
Hi all I am creating a basic control to perform some tasks, and I want to declare some events to be raised so they can be handled from the form that the control is on. I can create my own Event...
3
by: xAvailx | last post by:
I apologize ahead of time for the long post... Background: Working on a CRM type custom application. The application is for an event management company. The company will provide the application...
1
by: melanieab | last post by:
Hi, I found an article that explains how to do the custom sorting. Here is what it says: .... Perhaps you want some custom sorting method to take effect. To do that, DataGrid provides you with...
5
by: Barry Carr | last post by:
Hi, I've created a composite custom web control and a ControlDesigner descendant to render the control a design time. The child controls are public properties of composite control and as such...
6
by: Shimon Sim | last post by:
Hi I am working on application that need to hold custom user information - Last and first name, email, some other domain related information. I used to create Base class for all my pages. The base...
3
by: George Jordanov Ivanov | last post by:
Folks, I am implementing a WebUserControl, which will have its own custom event StateChanged. Now, I want to add this event to the Events tab in the control properties, so that the users of my...
4
by: matt.delvecchio | last post by:
hello, i understand the usefulness of having custom base classes when it pertains to common methods or custom handling of events (say, overriding all pages OnError and sending out an email of...
1
by: Gene | last post by:
I would like to know if the following is even possible with the visual studio.net Setup and Deployment project. 1. During the deployment after creation of application directory the setup needs...
8
by: =?Utf-8?B?QXNo?= | last post by:
Hi, I have an object, for example User. User contains various properties which i have been able to bind to successfully using wizards and the form view. However if the class User has a property...
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
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:
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...
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,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
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...
0
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...

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.