A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Setting Up & Running Reports
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

drawing excel like grids on access reports



 
 
Thread Tools Display Modes
  #1  
Old April 16th, 2010, 04:19 PM posted to microsoft.public.access.reports
Access infant
external usenet poster
 
Posts: 14
Default drawing excel like grids on access reports

Hi All,
I want to draw excel like grids on my access reports. The line should start
from the top of each label in the page footer to the bottom of the
corresponding text box in the page footer.(For each text box in the detail
section, there's one unbound text box in the page footer to display totals).
I don't know how to do this. can anyone please help me?
--
from
chanakya
Baruva
  #2  
Old April 16th, 2010, 10:36 PM posted to microsoft.public.access.reports
Duane Hookom
external usenet poster
 
Posts: 7,177
Default drawing excel like grids on access reports

Can't you use rectangle or line controls in your various sections? These
should work unless your sections are set to Can Grow. If this is the case,
you may need to use the Line method in the report's On Print events to draw
the lines.

--
Duane Hookom
Microsoft Access MVP


"Access infant" wrote:

Hi All,
I want to draw excel like grids on my access reports. The line should start
from the top of each label in the page footer to the bottom of the
corresponding text box in the page footer.(For each text box in the detail
section, there's one unbound text box in the page footer to display totals).
I don't know how to do this. can anyone please help me?
--
from
chanakya
Baruva

  #3  
Old April 17th, 2010, 04:00 AM posted to microsoft.public.access.reports
Access infant
external usenet poster
 
Posts: 14
Default drawing excel like grids on access reports

I have tried what you told but it looks quite awkward when there's different
groupheaders in between on a page. So, I will choose to use the code to draw
lines across different groups using line method if only i can get help from
you
--
from
chanakya
Baruva


"
  #4  
Old April 17th, 2010, 08:02 PM posted to microsoft.public.access.reports
Duane Hookom[_4_]
external usenet poster
 
Posts: 316
Default drawing excel like grids on access reports

Any help from you regarding my comments on Can Grow? I generally set the tag
property of controls that I want to add borders. I can then loop through the
controls in a section and use the line method to draw vertical or horizontal
lines using the Left, Top, Width, and Height of the appropriate controls as
starting and ending points of the lines.


--
Duane Hookom
MS Access MVP


"Access infant" wrote in message
...
I have tried what you told but it looks quite awkward when there's
different
groupheaders in between on a page. So, I will choose to use the code to
draw
lines across different groups using line method if only i can get help
from
you
--
from
chanakya
Baruva


"


  #5  
Old April 18th, 2010, 04:49 PM posted to microsoft.public.access.reports
Access infant
external usenet poster
 
Posts: 14
Default drawing excel like grids on access reports

Actually i have added some unbound controls in the different group footers
and the report and page footers also. so, in order to make sure that the line
would be straight, can i take the left of a control in the detail section
only and store it in a module level variable and use the same value in all
sections 'on print' event. so that the line could be straight ? If you don't
feel that i am expecting too much of you, could you please give me code for
one section which i can use with changes (if needed) for other sections
also.Or at least direct me to a link where i can get some sample code.
--
from
chanakya
Baruva


  #6  
Old April 18th, 2010, 08:17 PM posted to microsoft.public.access.reports
Duane Hookom[_4_]
external usenet poster
 
Posts: 316
Default drawing excel like grids on access reports

I'm not exactly sure how you have these controls setup. But again, I like to
put something in the tag property that identifies if a control should have
lines on its left, top, right, or bottom. Consider entering any combination
of LTRB for these sides into the tag. Then you might have code in the On
Format event of a section like:

Dim ctl as Control
dim strTag as String
For Each ctl in Me.Controls
strTag = ctl.Tag & ""
If Instr(strTag,"L") Then 'left
Me.Line (ctl.Left, clt.Top)-Step (0,clt.Height)
End If
If Instr(strTag,"T") Then 'top
Me.Line (ctl.Left, clt.Top)-Step (clt.Width,0)
End If
'duplicate similar code for left and bottom
'the line method uses the first (x,y) as the x and y position in the
section
' the Step argument is used to set the (x,y) to relative to the first
(x,y)
Next


--
Duane Hookom
MS Access MVP

"Access infant" wrote in message
news
Actually i have added some unbound controls in the different group footers
and the report and page footers also. so, in order to make sure that the
line
would be straight, can i take the left of a control in the detail section
only and store it in a module level variable and use the same value in all
sections 'on print' event. so that the line could be straight ? If you
don't
feel that i am expecting too much of you, could you please give me code
for
one section which i can use with changes (if needed) for other sections
also.Or at least direct me to a link where i can get some sample code.
--
from
chanakya
Baruva


 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 08:43 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.