I currently am making a database that accomplishes a canned report. Part of it is an images "Attachment " to the report. I have figured out how to put the pictures in but I need to put 2 images side by side. The best way I can figure to do that is by placing a subreport next to the original in the detail section. I cannot find any information on how to figure odd and even numbers. In the detail section I want to put the odd numbers and in the subreport put the odd numbers. This way they should line up. Can anyone tell what the query should be to only show odd or even numbers? You would make me a happy employee!!!
Creating a Images page in reports
Collapse
X
-
Tags: None
-
-
My calculation is based off the user establishing Image numbers. Example 1, 2, 3, 4, 5. Can I use the MOD in the VBA of the report to only display the evens or odds? I thought I had to use them in a query.Comment
-
Sorry Nico but I am a novice when it comes to using Mods. So I use the suggestion in the criteria correct?Comment
-
The MOD function (when using the value 1) will return a 0 or a 1 depending on the value of the passed variable.
When you have an imagenumber 1,2,3,4,... using in your query:
SELECT [imagenumber], [imagenumber] MOD 1 As OddEven, ...
Will return:
1, 0, ..
2, 1, ...
3, 0, ...
4, 1, ...
etc.
This OddEven field can be used to filter the "0" records for the mainform and the "1" records for the subreport.
Getting the idea ?
Nic;o)Comment
-
using the following statement
SELECT [imageno], [imageno] MOD 1 As OddEven
FROM PictureTable;
Got me
1 0
2 0
3 0
4 0
5 0Comment
-
-
Ok. Thanks. It looks great. You don't know how long I hve been looking for a solution. Have a great week.Comment
-
In a database I want to add a record to several tables that are not currently open on the form. I used to toy with recordsets but have since forgotten (old age). How do I add a record and then insert some text? The filed I want to insert is an ID (I call it FACID for Facility ID that is my common link to all tables because the tool reports on facilities). Any help would be appreciated.
NICO you know?Comment
Comment