private void saveCodeActivity_ExecuteCode(object sender, EventArgs e) { DataEntityToken token = (DataEntityToken)this.EntityToken; IMediaFile file = (IMediaFile)token.Data; string content = this.GetBinding <string>("FileContent"); file.SetNewContent(content); DataFacade.Update(file); SetSaveStatus(true); }