Esempio n. 1
0
        private void showEditPost(CannedPost i_Post)
        {
            FormEditCannedPost editForm = new FormEditCannedPost();

            editForm.CannedPost = i_Post;
            editForm.ShowDialog();
            if (editForm.DialogResult == DialogResult.OK)
            {
                XmlSerializer serializer = new XmlSerializer(typeof(CannedPost));
                using (TextWriter writer = new StreamWriter(Path.Combine(this.CannedPostsDirectoryPath, editForm.CannedPost.Name + ".post.xml")))
                {
                    serializer.Serialize(writer, editForm.CannedPost);
                }
            }

            refreshPostList();
        }
        private void showEditPost(CannedPost i_Post)
        {
            FormEditCannedPost editForm = new FormEditCannedPost();
            editForm.CannedPost = i_Post;
            editForm.ShowDialog();
            if (editForm.DialogResult == DialogResult.OK)
            {
                XmlSerializer serializer = new XmlSerializer(typeof(CannedPost));
                using (TextWriter writer = new StreamWriter(Path.Combine(this.CannedPostsDirectoryPath, editForm.CannedPost.Name + ".post.xml")))
                {
                    serializer.Serialize(writer, editForm.CannedPost);
                }
            }

            refreshPostList();
        }