2.2.4.42.12 storage::Write

Description

Write contents of a storage class into a file.

Syntax

bool Write( LPCSTR lpcszFile )

Parameters

lpcszFile
[input]File name

Return

Returns TRUE on success and FALSE on failure.

Examples

EX1

//run example code in Storage::SetSection before run this code to check the result.
void Storage_Write_ex1()
{    
    Page pg = Project.Pages();
    if(pg==NULL)
        return;
    
    storage st;    
    string strStorage = "Test";    
    st = pg.GetStorage(strStorage);    
    
    if(st.IsValid())
    {
        bool bRet = st.Write("C:\\Test.xml");
    }    
}

Remark

See Also

Storage:SetSection, Storage:Read

Header to Include

origin.h