Results 1 to 4 of 4
  1. #1
    Akazuba is offline Novice
    Windows XP Access 2007
    Join Date
    Apr 2011
    Posts
    2

    Question Currency/text display issues

    I have a database and report of employee total compensation. (The "report" is an Access form, actually. There is one page for each record/employee.) It lists all the benefits offered by our organization, with the annual amount the organization pays vs. what the employee pays. If the employee does not opt for a certain benefit, I wanted the form to display "NONE" rather than just $0.00, because there are some benefits an employee is covered by but he/she pays nothing. So, since I knew I couldn't have text and numbers in the same column, I converted each whole column to text in Excel, with $ signs and commas, so that my currency figures would display correctly and I could keep my "NONE" values. (If I opted instead just to change the column format to text within Access, the currency figures don't display correctly.)

    The form works fine how it is now, but I want to make it as easy as possible to duplicate this with new figures, and I feel that what I did with using the TEXT() function in Excel perhaps would be difficult for some people who may be producing this print-out in the future.



    I understand that I cannot store text and numbers in the same column... but is there any workaround I could use just for my form? I tried making a query that had an IIF statement using the CCur() function, but it gives me #Error when I ask it to display text for the else portion.

    Any ideas??
    Last edited by Akazuba; 04-20-2011 at 07:49 AM. Reason: Issue resolved, changed title

  2. #2
    orange's Avatar
    orange is offline Moderator
    Windows XP Access 2003
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,726
    I think you'd be better off using numeric data and the Format(yourNumber,"Currency").
    It would be consistent.

    see http://www.techonthenet.com/access/f...ing/format.php for other Formats

  3. #3
    Akazuba is offline Novice
    Windows XP Access 2007
    Join Date
    Apr 2011
    Posts
    2

    Thumbs up

    Thanks, orange. I am a newbie to Access, so I didn't know about the Format() function. So I guess it works differently than the CCur() I was trying to use? I replaced where I had CCur() with your Format() instead in an IIF statement for my query like this:

    Expr1: IIf([MedRx] Is Null,"NONE",Format([MedRx],"Currency"))

    And now finally my form displays currency or "NONE" in the same field! Hooray!!

  4. #4
    orange's Avatar
    orange is offline Moderator
    Windows XP Access 2003
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,726
    Glad you got it solved.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 2
    Last Post: 03-23-2011, 11:43 AM
  2. Replies: 2
    Last Post: 11-16-2010, 10:55 AM
  3. Display field as text box
    By thekruser in forum Forms
    Replies: 5
    Last Post: 08-31-2010, 10:37 AM
  4. Replies: 2
    Last Post: 10-09-2009, 07:34 AM
  5. Replies: 1
    Last Post: 03-02-2006, 06:17 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums