cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Choose Language Hide Translation Bar
dfusco923
Level III

How do I save (overwrite) a JMP file to Excel and maintaing the Excel file formatting from te orignal Excel File?

I have a piece of JMP script that saves a JMP file to Excel.  The Excel file is overwritten with the new data.

 

 

CTZ = CT_1 << Summary(
    Group(
        :Rcd No., :Prog, :Pri, :No., :Matl_Desc, :Issue, :Cog Eng., :Status,
        :Assign Date, :ECD, :Actionee
    )
);

CTZ << delete columns( "N Rows" );

CTZ << save( "Daily Rpt Listing.xlsx" );

 

 

When the file is save the formatting of the Excel file that is being overwritten is lost.  How can I overwrite the Excel file but maintain the original Excel file formatting?   I have done this in the past but cannot find how I did it . . .

 

 

4 REPLIES 4
Jeff_Perkinson
Community Manager Community Manager

Re: How do I save (overwrite) a JMP file to Excel and maintaing the Excel file formatting from te orignal Excel File?

I don't think that JMP has a way of inserting values into an existing worksheet, thereby retaining the formatting in the workbook. @briancorcoran may be able to confirm.

-Jeff
Georg
Level VII

Re: How do I save (overwrite) a JMP file to Excel and maintaing the Excel file formatting from te orignal Excel File?

You can let JMP write a plain Excel File, and let Excel in the formatted Worksheet take the data from that plain file via link. Hope this helps.

Georg

Re: How do I save (overwrite) a JMP file to Excel and maintaing the Excel file formatting from te orignal Excel File?

When JMP writes an Excel file, the old file is completely overwritten.  Values are not inserted into it.  That is, JMP creates a brand new Excel file in its place.  So, there is no way to maintain the previous formatting.

 

Brian Corcoran

JMP Development

Devin
Level I

Re: How do I save (overwrite) a JMP file to Excel and maintaing the Excel file formatting from te orignal Excel File?

Brian - JSL will not save over an opened excel file. I can ask users to close it for a time, so that I can save the xlsx as 'read only'. But I'm having trouble finding the code that will do that. If my excel file is at \\Server\Eng\egfile.xlsx, how can I save it as 'read-only' or 'read-only recommended' ?  Thanks!