save()

Description

Saves the changes made to the document.

Please note that this function is built-in behind the OK tool item.

Syntax

- (void) save

Parameters

None

Return value

void

Remarks

The edited document will overwrite the original document.

The object that the current document corresponds to is deleted, the save operation fails and the exception DcsObjectNotExistException will be thrown.

Example


@interface ViewController ()<DcsUIDocumentEditorViewDelegate>{
    DcsView *dcsView;
}
@end
 
@implementation ViewController
 
- (void)viewDidLoad {
    [super viewDidLoad];
     
    dcsView = [[DcsView alloc]initWithFrame:CGRectMake(0, 0, self.view.frame.size.width, self.view.frame.size.height)];
 
    dcsView.documentEditorView.delegate = self; 
    [self.view addSubview:dcsView];

    [self.dcsView.documentEditorView save];
}

@end

See Also

discard()

Is this page helpful?

Leave a Reply

Your email address will not be published.