Custom Sort Order in a Form


I am trying to set the sort order to a custom setting in an Access
Form (2k).  I have a field with data "High", "Medium", "Low".  If I
sort normal the data is viewed High, Low, Medium.  I want it to sort
H,M,L.  Is there anyway to do this?

12/2/2009 6:23:50 PM
access.forms 6864 articles. 2 followers. Follow

2 Replies

Similar Articles

[PageSpeed] 56

Create a table along the lines of:

RatingValue  SortOrder
High                    1
Medium              2
Low                     3

Sort on the SortOrder field.

Doug Steele, Microsoft Access MVP
(no e-mails, please!)

"jrizzo77" <> wrote in message
> Hello,
> I am trying to set the sort order to a custom setting in an Access
> Form (2k).  I have a field with data "High", "Medium", "Low".  If I
> sort normal the data is viewed High, Low, Medium.  I want it to sort
> H,M,L.  Is there anyway to do this?
> Thanks 

12/2/2009 6:54:32 PM
A couple of ways.  Use a calculated field --
   Sort_Field:  IIF([DataField]="Low", 1, IIF([DataField]="Medium", 2, 3))

Or use a translation table and join --
DataField  SortOrder
Low             1
Medium       2
High            3

Build a little, test a little.

"jrizzo77" wrote:

> Hello,
> I am trying to set the sort order to a custom setting in an Access
> Form (2k).  I have a field with data "High", "Medium", "Low".  If I
> sort normal the data is viewed High, Low, Medium.  I want it to sort
> H,M,L.  Is there anyway to do this?
> Thanks
> .
12/2/2009 7:59:01 PM

Similar Artilces:

How to create new lead for existing customer?
We are tracking all new leads, whether it is a new prospect or new lead within an existing customer. But when you enter a new lead, it will not allow you to pull an existing account. You have to rekey all company data. Any thoughts? Seems kind of like a backwards approach (which is why there's no option to do this). I would think you would just create a new contact inside an existing account. -- Brandon IT Director Presentations Direct - Office Equipment & Supplies "Jan Kratochvil" <Jan>...

Form event not firing on change
I am using a pop-up calendar form that is called from my main form. GotFocus and MouseDown events on the main form are calling the popup calendar. Once a day has been selected the last thing that happens is the originating control (the date field on my main form) is being set to the value of the date selected. This method does not fire the Change, BeforeUpdate, nor AfterUpdate events. I have looked at RaiseEvent, but the statement that is setting the value of the originating control is in calendar form module not the main form module. I also tried putting the onupdate code in a...

Calculate total amount on continuous form line in sub-form
Hi, I’m on Access in Office 2003. I have a sub-form which has a default view of “Continuous Forms”. This form is comprised of a single line which has the fields: Work Date Hours Miles Other Expense Total The work date, hours, miles, and Other expenses are data entry fields. The Total field is equal to (Hours * HourlyRate) + (Miles * MilageRate) + Other Expenses. The rates are retrieved from the main form. That part is working fine. The Work Date, Hours, Miles, and Other Expenses are bound to fields on my table. The Total field is unbound. The problem ...

Sorting in Queries
Hi, I am trying to write a query that assigns contributions for each account considered to either East or West depending on which territory has the larger contribution. I am wrote a queryStep1: SELECT [tbl_Transactions].month_end_date, [tbl_Transactions].account, [tbl_Transactions].contribution, [tbl_Transactions].territory FROM [tbl_Transactions] ORDER BY [tbl_Transactions].account, [tbl_Transactions].contribution DESC , [tbl_Transactions].territory; Then wrote queryStep2: SELECT step1.month_end_date, step1.account, Sum(step1.contribution) AS SumOfcontribution, Firs...

Excel Order Form
I've created an order form that's 131 lines. I saved it as a webpage, but only part of the form shows with a vertical scroll bar. I want users to be able to print out the sheet for mailing; but, of course, all that prints is what is showing on the screen. Is there any way to have the entire spreadsheet on the webpage? best solution is to convert it to a pdf file then just let them download it On Wed, 14 Jan 2004 06:37:59 -0800, "Carl" <> wrote: >I've created an order form that's 131 lines. I saved it >as a ...

field order
I made a pivot table report. somthing like following, it is about serve access count Server1 server server3 server 4 Date time 10/1/2004 1:00pm -6:00pm 1000 5600 50050 243243 10/1/2004 8:00am -12:00pm 23424 4234 4234 674 9/29/2004 1:00pm -6:00pm 2 3243 32 4234 9/29/2004 8:00am -12:00pm x x x x 9/30/2004 1:00pm -6:00pm x x x x 9/30/2004 8:ooam -12:00pm 256 ...

Tabbed form
I have created a tabbed form on Access 2007. After moving to different tabs on the form, it jumps up and I cannot see the top of the form. I have to use the scroll bar to move the form back down. How can I prevent the form from jumping up? -- Ronnie Hi Ronnie, I seem to remember reading a similar post a couple of weeks ago. Did you post this question previously? I have found this problem in my work. In my case, when I opened the form, the tabs were hidden so there was no way to even know there were tabs to click. The solution was to make the tab control quite a bit short...

Error after creation a custom field with Schema manager
This is my first attempt to customize the CRM. I used Schema manager to create a new field (attribute) and it seemed to be allright there. Then I published the customization, restarted the IIS and entered the CRM. Now an attempt to enter the customized area (I tried it with Leads and Opportunities) produces an Error without any informative message. Yet, I successfully customized a form with a new tab, new screen controls and OnChange event. Did anybody encounter a similar problem and/or knows a cure? boazM Do you removed any field? To see the error details turn On DevErros key on

Autopopulate Multiple Fields in Table Using a Form
I have a form based on a table where I want to store data. The data to store comes from combo boxes based on various lookup tables. The wrinkle is that there is one lookup table that contains 2 fields of data (questionnum and question) I want stored in the table once the questionnum is selected. The question field is formatted as 'memo'. When I create the combo box the question field is not an option for selection. I add it manually to the properties after completing the criteria for the combo box. I have been struggling with the code used to autopopulate more than one field but...

Question--Payment and Deposit order in advance register
Hi Everyone: I just purchased MS Money 2006 and have a question on the manner transactions are posted in the advanced register. I noticed that when both payment and deposit transaction are entered on a single date, the transactions are sorted so that payments are listed first and deposits are listed last. This means that all of the previous payment transactions for that date are drawn from the account without the benefit of the deposit. So payments made against the deposit make the account appear to have insufficient funds for those transactions. Is there a setting to disable the auto...

Question on Sorting by (date, etc)
I have a column (A) which sre dates. If I select the column heading and click either the sort ascending or desending button, the date column alone sorts independent of the other eight columns that comprise the entire entry. How would I go about being able to sort by a particular column and have everything sort with it? I have other columns that I would like to sort by sometimes too, like "color", "type", etc. Thanks for reading! select all the columns and now go to data | sort . On Feb 20, 11:21=A0pm, "Ed" <> wrote: > I have a column...

Outlook Custom Form Installation Error
Here is my problem: We just upgraded Microsoft Office 2003 to Service Pack 3, and now a custom form is broken. The users that used this form used to double click the .oft file on their desktop to launch it. Now when they double-click it, they get a message saying "The custom form could not be opened. Outlook will use an Outlook form instead." When I attempt to install the form to Outlook using the Tools --> Options --> Other --> Advanced Options --> Custom Forms --> Manage Forms --> Install option, I get this error message: ---------------------- The form could not...

user form
I am so frustrated. I am creating a form and I want to force a phone number format. Easy in Excel but cannot find it anywhere in word 2007. Please help Thanks Use the VBA Format function Format(1234567890, "(###) ###-####") will return (123) 456-7890 -- Hope this helps. Please reply to the newsgroup unless you wish to avail yourself of my services on a paid consulting basis. Doug Robbins - Word MVP, originally posted via "Dcook" <> wrote in message news:5F0E1C93-E828-46F7-98EF-FE6DF84...

Validate Purchase Order Date
We were able to enter a PO (against a Project) dated 2004, several years before we started on GP, so I'd guess that (because this is non-posting) the date isn't validated against the fiscal periods that have been set up. However, this lead to a Project Begin Date of 2004, and caused an error when we tried to enter a fixed fee amount against the project "Fiscal information does not exist for the date range. The fiscal year must exist in order to create the periodic records". The only way I found to fix this was to go into SQL table PA01201 and fix the Project's b...

Sorting does numbers in weird order
I was given a worksheet that I need to sort in numerical order. The cells contain both letters and numbers (e.g., VL 1087). The problem is that it sorts them like VL 1, VL 10, VL 100, VL 1000, VL 1001, etc. VL 16 is after 159 etc. Kind of like dewey decimal system without the decimals. I have tried reformatting the cells to text, numbers, general. Nothing seems to work. Any ideas? The easiest way is to insert two temporary helper columns next to th numbers column. Then - seperate the VL from the numbers, using Data Text-to-columns. Now you have a number column you can sort by, an a...

Sorting with Hyperlinks
I have a spreadsheet that contains a column of URL links. When I sort on a different column of information, the links to not sort with the rest of the data...the URL letters change, but the link itself does not. Exampl How can I get the links to sort with the rest of the data JT Are you sure you are selecting the whole range, INCLUDING the column with the links when you do your sort. -- Regards Ken....................... Microsoft MVP - Excel Sys Spec - Win XP Pro / XL 00/02/03 ----------------------------------------------------------------------------...

Printing a User Form
I have a user form using columns A-V in Excel which scrolls down to Row 200. Each row contains customer details in the colums A to V e.g, Name/Address/ Contact Numbers/ Age etc. As I scroll down the list of custermers their details appear in the relevant boxes on the User Form. Is it possible when a customers details fill in the relevant boxes that I can print the User Form with just their details. I hane placed a Command Button ( Print ) on the User Form however cannot get it to print. Any help would be much appreciated. Hi Mully, > I hane placed a Command Button ( Print ) on the...

Sort across a table
I have a table with theese records: SpillID SumBS SumGG SumBB SumBH 1 66 42 53 21 2 60 22 35 32 3 52 21 20 14 4 59 10 4 46 5 -8 53 17 -1 6 39 18 49 53 7 17 50 54 34 8 24 53 38 56 9 25 44 35 53 10 55 11 -9 32 Are there a way that Access that can present these data sorted like this: SpillID 1 66 53 42 21 2 60 35 32 22 3 52 21 20 14 4 59 46 10 4 5 53 17 -1 -8 6 53 49 39 18 7 54 50 34 17 8 56 53 38 24 9 53 44 35 25 10 55 32 11 -9 Any answer will be highly valued. hi, On 15.02.2010 12:14, The Viking wrote: > I have a table with theese records: > Spil...

Could not install the custom action
I'm running O2K7-TR and just recently started getting this error whenever I go to work with a message. I get the error whether I'm composing new, replying or forwarding. I'm trying to figure out where to look to troubleshoot this. All the searches I've done on custom actions have to either pertain to message rules or forms. Obviously, something is no longer where it was but the question is where and what is trying to access it. I'm thinking that because it's happening on any kind of composition that it is relating to the default template but i can't mak...

Error opening subform/form
When i use an access database and open a form containing a subform, the subform and its records are loaded before the main form as it should be. When i use an sql server database and open a form containing a subform, the subform and its records are NOT loaded before the main form. Can anyone please help me? Laura Laura, you cannot alter the way Access fires its events, so you will need to learn to work with it. Typcially when Access opens a form, it fires the subform's Open event before the main form's. But that does not mean it loads the *records* of the subform before the ...

Unable to pay purchase order
I have a purchase order that has been received and the receipt is now in history however I unable to pay for the purchase order. I am able to view the purchase order via PO processing inquiry but I can't pull it up to pay for it. Does anyone have any suggestions? Candi, If all you have entered is a receipt for the inventory, then you need to first match it to an invoice (Transactions > Purchasing > Enter/Match Invoices. When you post the invoice, then you can pay it in Payables. Hope that helps. -- Victoria Yudin GP MVP "Candi" <

CRM 4.0 Display content of custom entity throws exception.
The following errorreport is shown on a display request for a custom entrity: http://perfectv-mcjywm:5555/GemeenteRommeldam/_root/homepage.aspx?etc=10036 Microsoft CRM Error Report: Error Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Error Details: Exception of type 'System.Web.HttpUnhandledException' was thrown. Full Stack: [FormatException: Guid should contain 32 digits with 4 dashes (xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx).] ...

Sorting Area with Merged Cells
In the area A23:G30, each row contains merged cells of column B, C, D, E and F apart from each other row in the area. I get a "This operation requires that merged cells to be identically sized" error when running this macro. Even using the Data/Sort from the File menu gives me this error. How would I sort an area containing rows with merged cells? Also, the cells must remain (or return to being) merged after this operation. I appreciate the previous help concerning clearing the contents from merged cells using ActiveCell relative references. Unfortunately, my email/newsgroup ...

Sort By Account Name in Activities
Does anyone know if this is possible? I have tried customising through : http://crm/tools/viewEditor/viewManager.aspx?id={00000000-0000-0000-00AA-000010001903}but this only allows you to add 6 field names that i don't want. Is there a way to add "Company Name" to the list of columns i can add or is there another way around this?ThanksSimon ...

Slow sorts on Excel
I have a spreadsheet that I created a custom macro to sort certain columns in a workbook. For some reason after I have the workbook open for any extended period of time (saving and updating periodically) the sort will go from taking about 1.5 seconds to about 10 or 15 seconds. Once it takes 10 or 15 seconds I have to close the spreadsheet down and re-open to get back to the 1.5 second sort (I don't have to close Excel). Does anyone know why this may be hapening? I know it's ugly code and can be cleaned main question is what could be causing the slow down. Thanks, Ryan Her...