Results 1 to 9 of 9
  1. #1
    George is offline Competent Performer
    Windows 7 32bit Access 2007
    Join Date
    Feb 2012
    Posts
    295

    Setting Field positions

    My database consist of a main form "Orders" and a subform "Order Details". The subform has several fields including: Quantity, Unit Cost, Product Code, Description etc.



    Problem: I want "Product Code" to be the first field so I arrange it like that in the design view, but it does not appear like that in the form view; the Quantity stays as the first field. I have even tried shifting the fields around in the form views and this works but when the form is closed and reopened the "Quantity" field reverts to first position.

    Setting the field width is the same problem it revert to original column width.

    would be grateful for some assistance

  2. #2
    June7's Avatar
    June7 is online now VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,929
    Is form in Datasheet view mode?
    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
    George is offline Competent Performer
    Windows 7 32bit Access 2007
    Join Date
    Feb 2012
    Posts
    295
    thank.

    Yes it is in datasheet view

  4. #4
    CJ_London is offline VIP
    Windows 8 Access 2010 32bit
    Join Date
    Mar 2015
    Posts
    11,430
    datasheet column positions are not affected by the form design. To change the order of columns in a datasheet, open in datasheet view, click on a column heading and drag to the position required. Then save the datasheet. If it is a subform, it is better to do this from the form itself rather than via the main form subcontrol

  5. #5
    George is offline Competent Performer
    Windows 7 32bit Access 2007
    Join Date
    Feb 2012
    Posts
    295
    Thanks. I have been trying that before and now but it just doesn't work. Do you have any other suggestions?

  6. #6
    June7's Avatar
    June7 is online now VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,929
    The technique works for me. I have done it from the subform container.

    If you want to provide db for analysis, follow instructions at bottom of my post.
    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.

  7. #7
    CJ_London is offline VIP
    Windows 8 Access 2010 32bit
    Join Date
    Mar 2015
    Posts
    11,430
    it works for me as well, but if you want to set it in code take a look at the columnorder property

    https://msdn.microsoft.com/en-us/lib...ffice.11).aspx

    You'll find links at the bottom for also setting widths, hiding and freezing columns and setting row heights

  8. #8
    George is offline Competent Performer
    Windows 7 32bit Access 2007
    Join Date
    Feb 2012
    Posts
    295
    Thanks to all of you for your assistance, however I think I have stumbled across a simple solution:

    Open the form in form view rearrange the fields as desired, by dragging. Open the property sheet. Click on any of the columns until the property sheet display changes to show a list with column count. change the column count. In my case I change it to 6 from 1 - Don't know if the number matter though. And that all. The field tick where you have them.

  9. #9
    CJ_London is offline VIP
    Windows 8 Access 2010 32bit
    Join Date
    Mar 2015
    Posts
    11,430
    As suggested in post #4

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

Similar Threads

  1. Field Positions
    By MaineLady in forum Access
    Replies: 3
    Last Post: 07-25-2015, 05:18 AM
  2. Replies: 2
    Last Post: 12-04-2014, 11:09 AM
  3. Replies: 3
    Last Post: 03-13-2014, 11:21 PM
  4. Replies: 3
    Last Post: 09-26-2012, 01:24 PM
  5. Calculating race finishing positions
    By Coheeba in forum Queries
    Replies: 4
    Last Post: 09-01-2011, 12:44 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