VB coding help sought

D

Debbiedo

How can I show only the data that is not not null without suppressing
the record containing the null data?

My Table (Driver) looks like this:


ID ID2 ID3 Color Car Name
1 1 1 Red Joe
1 1 2 Red Jack
1 2 3 Blue GM John
1 2 4 Blue GM Jill
1 2 5 Blue GM Jayne
1 3 6 Yellow GM Jonas


Grouped by ID (Group Heading Section One), then color
(Group Heading 2). Car field is ALWAYS either blank (or Null)
and ONE car name (e.g. GM-name varies).

I want Access report to look like this
--------

ID 1 Car GM (in Group Heading Section One)


RED (Group Heading 2)
Joe (Detail)
Jack (Detail)


Blue (Group Heading 2)
John (Detail)
Jill (Detail)
Jayne (Detail)

Yellow (Group Heading 2)
Jonas (Detail)
------------

(Note: GM is displayed only once at the top of the page.) Right now,
a blank is displayed. If I group by car and suppress null, the
records
that have a null value in the field Car do not display.

Can this be done? The blank data in the Car field is showing first.
I
can't sort in descending order because I am referencing an Access sql
query that, among other things, is sorting ID, ID2, ID3 in ascending
order. It is important that this remain like this. In most cases (but
not all of course), the Car record is null or blank if ID2 = 1.

I am thinking I may have to pass the value to a variable. If so, how?
I
need to have this coded in VB because eventually it will be
converted to Crystal Reports.

Thanks in advance

Deb
 
M

Marshall Barton

Debbiedo said:
How can I show only the data that is not not null without suppressing
the record containing the null data?

My Table (Driver) looks like this:

ID ID2 ID3 Color Car Name
1 1 1 Red Joe
1 1 2 Red Jack
1 2 3 Blue GM John
1 2 4 Blue GM Jill
1 2 5 Blue GM Jayne
1 3 6 Yellow GM Jonas

Grouped by ID (Group Heading Section One), then color
(Group Heading 2). Car field is ALWAYS either blank (or Null)
and ONE car name (e.g. GM-name varies).

I want Access report to look like this
--------
ID 1 Car GM (in Group Heading Section One)

RED (Group Heading 2)
Joe (Detail)
Jack (Detail)

Blue (Group Heading 2)
John (Detail)
Jill (Detail)
Jayne (Detail)

Yellow (Group Heading 2)
Jonas (Detail)
------------
(Note: GM is displayed only once at the top of the page.) Right now,
a blank is displayed. If I group by car and suppress null, the
records
that have a null value in the field Car do not display.

Can this be done? The blank data in the Car field is showing first.
I
can't sort in descending order because I am referencing an Access sql
query that, among other things, is sorting ID, ID2, ID3 in ascending
order. It is important that this remain like this. In most cases (but
not all of course), the Car record is null or blank if ID2 = 1.

I am thinking I may have to pass the value to a variable. If so, how?
I need to have this coded in VB because eventually it will be
converted to Crystal Reports.


Sorry, but trying to figure out how to display a value that
doesn't appear until later in a report is a messy afair.
What do you want to happen if there are several different
cars with the same ID and Color, just pick on at random??
If that's sufficient for your needs, then try using the Min
or Max function in the ID group header car text box
=Max(Car)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top