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

Report Name Headers and Form Field Fill

Status
Not open for further replies.

kickingbac

Technical User
Apr 4, 2008
5
US
Hi guys and gals,

I have a table from which I produce a report seperated by alphabetical listing with a space between each letter. I would like to place a bold letter atop each section corresponding with the alphabet letter listing. I cannot figure out where or how to place this in the design.

Also I have the table with each persons phone number, last name, firstname, and a box that I would like to populate with lastname, firstname automatically from input in the lastname and firstname input fields. Can this be done on the same table or do I need a querry or relationship to do this?

Any help will be greatly appreciated.

kickingbac


kickingbac
 
It seems likely you are grouping by the first character of the lastName. If so, in the Group Header, place a text box with this control source:

=Left(MyLastNameFieldName,1)

---

If all the fields for a desired report are present in a single table then that table can be used as the record source for the report. No query or relationship would be required.

--Lilliabeth
 
Awesome Lilliabeth! The first worked great.

I should have been more precise on the second question.

The table stores all the info. In that table I have all the fields. Using a input form I type in the last name in one box which populates the lastname field for the table. I then type in the firstname in another binput box which populates the firstname filed on the same table. Within that same table I want to populate a seperate filed called name which inputs lastname,firstname in a box on the input form. It does this in the form but does not save int he table. How do I get it to populate int he same table. I have to manually copy and paste the info in the table but the form shows correctly.

Thanks again for the assistance! You are awesome!!!!
 
If you have a lastname field and a firstname field then you don't normally want to store the full name. If you want to display the LastName,FirstName, just create an expression in the form or report.

Duane
Hook'D on Access
MS Access MVP
 
Thanks Duane, I appreciate the info. But I already have an expression in the form which shows just that but it does not save to the table where I have the output of both names. I am trying to have the same table store all three columns using the form I use to input the names. I use the table for internet access to display the name filed which should be the lastnmae, firstname.

Maybe I am making this more complicated than need be. I just thought there was a way to update a column on a table by referencing two other columns on the same table.

Any suggestions will be greatly appreciated. Thanks so much.
 
Sometimes there is a reason to store a value that can be deduced from other values, but unless there is a good reason, it's very poor database practice to store stuff twice. I can't think of any reason to store a person's name twice, can you?

--Lilliabeth
 
Your absolutely right.

I just thought that you could store one fieled as a value and another as another value and one more filed as the two values combined. That is all I really want.

I don't want to hire a contractor to come in and rewrite the sql database code to populate those two fields into one on the output website.

If this can't be done then I thank you again for your assistance. If it can be done then I appreciate it all the more.
 
Can we assume your "output website" gets information from a query? If so, just add a column in your query:
Code:
   Fullname: LastName & ", " & FirstName

I'm not sure why you think this would involve a contractor.

If you really must store the value in your table, you can use the before update event of the form to set the value of the FullName field:
Code:
   Me.Fullname= Me.LastName & ", " & Me.FirstName

Notice I didn't use the field named "name" since "name" is a reserved word.

Duane
Hook'D on Access
MS Access MVP
 
Thank you so very much. I think I understand that now. The reason for a contractor is that our company used a contractor to set up the site which accesses the data from this access database to a sql server dbase and we unfortunately were told to "not touch it" since the contractors are responsible for any changes. we can change our Access dbase though so that is what i am trying to do.

You all have been great and I appreciate all your replies! Thank God for Access geniuses like yourselves that help us less knowledgable out! :)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top