data in Subform/Subreport

the Source Object for a Subform/Subreport is
Report.rpt_all_pinned_Data
under this report, the record source is blank. it populates the same info wherever it is placed/called (in any reports).

how can i drill down to see where it is getting the data from?

this is in v2002

thanks
subrpt.bmp
LVL 6
anushahannaAsked:
Who is Participating?
 
Jim Dettman (Microsoft MVP/ EE MVE)Connect With a Mentor President / OwnerCommented:
<<how can i drill down to see where it is getting the data from?>>

  you'll need to hunt for it.  Check the reports OnOpen, event first.

JimD.
0
 
anushahannaAuthor Commented:
OpOpen has
------------------
Option Compare Database

Private Sub Report_Open(Cancel As Integer)
  Call format_fields
End Sub
------------------------
format_fields() just gives the font and colors etc but no data pull.

on
close, activate, no data, on page, on error all are blank/empty
0
 
Scott McDaniel (Microsoft Access MVP - EE MVE )Connect With a Mentor Infotrakker SoftwareCommented:
You'll have to check any "object" which interacts with this report, or with any report that uses that as a subreport. A simple way is to search the VBA source for the name of that report, although this won't tell you about macros.

You might consider investing in something like Rick Fisher's Find and Replace utility (www.rickworld.com). For the money (less than $40 US) it's an invaluable tool.
0
Get expert help—faster!

Need expert help—fast? Use the Help Bell for personalized assistance getting answers to your important questions.

 
DatabaseMX (Joe Anderson - Microsoft Access MVP)Database ArchitectCommented:
Can you upload the db?
0
 
GRayLConnect With a Mentor Commented:
? Forms!myReport.Form.srpReport.RecordSource
--------------^--realRepName-^-realSubRepName

assumes myReport is already open.
0
 
anushahannaAuthor Commented:
LSM, do you mean 'modules' by VBA source?
0
 
anushahannaAuthor Commented:
DatabaseMX, due to confidential data, i am not able to; otherwise, i would have been glad to.
0
 
anushahannaAuthor Commented:
>>? Forms!myReport.Form.srpReport.RecordSource
--------------^--realRepName-^-realSubRepName

where do i run this from?
0
 
Scott McDaniel (Microsoft Access MVP - EE MVE )Infotrakker SoftwareCommented:
<LSM, do you mean 'modules' by VBA source? >

Yes. You'll need to search this for any occurence of the Report name. As I stated, using the standard builtin Access search function (from the VBA Editor) won't search macros. If you've made extensive use of macros, then you'll need a 3rd party utility like F&R.

0
 
anushahannaAuthor Commented:
access does not feature to search within macros?

can we see (the code) what is behind macros?
0
 
DatabaseMX (Joe Anderson - Microsoft Access MVP)Database ArchitectCommented:


As suggested twice above, make this easy on yourself.  Download this:

http://www.rickworld.com/beta   (don't worry about the word Beta)

I believe you can still try it for 30 days.

mx
0
 
anushahannaAuthor Commented:
i am glad to try it..thanks

if you use that tool, can you guide me- i see the Tools->add in only in the replace9.mde file, not in any of the other mdb files that i am interested in. do you search for any other database from the replace9.mde file?
0
 
DatabaseMX (Joe Anderson - Microsoft Access MVP)Database ArchitectCommented:
You need to follow the installation instructions in Readme.txt file, which I have attached.

mx
F-R-readme.txt
0
 
anushahannaAuthor Commented:
mx, that part is done, and i can see the effect: replace9.mde has under Tools-> Add-ins->Find and replace; but test.mdb does not have that option (both are access 2000).

you would expect that option to be shown in all access database on that machine?
0
 
DatabaseMX (Joe Anderson - Microsoft Access MVP)Database ArchitectCommented:
"you would expect that option to be shown in all access database on that machine?"
Definitely.


Capture1.gif
0
 
anushahannaAuthor Commented:
that is what i would have though, too..

i know the install must have worked because that option is seen on the F&R mde..

to install, I just clicked on install, and it just done..

any thoughts what i can try differently..
userdb.jpg
fr90.jpg
0
 
DatabaseMX (Joe Anderson - Microsoft Access MVP)Database ArchitectCommented:
Can you upload 'test.mdb' ?

OK ... wait, that first JPG is a *Custom* Tools menu ... look at the items.

How down the Shift Key while opening the db ... then see if you get the *normal* Access menu ...

mx
0
 
anushahannaAuthor Commented:
mx, just got access to check again..

yes, you are right - probably the custom tools menu.. when i shift key on a mdw-less DB, i get the regular tools menu.. when it PW protected, then i get the custom tools menu.. any thoughts, how i can get the regular tools menu on the pw protected db.

thanks
0
 
anushahannaAuthor Commented:
also, would the F&R work on a non-pw protected file the same way, say, as if the same DB should be password protected?
0
 
anushahannaAuthor Commented:
when i tried it on the non-pw database, i get the following message- the * says search in all, right? how do you tell it to search in all code?
search.jpg
0
 
Scott McDaniel (Microsoft Access MVP - EE MVE )Infotrakker SoftwareCommented:
You must click the various objects you wish to search in. For example, if you want to search Tables, click the button labeled "Tables".
0
 
DatabaseMX (Joe Anderson - Microsoft Access MVP)Database ArchitectCommented:
Yes, as noted by LSM, click the Tables, Queries .... Modules buttons below Search In.
Then, check
Find Only, No Replace
Log Finds/Changes
Find without asking

then finally ... Find

once done, click View Log

mx
0
 
anushahannaAuthor Commented:
how can i search if pw protected. if i use mdw, then i get only the custom tools menu..


error.bmp
0
 
DatabaseMX (Joe Anderson - Microsoft Access MVP)Database ArchitectCommented:
Can I ask why you would need to do that if ... you are not in development mode, ie you have bypassed startup code using holding Shift Key down ...?

mx
0
 
DatabaseMX (Joe Anderson - Microsoft Access MVP)Database ArchitectCommented:
You can ... if you really want to, add the Add-Ins menu to your custom Menu ... I just tried it and it works ... see screen shot:

mx
Capture1.gif
0
 
anushahannaAuthor Commented:
thanks a lot- i got it now.. i search for in modules and macros.. i searched for the subreport name, but it came back with nothing.. what exactly should i be searching for as..

all i need really is the code that populates the label, so i can change it, and that is in the sub-report.
0
 
DatabaseMX (Joe Anderson - Microsoft Access MVP)Database ArchitectCommented:
"what exactly should i be searching for as.."

Sorry, but I'm kind of lost at this point.  Maybe you could summarize exactly what the issue is at this point ?

mx
0
 
anushahannaAuthor Commented:
mx, yes, i was in dev mode yet .. what i did i tried to open a module, and it asked for password, and then it did not complain.. i would like to learn to add that to custom tools, too.. if it is quick and easy, kindly share how to do it.. if not, i would rather not distract away from the issue..
0
 
anushahannaAuthor Commented:
>>Sorry, but I'm kind of lost at this point.  Maybe you could summarize exactly what the issue is at this point ?

sure.

the label is the same in all the report, and it is displaying wrong data. it is a sub report. but I am not able to see the code behind the subreport. hence wondering if the subreport name is referenced in the modules, and see what logic is used to populate the label.

thanks
0
 
DatabaseMX (Joe Anderson - Microsoft Access MVP)Database ArchitectCommented:
"i would like to learn to add that to custom tools, too"
Well, that is pretty easy to do ... no code ...

Everything you need is here (A2003 and prior only)- no code ... see this link:
Everything you need is here (A2003 and prior only)- no code ... see this link:

http://www.jamiessoftware.tk/articles/menubars.html
       
Not sure it that article mentions it, but ... when you are in the Customize mode (dialog) ... if you hold down the Control key,

you can drop and drag (ie, copy) menu items from one place to another ... handy for making a new menu that is similar another one.

0
 
DatabaseMX (Joe Anderson - Microsoft Access MVP)Database ArchitectCommented:
ok ... well, you should ... be able to search for pretty much anything you want using F&R ... be sure to check all options in the Search In area ...

mx
0
 
anushahannaAuthor Commented:
thanks-
if the reportname whose picture is in the main question- that is what i want to search, right?

that is what is displaying the label in all the reports.
0
 
DatabaseMX (Joe Anderson - Microsoft Access MVP)Database ArchitectCommented:
Well, seems so ... this:

rpt_all_pinned_Data

mx
0
 
Scott McDaniel (Microsoft Access MVP - EE MVE )Infotrakker SoftwareCommented:
<the label is the same in all the report, and it is displaying wrong data. it is a sub report. but I am not able to see the code behind the subreport. >

Why are you not able to see the code behind the subreport? If you open this in Design mode, then you should be able to review the code (either manually or with F&R).

If you cannot actually get into Design mode, or if the VBA code has been protected, then you'll need to find another file where you can actually get to the code, or that is not protected.
0
 
anushahannaAuthor Commented:
mx, it has to be under macros or modules only, right?
0
 
anushahannaAuthor Commented:
LSM, there is no record source for the sub report, that is mentioned..

and as in #34191258, the only code behind the report is ...
Option Compare Database

Private Sub Report_Open(Cancel As Integer)
  Call format_fields
End Sub

Private Sub format_fields()
    Custom1.Caption = CustomData(5)
    Me.Custom1.FontSize = CustomData(9)
    Me.Custom1.ForeColor = QBColor(CustomData(10))
    Me.Custom2.Caption = CustomData(6)
    Me.Custom2.FontSize = CustomData(9)
    Me.Custom2.ForeColor = QBColor(CustomData(10))
    Me.Custom3.Caption = CustomData(7)
    Me.Custom3.FontSize = CustomData(9)
    Me.Custom3.ForeColor = QBColor(CustomData(10))
    Me.Custom4.Caption = CustomData(8)
    Me.Custom4.FontSize = CustomData(9)
    Me.Custom4.ForeColor = QBColor(CustomData(10))
End Sub

Open in new window

0
 
DatabaseMX (Joe Anderson - Microsoft Access MVP)Database ArchitectCommented:
"the label is the same in all the report, "
What label ?

"and it is displaying wrong data. "
What data is it supposed to be displaying ?

0
 
anushahannaAuthor Commented:
>>What label ?

label of the company (just has name and address etc) and it is coming from the sub-report..

>>"and it is displaying wrong data. "

the address needs update- that is why i am trying to get to the code behind the sub-report(label)
0
 
DatabaseMX (Joe Anderson - Microsoft Access MVP)Connect With a Mentor Database ArchitectCommented:
"mx, it has to be under macros or modules only, right?"
To be sure, search Forms, Reports, Macros & Modules ... Reports for sure.

mx
0
 
anushahannaAuthor Commented:
when i included those 4, then i get
Found String in:Reports!<ReportName>!Data Subform.SourceObject
...many more reports like that, and then finally
Found String in:Report!rpt_all_pinned_Data.Name

in modules/macros, it is not finding it..

what other logic might be used to full the header info?
0
 
anushahannaAuthor Commented:
SouthMod, the app is to hold data entry from what is collected in form, and get reports on the data, especially at year end..

basically, the company has moved, so all i am trying to do is put the right (new) address on the header of the reports. header info (and footer) generally is trivial- the ownership is with the person to whom this custom software was sold to, who needs me to change this..

Do you still feel this is a ownership issue?

>>why you cannot use standard means to do change data in the application

Generally, the code will be right behind the report- that is how i have always seen it.. i can see from LSM's comment in #34290421, "If you open this in Design mode, then you should be able to review the code (either manually or with F&R)." too that he also would expect to see the code for the subreport right there.

"stamped"- is this is a technical stamp through code, or a ethical one you are talking about?
0
 
anushahannaAuthor Commented:
SouthMod, by stamped if you meant password protection to get to design mode or the code, yes, i am using that password- the db is secured 2 levels mdw and then password for the code/design. i am through that and valid in my attempt... jfyi-
0
 
anushahannaAuthor Commented:
thanks for your feedback, SouthMod.

sorry if i confused you on this point- the sw belonged to CompanyA and still does- all that has happened is that the company has moved to a different address.
example:
ee-company
SouthMod, Sr.Mod
ee-land, CA 12345

the company has moved to
ee-company
SouthMod, Sr.Mod
ee-ground, NY 67890

that's all.

this data is shown in all the reports printed, and obviously wrong, and just needs corrected.

Generally, you would be able to just go behind the subreport code and see how it is getting populated, and fix it. this is not straight forward- hence checking on the access experts.

From all of my questions, did i ever try to break anything without a password- i was only asking how to use the password I was having at hand.. yes, access with mdw is new to me.

the dev has long lost touch, and  is not able to tracked.. the good thing is we have the right passwords.. but still eluding..

so by stamped, you did not mean a technical stamp, did you?
0
 
anushahannaAuthor Commented:
finally tracked where the info was being called from one of the modules.. fixed it.

Thanks for all the expert's help...

and to SouthMod also for the alertness and watchfulness..
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.