473,395 Members | 2,796 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

vertical line between snaking columns in ms access reports

6
In Access 2003 I have a multi-column report (3 columns).
I would like to get 1 continuous vertical line from the top of the page to the bottom of the page, between columns 1 and 2 and between columns 2 and 3.

Is there anyway to create this line?

If so, is there any way to print this line only if there would data in the column to the right of the line?
Aug 16 '08 #1
5 8926
ADezii
8,834 Expert 8TB
The code to dynamically draw Lines in a Report must be placed in the Print() Event of the Report's Detail Section. The following code will draw a Vertical Red Line, 25 Pixels wide, exactly 1000 Pixels from the Left Margin of the Report, spanning the entire Vertical Length of the Report.
Expand|Select|Wrap|Line Numbers
  1. Private Sub Detail_Print(Cancel As Integer, PrintCount As Integer)
  2. Dim lngColor As Long
  3.  
  4. Me.ScaleMode = 3    'Pixels
  5. Me.DrawWidth = 25   'in Pixels
  6.  
  7. lngColor = RGB(255, 0, 0)       'Red
  8.  
  9. Me.Line (1000, 0)-(1000, Me.ScaleHeight), lngColor
  10. End Sub
Aug 16 '08 #2
appmab
6
Thank you! I can now get the lines. I am, however, having a slight problem. I'm getting a slight break in the lines on the report between detail lines and also between groups, so it's not an absolutely solid line.

My report would be:

Allen, Michael
100 Main St.
Anyplace, US
..Allen car1
..Allen car2

Axelrod, Timothy
200 Elm St
Sunrise, US
.. Axelrod car1
.. Axelrod car2

The personal information is in a group header and the cars are in the detail section.

I'm getting slight breaks in the line between Allen car 1 and Allen car 2, between Alexrod car 1 and Axelrod car2, and between Allen Car 2 and Alexrod, Timothy.
Am I doing something wrong, or is there any way to fix this?

Also, the data in the columns are not always the same length because people have different number of cars. The line is only extending down as far as the last detail line, and I understand why, but is there any solution for that?
Thank you.
Aug 16 '08 #3
ADezii
8,834 Expert 8TB
Thank you! I can now get the lines. I am, however, having a slight problem. I'm getting a slight break in the lines on the report between detail lines and also between groups, so it's not an absolutely solid line.

My report would be:

Allen, Michael
100 Main St.
Anyplace, US
..Allen car1
..Allen car2

Axelrod, Timothy
200 Elm St
Sunrise, US
.. Axelrod car1
.. Axelrod car2

The personal information is in a group header and the cars are in the detail section.

I'm getting slight breaks in the line between Allen car 1 and Allen car 2, between Alexrod car 1 and Axelrod car2, and between Allen Car 2 and Alexrod, Timothy.
Am I doing something wrong, or is there any way to fix this?

Also, the data in the columns are not always the same length because people have different number of cars. The line is only extending down as far as the last detail line, and I understand why, but is there any solution for that?
Thank you.
I would actually have to physically look at the Report and its layout, in order to even venture a guess as to what is causing this.
Aug 17 '08 #4
appmab
6
Thanks. I can't send the report due to the data. I could send the code. I tried this on all my other reports which I am making snaking columns which I could send, and unfortunately (or fortunately) it is working with them. So it definitely helped me on the others. I'll have to keep plugging away on this one. Thank you.
Aug 20 '08 #5
Changing ScaleHeight to Height seemed to solve the problem for me.

I was getting gaps because some fields had CanGrow = true
Oct 1 '10 #6

Sign in to post your reply or Sign up for a free account.

Similar topics

4
by: intl04 | last post by:
I have a memo field that is included in some Access reports I created. Is there some way for the memo field to display nicely formatted text, with line breaks between paragraphs? Or is it necessary...
3
by: James P. | last post by:
Help, In Access 2000, I have a bound column - textbox. As soon as I type three dots (periods) in the textbox and keep typing (more dots or anything else), it automatically converts the three...
6
by: (Pete Cresswell) | last post by:
I've got a situation where the user is expanding nodes in a TreeView and below a certain level, the child nodes become too numerous for them to deal with easily on a straight-up sequential list. ...
16
by: cyranoVR | last post by:
This is the approach I used to automate printing of Microsoft Access reports to PDF format i.e. unattended and without annoying "Save As..." dialogs, and - more importantly - without having to use...
3
by: stawicki | last post by:
I have a report that uses snaking columns to generate four 2.5 inch columns in landscape mode. It is used to print a double-sided document whch is then cut down the middle and bound. The...
1
by: diesel | last post by:
I have an OWC chart that works great Our client has requested that we add a vertical line at a specific point on the chart For example the horizontal axis contains 2,4,6,8 The vertical line...
16
by: JoeW | last post by:
I'm utilizing a database that I created within MS Access within a program I've created in VB.NET. I am using the VB front end to navigate the information, but want to be able to print a report,...
0
by: ashkaan57 | last post by:
Hi, I am trying to put a vertical line between two DIVs that are contianers for menu and content. I added another DIV in between them and set the background-image and repeat-y but it doesn't...
1
by: senort01 | last post by:
Is it possible to create a table within MS Access Reports so that horizontal data stays aligned? For example, I have two columns of data. The left column is fixed, the right column will be...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.