Selasa, 16 Agustus 2022

Re: [MSAccessProfessionals] Report, when field blank look up standard note

Greetings from just over the hill east of you (I assume).  You haven't shown your code so it's hard to know what might be going wrong with it.  In general:

If Len(Me.WarrantyNote & vbNullString) = 0 Then
  Me.WarrantyNote = DLookup(...)
End If

You can use a similar test to hide the labels.  The place to do that is typically the format event of the section containing them on the report.

Paul

------ Original Message ------
From "michael simpson via groups.io" <saccity101=yahoo.com@groups.io>
Date 8/16/2022 2:01:02 PM
Subject [MSAccessProfessionals] Report, when field blank look up standard note

Good day - 
I am working on updating automating my database to send out invoices, 
I have two issues, 
I have a Form (fmWO) which I publish to a report (rptWO) and then print to a PDF to email to clients. 

First I generally us a standard warranty on my work orders, so I don't type it in unless something atypical. 
Want to if field WarrantyNote = "" then lookup standard note. 

Second issue: if some fields are not filled in then hide the label and message box 

First thought was to put something on the on load event, however, getting "invalid use of Null" error.
The on current event is triggered when I close the form,  

Take care,

Mike the Plumber

Sac City Plumbing

Tidak ada komentar:

Posting Komentar