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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

SORTING OUTPUT FROM REPORT-need ideas

Status
Not open for further replies.

AccessNovice

Programmer
Feb 7, 2001
24
US
I am now doing an Access95 report and am struggling with how output is sorted, need help-any ideas. I have a control in the details section where it displays successfully displays comments...for each record(detail section). But I want the end result of the report to display the comments in this way; 1: high pressure 2: medium pressure 3: etc Currently I am trying to build a subform to hold text and label boxes. For the 1: 2: I just built labels with #s/colons in lable. After the first label I have a textbox for the comment, after the second lable(2:)I have another textbox to store the second comment. I have 9 text/labels on the subform-more than enough. For aesthetic reasons I don't want exter-example, if only 3 comments I want textboxex and labels 4-9 invisible. So on the subform's open event I coded, ...If txtOne.text is null then
txtOne.visible=false and lblOne.visible=false
end if
...I continue this code for all nine pairs of textbox and labels, that way only those with comments are visible.
Question-how do I get the output from the control(called Note) to sort 1: comment 2: another comment etc - should I have the subform(w/ its 9 labels & textboxes) in the date footer or where? What code/settings will be needed to get the output generated from the DetailSection's Note control? The Note is doing its job right, I just want its vertical display/record to be sorted horizontally, flanked by 1: 2: 3: ??
 
If your numbers are in the original table, then you can sort the fields using the group/sort button/command in the report design view. This seems like the obvious answer, so if you have tried it already and it didn't work, I do not know...However, if your numbers are merely lables, then I don't think they can be sorted. You might consider adding a column to the table to include the numbers, thus providing a means to sort. Note that to sort, the field must be a text field. Memo or other fields will not sort.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top