예제 #1
0
        private void btExportHTML_Click(object sender, System.EventArgs e)
        {
            try
            {
                string l_Path = System.IO.Path.Combine(System.IO.Path.GetTempPath(), "tmpSourceGridExport.htm");

                using (System.IO.FileStream l_Stream = new System.IO.FileStream(l_Path, System.IO.FileMode.Create, System.IO.FileAccess.Write))
                {
                    grid1.ExportHTML(new SourceGrid2.HTMLExport(SourceGrid2.ExportHTMLMode.Default, System.IO.Path.GetTempPath(), "", l_Stream));
                    l_Stream.Close();
                }

                SourceLibrary.Utility.Shell.OpenFile(l_Path);
            }
            catch (Exception err)
            {
                SourceLibrary.Windows.Forms.ErrorDialog.Show(this, err, "HTML Export Error");
            }
        }