The problem is the following. If I place a breakpoint before the "sort.wks();", it sorts an entire worksheet successfully. However if I don't place a breakpoint or place it after the "sort.wks();", it sorts only one column instread of the entire worksheet!!
I tried the following, but none can solve it. - Don't use "using". Place the LabTalk codes inside the _LT_Obj block. => Doesn't work. - Don't write a subfunction. Just write the LabTalk codes directly on where the function is called. -> Dosn't work. - Don't use "using" nor _LT_Obj block. Code each link of LabTalk command in the LT_execute function. -> Doesn't work.
I think I should be keep looking those header files (such as wksheet.h) when writing Origin C, instead of looking the help. The wksheet.h explains the Worksheet::Sort very clearly. Thank you for your help.
In most cases the descriptions for OC functions are taken from the corresponding .H file but help files are not always up to date. Since you have the release version (SR0) of O75 I strongly recommend that you update to the latest version (SR6). That will give you many bug fixes and additions as well as the latest help files. Run Help > Check for Updates and download/install anything that's offered. Repeat until no updates are found.