473,396 Members | 1,886 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Subform NOT working in REPORT

135 100+
Hello,

I have a form with some code to HIDE textboxes and labels when information is not used. I need this information in a report so i added the form as a Subform/Subreport in a report. The problem is that when runing the REPORT, it seems like the SUBFORM CODE DOESNT WORK, as it displays EVERYTHING. Its not following the code to HIDE the textboxes and labels, which are correctly hidden when running the FORM on its own.

Whats happening, what can i do??

Code lines in the form look like:
Expand|Select|Wrap|Line Numbers
  1. If IsNull([level7label]) Then
  2. Me.Label166.Visible = False
  3. Me.Label164.Visible = False
  4. Me.Label165.Visible = False
  5. Me.y16.Visible = False
  6.  
Thanks,
Gilberto
Oct 30 '07 #1
5 2572
Rabbit
12,516 Expert Mod 8TB
Make a subreport and use the On Render event of the section that the information is in.
Oct 30 '07 #2
Gilberto
135 100+
Make a subreport and use the On Render event of the section that the information is in.
Hello, thnks for the reply.

Just to be clear this is the situaction:

I simly dragged the form into the reports detail section, this section DOESNT have any ON RENDER event (it has on format, print, retreat), i actually COULDT find any ON RENDER on any section of or actual report. On the form i just inserted i found a BEFORE RENDER, AFTER RENDER and AFTER FINAL RENDER. The formatting code (if isnull([text1]...) i need is currently in the forms On Load so i simply did a copy paste into all of the render events however in the report the form (subform) code doesnt work.

Maybe i didnt understand what u were saying.

Any ideas???

Thanks
Oct 31 '07 #3
FishVal
2,653 Expert 2GB
Hi, Gilberto.

Rabbit obviously has dispelled event name.
Try OnPrint event on the main report.
And using subform control is quite acceptable in this case.

Be sure to refer to subform's control in a proper way.
e.g.
Expand|Select|Wrap|Line Numbers
  1. Me![Subform control name].Form![Subform's control name]
  2.  
Oct 31 '07 #4
Gilberto
135 100+
Hi, Gilberto.

Rabbit obviously has dispelled event name.
Try OnPrint event on the main report.
And using subform control is quite acceptable in this case.

Be sure to refer to subform's control in a proper way.
e.g.
Expand|Select|Wrap|Line Numbers
  1. Me![Subform control name].Form![Subform's control name]
  2.  
Thanks, it worked perfectly.
Oct 31 '07 #5
Rabbit
12,516 Expert Mod 8TB
Hi, Gilberto.

Rabbit obviously has dispelled event name.
Try OnPrint event on the main report.
And using subform control is quite acceptable in this case.

Be sure to refer to subform's control in a proper way.
e.g.
Expand|Select|Wrap|Line Numbers
  1. Me![Subform control name].Form![Subform's control name]
  2.  
Yeah, sorry about that. I always think that there's an On Render event.
Oct 31 '07 #6

Sign in to post your reply or Sign up for a free account.

Similar topics

4
by: John Baker | last post by:
Hi: I have a form, which contains a sub form (Employee main record and payment record). It all shows up fine in a screen view, but when I come to print it I find that I cannot get the sub form...
5
by: Mary Litten | last post by:
Hi - (This is my very first post) I have gotten to this point of registering to post because I have been spinning my wheels so long, I believe I am all caught up in the weeds. (and mud) I have...
1
by: kkrizl | last post by:
I have a form that displays general information about an alarm permit location. There's a subform that shows detailed information about burglar alarms that have gone off at the location. When a...
2
by: Mike | last post by:
I have a parent form with two subforms on it. Each subform lists certain records and then totals up one of the fieldsd. The parent form then totals up the two text boxes. The problem is that if...
2
by: David W. Fenton | last post by:
I think at various times we've all encountered this problem: A subform is on a main form. From the code of the main form we refer to some property of/control on the child form thus: ...
1
by: google | last post by:
I have a form with several subforms. Users enter the data, then on the parent there is a command button that runs code to generate a .pdf document from a report based on the data they are working...
3
by: paquer | last post by:
On my Main form I have a Command Button that opens a Subform in order to create a new Subform record. At this point I want the subform to show only the new record being created. Not all the...
4
by: Henrootje | last post by:
I have a REPORT with in it a subFORM Now I have this label (lblMonth) that I want to change. How should I do this? What would be the proper event to do this? The lblMonth should contain the...
1
by: Crombam | last post by:
Hi to all, After searching the net for a couple of hours I just have to ask the question. How can I close a report with a subform (Pivot Chart) when this Pivot Chart is having no data? ...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.