Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Filter Blank Values 1

Status
Not open for further replies.

samusa

Programmer
Joined
Jan 1, 2001
Messages
107
Location
US
Could someone tell me how to make labels invisible if value of the field is blank, in a query or Report.

Sam
 
Ok.. I have to put the cursor on the Source and then right click on it and I get the option "insert Script Block -> Client"
Now i am getting error " Object doesn't support this property or method " txtN2.value"

When I tried If (IsNull(txtN2)) then...
I am getting error on second line " Object doesn't support this property or method 'l5.style'



Sam
 
Bottom line: why not using a snapshot instead of a DAP if the issue is only to publish a report ?
 
In your original post, you have L5.style.visibility, now your getting an error on l5?
When you type in L5. does a dropdown appear immediately after you type the period? If it doesn't, then it's not recognizing the control name. Sure you spelled everything correctly?
Like I said, I'm at a disavantage because I don't have your version.

PHV - in a snapshot you can't control the visibility of the controls. Anyway, while at this point it would be easier, I would like to figure out why it works on my part, but not his. The trouble is I can't reproduce his work on my version of Access. But, bottom line, it's his choice.
 
in a snapshot you can't control the visibility of the controls
Isn't a snapshot just a view of the result of a report ?
The OP said that the report printed well ..
 
Yes drop down appears immediately. Also I changed the name of the label. But all in vain.

Sam
 
PHV - I think I see our differences. You're looking at what he's creating as a regular report. So just produce the report in Access then change that to a STATIC html. I'm seeing it having a form functionality, going record to record. Thus some fields will have data, then they may not on the next record. I guess it's because I've always started from DAP's.
So, I assumed something wrong (wouldn't be the first time).
Samusa - is this an Access report you're translating to a DAP or did you originally create this as a DAP?
If you're exporting a report, they become a STATIC html web page. You can't dynamically change them like a "form". Can you create a DAP from the recordsource of your report?
At least, I can now hide fields.
 
Yes it is Access Report that I converted into DAP. But I am getting same error on a different DAP as well.

Sam
 
You are the Man!, Yes it worked. I created new page and pulled 2 fields from table on the page. It works fine. Now I have to figure out why it did not work on other page.

Sam
 
Ok .. I got it working. I put the Sub....End Sub script immediately after
<SCRIPT language=vbscript for=MSODSC event=current(info)>
<!--
FixEnabling
-->
</SCRIPT>

It did not generate any error.

Thank you fneily for your time and help

Sam
 
4 days, it's St. Paddy's Day, PHV recognized the static attribute, it's Friday, you figured the coding sequence in your version. Let's all have a drink tonight. Well, I am.
 
Yup.. I still need some help from you on creating Logon page so that users can access these DAP's with proper user name and passwords.

Have a nice weekend!



Sam
 
fneily: It works perfect when DataPageSize is 1. Since I need to change DataPageSize to "All" for generating reports but it pops up script error when I select "All".Any idea???

Sam
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top