Solved

call sub in another loaded form

Posted on 2013-01-13
2
274 Views
Last Modified: 2013-01-23
I have a piece of code thx to an expert that checks if a form is loaded and then sets its slider control.

I have a sub called setfilter in the other loaded form (frmsmmtmaster). How do i get that sub to run?

If Me.BtnToggleSyncForms = True And CurrentProject.AllForms("FrmSMMTMaster").IsLoaded Then
 Forms!FrmSMMTMaster.Form.Controls.Item("ccslider").Value = Me.CCExportSlider.Value

End If
0
Comment
Question by:PeterBaileyUk
2 Comments
 
LVL 29

Accepted Solution

by:
IrogSinta earned 500 total points
ID: 38773501
Make your procedure public instead of private.
Public Sub setfilter()

Then call it this way:
Call Forms.FrmSMMTMaster.setfilter
0
 

Author Closing Comment

by:PeterBaileyUk
ID: 38813293
apologies for delay I have been unwell.
0

Featured Post

Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

Join & Write a Comment

When you are entering numbers in a speadsheet, and don't remember what 6×7 is, you just type “=6*7" instead. It works in every cell! This is not so in Access. To enter the elusive 42 in a text box, you have to find a calculator, and then copy the re…
In the article entitled Working with Objects – Part 1 (http://www.experts-exchange.com/Microsoft/Development/MS_Access/A_4942-Working-with-Objects-Part-1.html), you learned the basics of working with objects, properties, methods, and events. In Work…
Familiarize people with the process of utilizing SQL Server stored procedures from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Micr…
In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now