Skip to Content

Sales Order sorted by item code before add

6 days ago


avatar image

Good morning,

In B1 and in the Sales Order form, I would like sort the item codes in the matrix before the users adds the SO. I would like to get the same behaviuor that when we do a double click in the Item Code header column.

I tried this code but it doesn't work because it also orders the order the "empty line"

Dim Matrix AsMatrix = CType(form.Items.Item("38").Specific, Matrix)

' Get Column object

Dim Column AsColumn = Matrix.Columns.Item("1")

' Ascending sort order



Line 1 item A005

Line 2 item A002

Line 3 item empty (ready to insert a new item)

When I run this code the matrix becomes

Line 1 item empty

Line 2 item A002

Line 3 Item A005

Any help will be appreciated.

Best regards,

Augusto Silva

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

1 Answer

Best Answer
Pedro Magueija 6 days ago

Hi Augusto,

Can you delete the first line on the grid after you've ordered it?

Pedro Magueija

LinkedIn | Twitter | Blog

10 |10000 characters needed characters left characters exceeded