Sabtu, 23 November 2013

RE: [MS_AccessPros] Sub reports borders should touch main reports Page footer

 

Khalid-

 

The Debug.Print statement sends its results to the Immediate Window, which you can open by pressing CTRL+G.

 

As for Twips, see: http://en.wikipedia.org/wiki/Twip

 

I'm not undestanding what it is you want.  Did you draw horizontal lines in the Detail section?  Of course, these lines won't go all the way to the bottom if the data in the Detail section doesn't fill a page.  Are you wanting the lines to continue down the page?  You could do a lot more experimenting with the Line method, but perhaps an easier way is to design a .jpg that you load as the background to the report.  Draw horizontal lines in the graphic the same distance apart as the height of your detail section.

 

John Viescas, Author

Microsoft Access 2010 Inside Out

Microsoft Access 2007 Inside Out

Microsoft Access 2003 Inside Out

Building Microsoft Access Applications

SQL Queries for Mere Mortals

http://www.viescas.com/

(Paris, France)

 

 

 

From: MS_Access_Professionals@yahoogroups.com [mailto:MS_Access_Professionals@yahoogroups.com] On Behalf Of Khalid Tanweer
Sent: Saturday, November 23, 2013 9:06 AM
To: MS_Access_Professionals@yahoogroups.com
Subject: Re: [MS_AccessPros] Sub reports borders should touch main reports Page footer

 




John,

 

That's great! Its perfect. The box is also in bold, wonderful. Thanks alot as you are always with me to resolve the issues and going from start to complete the problem. My boss would really appreciate it.

 

You wrote:

The Debug statements showed Top = 0, Left = 0, Width = 11518 (8 inches or 20.32 cm), Height = 15120 (10.5 inches or 26.67 cm).  The result is a .02 inch border drawn 20 Twips inside the defined width of the report based on the margins.

 

Where can i see these conversions which you mentioned above and study them?

 

One more thing can we make this report more robust and have a try on one more thing.

 

At the detail section around controls i have DRAWN LINES MANUALLY excluding left and right border, and they are moving down along the rows, but if rows are fewer and not touching Page Footer the LINES WHICH I DRAWN aside the controls may move up to Page Footer.

 

Regards & Thanks once again,

Khalid

 

 

On Friday, November 22, 2013 10:51 PM, Duane Hookom <duanehookom@hotmail.com> wrote:

 

Khalid,

Typing "Line Method" into the ask a question box allows you to see information about using the line method including:

"The width of the line drawn depends on the DrawWidth property setting. The way a line or rectangle is drawn on the background depends on the settings of the DrawMode and DrawStyle properties."

If you need more help, you can enter DrawWidth into the search box.

Duane Hookom MVP
MS Access

________________________________
> From: khalidtanweerburrah@yahoo.com 
>
> John
>
> As you mentioned it's a method of trial and errors to get it exactly
> right. I've played many many times and come to this stage that on
> preview of report i can see complete box on the page.
>
> But when i do print left side is completely not printing. Again i do
> copy my code, please see still am i making any mistake. Also is there
> any way to get this box "Bold" and also if left side is not coming in
> print range is there any connection with page set up of access/office ?
> I did played there also but cannot resolve it yet.
>
> Sub DrawLine()
> Dim rpt As Report, lngColor As Long
> Dim sngTop As Double, sngLeft As Double
> Dim sngWidth As Double, sngHeight As Double
>
> Set rpt = Reports![COO Aventis]
> ' Set scale to inches.
> rpt.ScaleMode = 1
> ' Top inside edge.
> ' Calculate the top of the rectangle
> sngTop = rpt.ScaleTop - 20
> '------------------------
> ' Left inside edge.
> sngLeft = rpt.ScaleLeft - 1 ' -1(putting this value in +ve and
> increasing value decreases top of box)
> '--------------------------
> ' Width inside edge.
> sngWidth = rpt.ScaleWidth - 2 'This increases Right width of box
> '-----------------------------
> ' Height inside edge.
> sngHeight = rpt.ScaleHeight - 0.75
> '-------------------------------
> ' Make color black.
> lngColor = RGB(0, 0, 0) ' Black
> '------------------------------
> ' Draw line as a box.
> rpt.Line (sngTop, sngLeft)-(sngWidth, sngHeight), lngColor, B
> End Sub
>
> Regards, Khalid
>
>
> On Wednesday, November 20, 2013 2:10 PM, John Viescas <JohnV@msn.com> wrote:
>
> Khalid-
>
> You have set the ScaleMode to millimeters, which should be a small
> enough increment to allow you to adjust a bit at a time until it comes
> out how you want it. You need to play with this:
>
> ' Left inside edge.
> sngLeft = rpt.ScaleLeft + 1
>
> If the line is too far from the edge, try adding negative values. If
> it's not far enough from the edge, make the amount you add larger until
> the line moves until you want it. I have often found it's a matter of
> trial and error to get it exactly right.
>
> John Viescas, Author

 




__._,_.___
Reply via web post Reply to sender Reply to group Start a New Topic Messages in this topic (17)
Recent Activity:
.

__,_._,___

Tidak ada komentar:

Posting Komentar