Post Reply 
ORDER Error
01-07-2021, 01:20 PM
Post: #5
RE: ORDER Error
(01-07-2021 12:39 PM)Giuseppe Donnini Wrote:  The job of the ORDER command is not to reorder the elements of a given menu, but to reorder the variables in the current directory, that is, to adequately rearrange the linked list of identifier/object pairs stored in the dedicated RAM area called USEROB. The new order will then automatically be reflected by the built-in VAR menu — but not by any other menu, including temporary or custom menus containing, or even consisting entirely of, variables from the current directory.

All true, of course, but I (perhaps mistakenly) perceived the actual goal here as simply placing certain strings in those menu positions on the screen to achieve the display of a particular message. Hence my suggestion.

If MNH truly wants to rearrange the order of those globals in the directory, one way to do that without running into the command-line parser's confusion would be:
  1. Obtain a list of the globals in the current directory with the VARS command
  2. Explode that list (OBJ→ DROP)
  3. Rearrange the order as needed with the interactive stack (ROLL and ROLLD would be very helpful for this)
  4. Recombine into a new list (<quantity> →LIST)
  5. Execute ORDER

Having to "jump through hoops" like this is just one of the potential pitfalls of having non-standard names for globals, which is a good reason not to use them IMHO. Smile
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
ORDER Error - MNH - 01-03-2021, 03:38 PM
RE: ORDER Error - rprosperi - 01-03-2021, 03:45 PM
RE: ORDER Error - DavidM - 01-03-2021, 06:12 PM
RE: ORDER Error - Giuseppe Donnini - 01-07-2021, 12:39 PM
RE: ORDER Error - DavidM - 01-07-2021 01:20 PM
RE: ORDER Error - Csaba Tizedes - 01-10-2021, 02:48 PM
RE: ORDER Error - DavidM - 01-10-2021, 05:54 PM
RE: ORDER Error - DM48 - 03-28-2021, 09:04 PM
RE: ORDER Error - Han - 03-28-2021, 09:16 PM
RE: ORDER Error - DM48 - 03-29-2021, 03:27 PM
RE: ORDER Error - Giuseppe Donnini - 01-07-2021, 05:42 PM
RE: ORDER Error - Csaba Tizedes - 01-10-2021, 11:50 AM
RE: ORDER Error - MNH - 01-10-2021, 12:27 PM
RE: ORDER Error - rprosperi - 03-29-2021, 04:37 PM



User(s) browsing this thread: 1 Guest(s)