Solved

How to open a Report on top of the switchboard as referring form closes

Posted on 2014-03-11
2
491 Views
Last Modified: 2014-03-11
A simple form with a combo box allows the user to select a service manager in order to open a report to list this person's action items.  This same method is used for two different reports.   One report opens in front of the Switchboard for immediate use.   I need the other to do the same, but it opens behind the Switchboard.  I don't know that anything is different between the forms/reports/code.  

How can I ensure a Report is opened in front of the Switchboard as the selecting Form is closed?

Listed below is the procedure that works, followed by the one that doesn't:

Private Sub cboNBitemSelect_AfterUpdate()
Dim SelectedCSM As String
SelectedCSM = Me!cboNBitemSelect.Column(0)
DoCmd.Close acForm, "fm_CSMSelectForNBReport"
If SelectedCSM = "All CSMs" Then
    DoCmd.OpenReport "rpNewBusinessStatus", acViewReport
Else
    DoCmd.OpenReport "rpNewBusinessStatus", acViewReport, , "NBCSM = '" & SelectedCSM & "'"
End If
End Sub

Private Sub cboCSitemSelect_AfterUpdate()
Dim SelectedCSM As String
SelectedCSM = Me!cboCSitemSelect.Column(0)
DoCmd.Close acForm, "fm_CSMSelectForCSReport"
If SelectedCSM = "All CSMs" Then
    DoCmd.OpenReport "rpClientServiceStatus", acViewReport
Else
    DoCmd.OpenReport "rpClientServiceStatus", acViewReport, , "CS_CSM = '" & SelectedCSM & "'"
End If
End Sub
0
Comment
Question by:David_W_R
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 120

Accepted Solution

by:
Rey Obrero (Capricorn1) earned 500 total points
ID: 39920587
try adding the option to open the report in dialog(modal) mode

DoCmd.OpenReport "rpNewBusinessStatus", acViewReport, windowmode:=acDialog
0
 

Author Closing Comment

by:David_W_R
ID: 39920642
Mighty fine!   Many thanks!
0

Featured Post

Creating Instructional Tutorials  

For Any Use & On Any Platform

Contextual Guidance at the moment of need helps your employees/users adopt software o& achieve even the most complex tasks instantly. Boost knowledge retention, software adoption & employee engagement with easy solution.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Overview: This article:       (a) explains one principle method to cross-reference invoice items in Quickbooks®       (b) explores the reasons one might need to cross-reference invoice items       (c) provides a sample process for creating a M…
In Part II of this series, I will discuss how to identify all open instances of Excel and enumerate the workbooks, spreadsheets, and named ranges within each of those instances.
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…

738 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