Calling a form from a sub form , and showing only the details that are selected

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • georgemathew
    New Member
    • Jan 2010
    • 1

    #1

    Calling a form from a sub form , and showing only the details that are selected

    hi there , this my first post

    i have a form "frmA" inside this form i have a sub form "frmB" , these two forms are linked by a field "keynum"( master to child relationship)
    the sub form "frmB" is in datasheet view .

    On selecting a field "index" on "frmB" i wanted to open another from "frmC"
    where by
    So on the on click event of the field index on the frmB i wrote the following code
    Code:
        stDocName = "frmC"
        
        stLinkCriteria = " "[Index] = [Forms]![frmC].[form]!Index"
     
       DoCmd.OpenForm stDocName, acNormal, ,stLinkCriteria
    This works fine when just the FrmC is only opened stand alone , and the record is clicked

    But when it try it to access the same through frmA , it ask me to enter the parameters
  • TheSmileyCoder
    Recognized Expert Moderator Top Contributor
    • Dec 2009
    • 2322

    #2
    Welcome to Bytes

    Please proofread your post, you have unfinished sentences.

    From the bit of code you posted it seems your trying to open frmC with a Where clause calling a field in frmC which doesnt make much sence.

    Comment

    Working...