Solved

Access 2010 Drill Down to Another Form

Posted on 2014-09-14
8
247 Views
Last Modified: 2014-09-14
I have a form (frm_Accounting_Transactions) with a field (Fund_Map) that has multiple values separated by commas (EC,EG,EM,EP,ER,ES,ET,TR)
I would like to drill down to another form (frm_fund_Groups) field Fund Type Code and display only the records based on the multiple values from the Fund_Map field on the frm_Accountinng_Transactions. Thanks
0
Comment
Question by:shieldsco
[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
  • 4
  • 2
  • 2
8 Comments
 
LVL 120

Expert Comment

by:Rey Obrero (Capricorn1)
ID: 40321793
try

docmd.openform "frm_fund_Groups",,, "[Fund Type Code]='" & me.txtFund_Map & "'"
or

docmd.openform "frm_fund_Groups",,, "[Fund Type Code]=" & chr(34) & me.txtFund_Map &  Chr(34)
0
 

Author Comment

by:shieldsco
ID: 40321825
I get compile error Method or Data Member no found on both..........txtFund_Map
0
 

Author Comment

by:shieldsco
ID: 40321827
Please note - the number of pairs vary with the records... some records my have three pairs while other records my none (null) or 1 or 5 etc
0
Enterprise Mobility and BYOD For Dummies

Like “For Dummies” books, you can read this in whatever order you choose and learn about mobility and BYOD; and how to put a competitive mobile infrastructure in place. Developed for SMBs and large enterprises alike, you will find helpful use cases, planning, and implementation.

 

Author Comment

by:shieldsco
ID: 40321902
0
 
LVL 120

Accepted Solution

by:
Rey Obrero (Capricorn1) earned 500 total points
ID: 40321923
use these codes


Private Sub Fund_Map_Click()
Dim strFund As String, j As Integer, fundArr() As String
If InStr(Me.Fund_Map, ",") Then
    fundArr = Split(Me.Fund_Map, ",")
    For j = 0 To UBound(fundArr)
        strFund = strFund & "," & Chr(39) & fundArr(j) & Chr(39)
    Next
    Else
    strFund = Chr(39) & Me.Fund_Map & Chr(39)
End If
If InStr(strFund, ",") Then
    strFund = Mid(strFund, 2)
End If

DoCmd.OpenForm "frm_fund_Groups", , , "[Fund Type Code] in(" & strFund & ")"
End Sub

Open in new window

0
 
LVL 29

Expert Comment

by:IrogSinta
ID: 40321927
You can also give this a try:
DoCmd.OpenForm "frm_fund_Groups", , , "InStr('" & Me.Fund_Map & "',[Fund Type Code])>0"

Open in new window

Ron
0
 

Author Closing Comment

by:shieldsco
ID: 40321933
Very Good-- Thanks
0
 
LVL 29

Expert Comment

by:IrogSinta
ID: 40322053
So did you the other solution not work?
0

Featured Post

Instantly Create Instructional Tutorials

Contextual Guidance at the moment of need helps your employees adopt to new software or processes instantly. Boost knowledge retention and employee engagement step-by-step with one easy solution.

Question has a verified solution.

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

Suggested Solutions

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…
AutoNumbers should increment automatically, without duplicates.  But sometimes something goes wrong, and the next AutoNumber value is a duplicate.  This article shows how to recover from this problem.
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
Basics of query design. Shows you how to construct a simple query by adding tables, perform joins, defining output columns, perform sorting, and apply criteria.

734 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