Page 1 of 2 12 LastLast
Results 1 to 15 of 26
  1. #1
    diegomarino is offline Competent Performer
    Windows 10 Access 2016
    Join Date
    Feb 2018
    Posts
    197

    report export problem - textbox not showing data

    hi
    i have a report in which i have 3/4 subforms.
    when i see in report view i can see some textboxes filled with a recordset, but when i export in pdf those textboxes are blank. The strange thing is that when i print the subform as stand alone those textbox are filled

    why?


    tell me what information you need

  2. #2
    Gicu's Avatar
    Gicu is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    Jul 2015
    Location
    Kelowna, BC, Canada
    Posts
    2,249
    Do you see them in Print Preview? Can you upload a small sample with the report (and the related tables, queries, subreports, etc.) wiht no sensitive data?

    Cheers,
    Vlad Cucinschi
    MS Access Developer
    http://forestbyte.com/

  3. #3
    diegomarino is offline Competent Performer
    Windows 10 Access 2016
    Join Date
    Feb 2018
    Posts
    197
    actually when i try to go to print preview there is a problem on sources. maybe a have to dig into it first. that's a good start point

  4. #4
    Gicu's Avatar
    Gicu is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    Jul 2015
    Location
    Kelowna, BC, Canada
    Posts
    2,249
    Good job, please post back if you get stuck!
    Cheers,
    Vlad Cucinschi
    MS Access Developer
    http://forestbyte.com/

  5. #5
    diegomarino is offline Competent Performer
    Windows 10 Access 2016
    Join Date
    Feb 2018
    Posts
    197
    i just decided to make a brand new system. When i made it i was so ignorant and now is easier to study the talmud then this report...thanks

  6. #6
    diegomarino is offline Competent Performer
    Windows 10 Access 2016
    Join Date
    Feb 2018
    Posts
    197
    hi
    sorry for necroposting but i got more or less the same problem

    this is a copy cleaned (a lot messed up unfortunely but i think it's ok)of my db with no sensible data (almost )

    the "candidati" form opens at start, there's a big orange button that you have to press to make the report.
    two issues

    1) when you go to print preview charts got no sources and you can't see them

    2) when you export the report the textbox filled with a recordset are blank,not in report view


    Click image for larger version. 

Name:	Cattura.PNG 
Views:	14 
Size:	21.5 KB 
ID:	44532

    can you check please?
    Attached Files Attached Files

  7. #7
    Gicu's Avatar
    Gicu is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    Jul 2015
    Location
    Kelowna, BC, Canada
    Posts
    2,249
    Hi Diego,
    Please have a look at the updated report. It is recommended to use reports not forms as subreports as they don't have the same events. The report you included is missing the chart (I get lots of compile errors because you probably removed stuff to create the sample) so couldn't really check that out, I've just commented out those lines.
    Cheers,
    Vlad
    Attached Files Attached Files
    Vlad Cucinschi
    MS Access Developer
    http://forestbyte.com/

  8. #8
    diegomarino is offline Competent Performer
    Windows 10 Access 2016
    Join Date
    Feb 2018
    Posts
    197
    thanks to you i think i found the problem: the recordset must be made in on load event, not on open...

    good advice to use reports as subreports and not forms

    i set this as solved, if i have some more difficulties i let you now

  9. #9
    diegomarino is offline Competent Performer
    Windows 10 Access 2016
    Join Date
    Feb 2018
    Posts
    197
    ok, the problem is that.

    when i use a report as subreport whem i export it i cannot see in pdf.

    i i use a form as subreport i can see it in pdf but the textboxes filled with recordset are blank.

    i think the only solution is to make another query to fill those textboxes and use a form as subreport.

    otherwise i'll go mad

  10. #10
    Gicu's Avatar
    Gicu is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    Jul 2015
    Location
    Kelowna, BC, Canada
    Posts
    2,249
    but the one I sent you with the subreport did have the textboxes on the last page populated just fine.
    Click image for larger version. 

Name:	Capture.PNG 
Views:	12 
Size:	64.6 KB 
ID:	44554
    Cheers,
    Vlad Cucinschi
    MS Access Developer
    http://forestbyte.com/

  11. #11
    diegomarino is offline Competent Performer
    Windows 10 Access 2016
    Join Date
    Feb 2018
    Posts
    197
    yes, i thinkl the first time it worked, now it's not working anymore. i just redownloaded you db and i got nothing in those textboxes.
    that's black magic, i'm managing in a different way (made another subreports instead of textboxes and works fine)

    i really can't understand what's going on, so, he won, i loose. I can accept defeat

  12. #12
    Gicu's Avatar
    Gicu is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    Jul 2015
    Location
    Kelowna, BC, Canada
    Posts
    2,249
    Mine is still working, is the code that populates the boxes in the Format (or Print) event of the subreport (not on Open)?
    Cheers,
    Vlad Cucinschi
    MS Access Developer
    http://forestbyte.com/

  13. #13
    diegomarino is offline Competent Performer
    Windows 10 Access 2016
    Join Date
    Feb 2018
    Posts
    197
    you're right.
    It works only when i print it, even the same recordset is on open.

    why? i can't have it even in report view?

  14. #14
    Gicu's Avatar
    Gicu is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    Jul 2015
    Location
    Kelowna, BC, Canada
    Posts
    2,249
    Because the report view doesn't have the print event:
    https://www.engram9.info/access-2007...of-events.html

    Cheers,
    Vlad Cucinschi
    MS Access Developer
    http://forestbyte.com/

  15. #15
    diegomarino is offline Competent Performer
    Windows 10 Access 2016
    Join Date
    Feb 2018
    Posts
    197
    i was totally unaware of format event. now works fine.

    i would have just the last doubt.
    i putted the recodset code even in "onload" event and then i open the subreport as stand alone i can see textboxes filled even in report view.

    when i open the main report texboxes are not filled (just in report view)
    why ?

Page 1 of 2 12 LastLast
Please reply to this thread with any new information or opinions.

Similar Threads

  1. Sub report not showing data on pdf export
    By diegomarino in forum Access
    Replies: 4
    Last Post: 09-04-2020, 01:51 AM
  2. Replies: 1
    Last Post: 01-23-2019, 01:55 PM
  3. Replies: 9
    Last Post: 08-08-2016, 02:57 PM
  4. Replies: 1
    Last Post: 07-21-2014, 04:06 PM
  5. Replies: 15
    Last Post: 04-16-2014, 01:15 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 - Senior Forums