INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS
Come Join Us!
Are you a
Computer / IT professional?
Join Tek-Tips now!
- Talk With Other Members
- Be Notified Of Responses
To Your Posts
- Keyword Search
- One-Click Access To Your
- Automated Signatures
On Your Posts
- Best Of All, It's Free!
*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.
Partner With Us!
"Best Of Breed" Forums Add Stickiness To Your Site
(Download This Button Today!)
"...Dudes! Great site. You've saved me hours and hours...and I have just started using your site. I've already passed your URL onto my entire company. Keep up the awesome work. Bingo-bango..."
Where in the world do Tek-Tips members come from?
How to write a form macro and set its default start position
Posted: 28 Sep 03
ACCPAC 5.0 and above must be installed.
1. Create a VBA macro in ACCPAC by using the macro editor
2. Insert a form into your macro
3. Right-click on Toolbox within the VBA Editor
4. Select to add the UI control you want to customize e.g. ACCPACPO1210UICtrl
5. Drag and drop to place the UI control on the form.
6. Select Tools->References from menu.
7. Find ACCPAC Data Source Control 1.0 and check it.
8. Add the following code to your control:
' Declare a data source control for use
Dim WithEvents dsPO As ACCPACPO1210.ACCPACDSControl
Private Sub AccpacPO1210UICtrl1_OnUIAppOpened()
' set your data souce control to one of the UI data source controls
Set dsPO = AccpacPO1210UICtrl1.UIDSControls(10)
' Define where you want your UI to start by default
dsPO.Fields("PONUMBER") = "PO000000028"
The above logic can be applied to just about any data entry forms in ACCPAC 5.0 and up. To find out details of each form, use the UI Info tool.
Back to ACCPAC Solutions FAQ Index
Back to ACCPAC Solutions Forum
Join Tek-Tips® Today!
Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.
Here's Why Members Love Tek-Tips Forums:
- Talk To Other Members
- Notification Of Responses To Questions
- Favorite Forums One Click Access
- Keyword Search Of All Posts, And More...
Register now while it's still free!
Already a member? Close this window and log in.
Join Us Close