Show/Hide Toolbars

EmEditor Help

Navigation: EmEditor Help > Plug-in Reference > Inline Functions

EmEditor Plug-in Reference: Editor_ConvertCsv

Scroll Prev Top Next More
EmEditor Home - EmEditor Help - Plug-in Reference - Inline Functions


Converts the CSV format of the current document. You can use this inline function or explicitly send the EE_CONVERT_CSV message.

HRESULT Editor_ConvertCsv( HWND hwnd, int iDestMode, UINT nFlags = 0, int nSepCount = 0, const int* pcxSepWidths = NULL );



Specifies the window handle of the view or frame of EmEditor.


Specifies the index of the CSV format you want to convert the current document to. 0 means fixed-width columns format (non-CSV). 1 means the first defined format in the CSV tab of the Customize dialog box (Comma separeted by default).


You can specify a combination of the following values.




Assumes all half-width characters to improve the speed.


Discards undo information to improve the speed.


If the current document is a non-CSV document, and if you want to convert the current document of fixed-width columns to a CSV document, this parameter specifies the number of separators, and it must be equal to the size of the array specified in the pcxSepWidths parameter. This parameter is ignored if the current document is a CSV document.


Specifies the array of integers representing the widths between separators if the nSepCount parameter is non-zero.

Return Values

The return value is S_OK if succeeds.


Supported on Version 19.8 or later.

Copyright © 2003-2021 by Emurasoft, Inc.