Results 1 to 4 of 4
  1. #1
    RichardAnderson is offline Advanced Beginner
    Windows 7 64bit Access 2010 32bit
    Join Date
    Jun 2013
    Posts
    74

    Make Empty Field Fall To Bottom

    I have a form that has 2 fields in the OrderBy property. Status and ProduceByDate. It is put into the property as follows.. Status, ProduceByDate. When the form is opened it sorts perfect except for one thing I dont like. If the ProduceByDate is empty, it is sorted on top of other records with dates. I do not want to do DESC because I need the dated nearest in the future to be above ones further out into the future. I thought about put ProducedByDate Is Not Null in the filter property but I still need these records to show. I just want them at the bottom.

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,623
    Try:

    Status, Nz(ProduceByDate,#12/31/2999#)
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  3. #3
    RichardAnderson is offline Advanced Beginner
    Windows 7 64bit Access 2010 32bit
    Join Date
    Jun 2013
    Posts
    74
    I tried that but it prompts for user input

  4. #4
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,623
    Well, that was wild thought off top of my head. Just tried it. Works. But slight error in my suggestion. Need [].

    Try:
    [Status], Nz([ProduceByDate],#12/31/2999#)

    However, even when I ommitted the [] I did not get popup prompt so something else may be wrong with your statement. Are both fields actually in the form RecordSource? Are they spelled correctly?
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

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

Similar Threads

  1. Replies: 4
    Last Post: 03-15-2013, 04:00 AM
  2. Replies: 2
    Last Post: 04-23-2012, 10:13 PM
  3. Replies: 4
    Last Post: 11-20-2011, 01:08 PM
  4. Delete Field if Empty?
    By bpowers2010 in forum Reports
    Replies: 1
    Last Post: 07-10-2010, 12:04 AM
  5. empty field
    By amber mara in forum Access
    Replies: 2
    Last Post: 05-05-2010, 01:46 PM

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