Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Making report results go to the right instead of down

Status
Not open for further replies.

storl2

Programmer
Jun 3, 2004
47
US
Ok, hopefully this is a simple one.

I have a subreport with a couple of groupings that list the results of the query that the report is tied to like this:

Group heading
result1
result2
result3
etc.

The results go down, but I want them to go right, and then down, as if it were typing out the results on a line until it got to the end of the line and went to the beginning of the next line.

What I want to do is make the report look like this:

Group heading
result1 result2 result3 result4
result5 result6 etc....

Is there a way to do this?
 
Use New Row or Col on the group header, and then set up the columns in your page setup to Across then down. I believe that should get you what you want.
 
Yeah, that's kind of what I'm going for. Sorry, I should have given more information.

The report is a subreport that shows the community service events for each month. What I am trying to do is have each month go across to the right and then down, but the results under each month go down. When I set the page set up to go across, it makes everything go across. I'm not sure if it's the way I have it grouped or what. A little more detailed view would be something like this:

January February March
Event1 Event1 Event1
Event2 Event2 Event2

April
Event1
Event2 etc.........
 
I am having the same problem, if you figure it out, please post it. I have been looking everywhere for a solution. You would think it would be something simple.

AJ
 
Hi folks,

I am not clear as to the extent of project, so the following suggestions may or may not be feasible.

1. A sub report for each month or;

2. Concatenate a string for each event (event 1, event 2) and then display each string result horizontally or;

3. Have you played with the report columns and column layout under Page Setup?

Cheers,
Bill
 
My table has two fields: MMCNumber and Date_of_receipt. I want to list the MMCNumbers in columns by month.

In Design View, sort on MMCNumber. Show MMCNumber footer - expand footer to about half an inch.

Under Page Header, create a rectangular box with the following dimensions in Twips: top = 60, left = 1920, width = 12240, height = 240.

Inside this rectangle place text boxes to hold the month names. Their dimensions in inches will be: width = .7104, height = .1667
240 twips = .1667 inches

The first text box will have =#1/1/2004# as control source. The rest of the text boxes will be based on this, eq. =DateAdd("m",1,[txtMth0]), =DateAdd("m",2,[txtMth0]), etc.

Click on the Detail Bar and put the following code:

Private Sub Detail_Format(Cancel As Integer, FormatCount As Integer)
Dim lngDuration As Long 'days of tour
Dim lngStart As Long 'start date of tour
Dim lngLMarg As Long
Dim dblFactor As Double
Dim holda As Integer
Dim holdb As String
Dim holdc As Integer

'put a rectangle in your page header that starts 1/1 and goes to 12/31
lngLMarg = Me.boxTimeLine.Left
dblFactor = Me.boxTimeLine.Width / 365
holda = Month(Me![Date_of_Receipt])
holdb = holda & "/1/2004"
holdc = DateDiff("d", holdb, Me![Date_of_Receipt])
lngStart = DateDiff("d", #1/1/2004#, Me.[Date_of_Receipt]) - holdc
'lngDuration = DateDiff("d", Me.[Start Date], Me.[End Date])

Me.MMCNumber.Width = 10 'avoid the positioning error
Me.MMCNumber.Left = (lngStart * dblFactor) + lngLMarg
' Me.Text97.Left = (30 * dblFactor) + lngLMarg
Me.MMCNumber.Width = (dblFactor) * 30
Me.MoveLayout = False
End Sub

I Think I covered it all. If you would like a database sample, email me at fneily@hotmail.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top