Change the order of your columns in a query, the result of which you export to Excel.
No options in the Export procedure for that.
The other option is to use the Print procedure (specify the variable order in the VAR statement) and create Excel output from it with ODS HTML or TAGSETS.EXCELXP.
PROC SQL ;
CREATE TABLE yourData AS
SELECT firstVar, secondVar, ...
/* you need to write them all */
Dunno why, but I was thinking you were using Excel (stupid me). So as long as you are programming, you'd rather use the PROC PRINT solution, which will run much faster (does not need to create a copy of your dataset).
Another solution is to reorder variables with a data step, using a "dummy" label (or format, or informat) statement to name them in the order you want, BEFORE your SET statement. This will cause SAS to use your order instead of the original you. It can be useful if you only have a few variables to be moved to the very left of your dataset, for example if original order is T U V W X Y Z you can do :
DATA reordered ;
LABEL X = "The X label"
Z = "The Z label" ;
SET original ;
I don't have a solution using proc export but I did develop a set of macros that writes SAS values to any cell(s) of any worksheet of any workbook. This code wrote SAS data to 28 worksheets. The workbook must be open and the worksheets already named to the names in this macro for this to work. The first step clears all the data in the sheet. The second and third steps write column names. The fourth step writes all the data.