Results 1 to 5 of 5
  1. #1
    markjkubicki's Avatar
    markjkubicki is offline Competent Performer
    Windows XP Access 2007
    Join Date
    Jul 2010
    Location
    Fire Island Pines, NY
    Posts
    496

    assigning a value to the control on a subreport (simple syntax ?)


    need to assign a value to the control on a subreport; but... I'm stuck in syntax
    the report name is rptFixtureSchedule_working copy
    the container on it for the subreport is ctr_Col1
    the subreport is srpt_FixtSched_col1
    the control on it is txtCol1_Text_001

    the code I'm fighting with is (and the many variations of....):
    Code:
            
    Reports![rptFixtureSchedule_working copy].report![ctr_Col1].[srpt_FixtSched_col1].[txtCol1_Text001] = strManufacturer

    with thanks in advance...
    mark

  2. #2
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,521
    Same as forms but with Reports/Report:

    http://www.theaccessweb.com/forms/frm0031.htm
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  3. #3
    markjkubicki's Avatar
    markjkubicki is offline Competent Performer
    Windows XP Access 2007
    Join Date
    Jul 2010
    Location
    Fire Island Pines, NY
    Posts
    496
    Thank you for the reply
    I do know of the table and have referenced it MANY times
    But this time I just can't get it right?

    =:-(

  4. #4
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,521
    Table? Did you look at the link? You don't reference both the subreport container and the subreport, just the container.
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  5. #5
    June7's Avatar
    June7 is online now VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,915
    Reports![rptFixtureSchedule_working copy].[ctr_Col1]![txtCol1_Text001] = strManufacturer

    Won't work if report is in PrintPreview or direct to printer. Has to be ReportView.

    Where is the code executed? How is strManufacturer populated?

    Probably should have [txtCol1_Text001] ControlSource reference a control on form or call a user defined function.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. assigning the inital value to an option frame control
    By markjkubicki in forum Programming
    Replies: 6
    Last Post: 08-12-2015, 07:06 AM
  2. simple syntax ?
    By markjkubicki in forum Queries
    Replies: 2
    Last Post: 10-09-2012, 10:31 AM
  3. Can't control subreport spacing
    By bonnerm in forum Reports
    Replies: 2
    Last Post: 08-11-2012, 04:30 PM
  4. Replies: 2
    Last Post: 06-13-2011, 06:04 PM
  5. Replies: 5
    Last Post: 06-10-2011, 03:31 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums