yangle
2023-03-03 c2a9a460e38c7c196fe98a94e29e6330eac3626f
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using Pub_Class;
 
namespace OAM
{
    public partial class frmSMsg : Form
    {
        public frmSMsg()
        {
            InitializeComponent();
        }
        //´«ËÍ
        public const int HFileNameCol = 0;//huan
        public const int HFilePathCol = 1;
        public const int HUpManCol = 2;
        public const int HROperatorCol = 3;
        public const int iFileIDCSCol = 4;
        public const int LoadDateCol = 5;
        public const int HBillStatusCol = 6;
        //½ÓÊÕ
        public const int HFileNameJSCol = 0;//huan
        public const int HFilePathJSCol = 1;
        public const int HUpManJSCol = 2;
        public const int HROperatorJSCol = 3;
        public const int iFileIDJSCol = 4;
        public const int LoadDateJSCol = 5;
        public const int HBillStatusJSCol = 6;
 
        public long ID;
        //public const int MainType = 5;
  
 
        public string fromoperator; //×Ô¼º
        public string tooperator;
 
 
        //public const string ModCaption = fromoperator;          //µ¥¾ÝÃû³Æ
        private void button3_Click(object sender, EventArgs e)
        {
            DBUtility.ClsPub.SaveGridView(grdmain, this.Name, DBUtility.ClsPub.AppPath);
            SQLHelper.ClsCN oCn = new SQLHelper.ClsCN();
            if (txtMsg.Text == "")
            {
                MessageBox.Show("ÇëÌîд»Ø¸´ÄÚÈÝ£¡");
            }
            string Context = txtMsg.Text.Replace("'", "¡®");
            int Rows = grdmain.Rows.Count + 1;
            oCn.RunProc("Insert into oa_msg(fromoperator,tooperator,context,opdate,isview) values('" + fromoperator + "','" + tooperator + "','" + txtMsg.Text.Trim() + "','" + DateTime.Now.ToString() + "'," + 0 + ")");
            txtMsg.Text = "";
            Display();
        }
        //ÏÔʾ´«Ë͸½¼þ
        private void DisplayCSFJ()//huan
        {
            SQLHelper.ClsCNK3 oCn = new SQLHelper.ClsCNK3();
            DataSet Ds;
            Ds = oCn.RunProcReturn("Select top 5 MainID,sPath,sFileName,operator,ROperator,LoadDate,HBillStatus from oa_PicBill where operator='" + fromoperator + "' and ROperator='" + tooperator + "'", "oa_PicBill");
            if (Ds == null || Ds.Tables[0].Rows.Count == 0)
            {
                return;
            }
            for (int i = 0; i < Ds.Tables[0].Rows.Count; i++)
            {
                grdCSFJ.Rows.Add();
                grdCSFJ.Rows[i].Cells[HFileNameCol].Value = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[i]["sFileName"]);
                grdCSFJ.Rows[i].Cells[HFilePathCol].Value = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[i]["sPath"]);
                grdCSFJ.Rows[i].Cells[HUpManCol].Value = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[i]["operator"]);
                grdCSFJ.Rows[i].Cells[HROperatorCol].Value = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[i]["ROperator"]);
                grdCSFJ.Rows[i].Cells[iFileIDCSCol].Value = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[i]["MainID"]);
                grdCSFJ.Rows[i].Cells[LoadDateCol].Value = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[i]["LoadDate"]);
                grdCSFJ.Rows[i].Cells[HBillStatusCol].Value = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[i]["HBillStatus"]);
                string HBillStatus = grdCSFJ.Rows[i].Cells[HBillStatusCol].Value.ToString();
                if (HBillStatus == "0")
                {
                    grdCSFJ.Rows[i].Cells[HBillStatusCol].Value = "δÏÂÔØ";
                }
                else
                {
                    if (HBillStatus == "1")
                    {
                        grdCSFJ.Rows[i].Cells[HBillStatusCol].Value = "ÒÑÏÂÔØ";
                    }
                    else
                    {
                        grdCSFJ.Rows[i].Cells[HBillStatusCol].Value = "¶Ô·½ÒѾܾø";
                    }
                }
            }
        }
        //ÏÔʾ½ÓÊÕ¸½¼þ
        private void DisplayJSFJ()//huan
        {
            SQLHelper.ClsCNK3 oCn = new SQLHelper.ClsCNK3();
            DataSet Ds;
            Ds = oCn.RunProcReturn("Select top 5 ID,MainID,sPath,sFileName,operator,ROperator,LoadDate,HBillStatus from oa_PicBill where operator='" + tooperator + "' and ROperator='" + fromoperator + "'", "oa_PicBill");
            if (Ds == null || Ds.Tables[0].Rows.Count == 0)
            {
                return;
            }
            for (int i = 0; i < Ds.Tables[0].Rows.Count; i++)
            {
                grdJSFJ.Rows.Add();
                grdJSFJ.Rows[i].Cells[HFileNameJSCol].Value = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[i]["sFileName"]);
                grdJSFJ.Rows[i].Cells[HFilePathJSCol].Value = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[i]["sPath"]);
                grdJSFJ.Rows[i].Cells[HUpManJSCol].Value = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[i]["operator"]);
                grdJSFJ.Rows[i].Cells[HROperatorJSCol].Value = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[i]["ROperator"]);
                grdJSFJ.Rows[i].Cells[iFileIDJSCol].Value = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[i]["ID"]);
                grdJSFJ.Rows[i].Cells[LoadDateCol].Value = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[i]["LoadDate"]);
                grdJSFJ.Rows[i].Cells[HBillStatusCol].Value = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[i]["HBillStatus"]);
                string HBillStatus = grdJSFJ.Rows[i].Cells[HBillStatusCol].Value.ToString();
                if (HBillStatus == "0")
                {
                    grdJSFJ.Rows[i].Cells[HBillStatusCol].Value = "δÏÂÔØ";
                }
                else
                {
 
                    if (HBillStatus == "1")
                    {
                        grdCSFJ.Rows[i].Cells[HBillStatusCol].Value = "ÒÑÏÂÔØ";
                    }
                    else
                    {
                        grdCSFJ.Rows[i].Cells[HBillStatusCol].Value = "ÒѾܾø";
                    }
                }
            }
        }
        public void Display()
        {
            SQLHelper.ClsCN oCn = new SQLHelper.ClsCN();
            DataSet Ds;
            string sSQL;
            sSQL = "Select top 50 id hid,fromoperator Óû§,opdate Ê±¼ä,context ÄÚÈÝ from oa_msg where  fromoperator='" + tooperator + "' and tooperator='" + fromoperator + "'  or  tooperator='" + tooperator + "'  and fromoperator='" + fromoperator + "' order by Ê±¼ä desc ";
            //Select id hid,fromoperator Óû§,opdate Ê±¼ä,context ÄÚÈÝ from oa_msg  where  fromoperator='ÄÚÏú²¿¾­Àí' or fromoperator= '¾°»ÀÕÂ' and tooperator='¾°»ÀÕÂ' or tooperator='ÄÚÏú²¿¾­Àí'
            Ds = oCn.RunProcReturn(sSQL, "oa_msg", ref DBUtility.ClsPub.sExeReturnInfo);
            if (Ds == null)
            {
                MessageBox.Show("ÏÔʾʧ°Ü£¡Ô­Òò£º" + DBUtility.ClsPub.sExeReturnInfo);
                return;
            }
            grdmain.DataSource = Ds.Tables[0].DefaultView;
 
            DBUtility.Xt_BaseBillFun.DisplayGrid(grdmain, this.Name, "", 0);
            //¸½¼þ   huan
            DisplayCSFJ();
            //DBUtility.ClsPub.GetGridView(grdMain, this.Name, DBUtility.ClsPub.AppPath);
            DBUtility.ClsPub.GetGridView(grdCSFJ, this.Name + "grdCSFJ", DBUtility.ClsPub.AppPath); 
            
            //½ÓÊÕ¸½¼þ   huan
            DisplayJSFJ();
            //DBUtility.ClsPub.GetGridView(grdMain, this.Name, DBUtility.ClsPub.AppPath);
            DBUtility.ClsPub.GetGridView(grdJSFJ, this.Name + "grdJSFJ", DBUtility.ClsPub.AppPath);
            //
        //    SQLHelper.ClsCN oCn = new SQLHelper.ClsCN();
   
 
        //    DataSet Ds;
        //    DataSet Ds2;
        //    Ds = oCn.RunProcReturn("Select * from oa_msg where fromoperator='" + fromoperator + "' and tooperator='" + tooperator + "' and isview=0 order by opdate", "oa_msg", ref DBUtility.ClsPub.sExeReturnInfo);
        //    if (Ds == null)
        //    {
        //        MessageBox.Show("ÏÔʾʧ°Ü£¡Ô­Òò£º" + DBUtility.ClsPub.sExeReturnInfo);
        //        return;
        //    }
 
        ////     Do While Not oRs.EOF
        //grdmain.AddItem ""
        //If IIf(IsNull(oRs!isxt), False, oRs!isxt) = True Then
        //    grdmain.TextMatrix(grdmain.Rows - 1, 0) = "ϵͳÏûÏ¢£º " & oRs!context
        //    grdmain.Cell(flexcpForeColor, grdmain.Rows - 1, 0, grdmain.Rows - 1, 0) = vbRed
        ////Else
        ////    grdmain.TextMatrix(grdmain.Rows - 1, 0) = oRs!fromoperator & " Ëµ£º " & oRs!context
        ////    grdmain.Cell(flexcpForeColor, grdmain.Rows - 1, 0, grdmain.Rows - 1, 0) = vbBlue
        ////End If
        ////oCn.Execute "update oa_msg set isview=1 where id=" & oRs!ID
        ////oRs.MoveNext
        //    grdmain.ColumnHeadersVisible = false;
        //    //grdmain.Columns[0].Visible = false;
        //    //grdMain.Columns[0].Width = 100;
        //    //grdMain.Columns[1].Width = 1000;
        //    DBUtility.ClsPub.GetGridView(grdmain, this.Name, DBUtility.ClsPub.AppPath);
        }
 
        private void grdmain_Scroll(object sender, ScrollEventArgs e)
        {
 
            grdmain.RowsDefaultCellStyle.WrapMode = DataGridViewTriState.True;
        }
 
        private void timer1_Tick(object sender, EventArgs e)
        {
            timer1.Enabled = false;
            //timer1.Interval = 60000;
            //SetOperator(); 
            Display();
        }
        private void SetOperator()
        {
            SQLHelper.ClsCNK3 oCn = new SQLHelper.ClsCNK3();
            DataSet Ds;
            Ds = oCn.RunProcReturn("Select top 5 ID,MainID,sPath,sFileName,operator,ROperator,LoadDate,HBillStatus from oa_PicBill where operator='" + tooperator + "' and ROperator='" + fromoperator + "'", "oa_PicBill");
            if (Ds == null || Ds.Tables[0].Rows.Count == 0)
            {
                return;
            }
            for (int i = 0; i < Ds.Tables[0].Rows.Count; i++)
            {
                grdJSFJ.Rows[i].Cells[HBillStatusCol].Value = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[i]["HBillStatus"]);
                string HBillStatus = grdJSFJ.Rows[i].Cells[HBillStatusCol].Value.ToString();
                if (HBillStatus == "0")
                {
                    pictureBox1.Visible = false;
                    pictureBox1.Visible = true;
                    grdJSFJ.Rows[i].Cells[HBillStatusCol].Value = "δÏÂÔØ";
                }
                else
                {
                    if (HBillStatus == "1")
                    {
                        pictureBox1.Visible = true;
                        grdJSFJ.Rows[i].Cells[HBillStatusCol].Value = "ÒÑÏÂÔØ";
                    }
                    else
                    {
                        pictureBox1.Visible = true;
                        grdCSFJ.Rows[i].Cells[HBillStatusCol].Value = "ÒѾܾø";
                    }
                }
            }
        }
 
     
        private void cmdCancel_Click(object sender, EventArgs e)
        {
            Close();
        }
 
        private void button2_Click(object sender, EventArgs e)
        {
            frmUserset ofrmUserset = new frmUserset();
            ofrmUserset.UserName = tooperator;
            ofrmUserset.Show();
        }
 
        private void cmdQMsgList_Click(object sender, EventArgs e)
        {
            QMsgList oQMsgList = new QMsgList();
            
            oQMsgList.fromoperator=fromoperator;
            oQMsgList.tooperator = tooperator;
            oQMsgList.Show();
        }
 
        private void frmSMsg_Load(object sender, EventArgs e)
        {
 
            string ModCaption = tooperator;          //µ¥¾ÝÃû³Æ
            initGridFJ();
            initGridJSFJ();
            
            this.Text = "Óë " + tooperator + "ÁÄÌìÖÐ";
        }
        private void initGridFJ()//huan
        {
            grdCSFJ.ColumnCount = 7;                       //×ÜÁÐÊý
            DBUtility.Xt_BaseBillFun.initGridFst(grdCSFJ, this.Name + "grdCSFJ");
            grdCSFJ.ReadOnly = true;
            grdCSFJ.RowCount = 0;
            //= 
            grdCSFJ.Columns[HFileNameCol].HeaderText = "ÎļþÃû³Æ";
            grdCSFJ.Columns[HFilePathCol].HeaderText = "Îļþ·¾¶";
            grdCSFJ.Columns[HUpManCol].HeaderText = "ÉÏ´«ÈË";
            grdCSFJ.Columns[HROperatorCol].HeaderText = "½ÓÊÕÈË";
            grdCSFJ.Columns[LoadDateCol].HeaderText = "´«ËÍʱ¼ä";
            grdCSFJ.Columns[HBillStatusCol].HeaderText = "״̬";
            grdCSFJ.Columns[iFileIDCSCol].HeaderText = "ID";
 
            grdCSFJ.Columns[HFilePathCol].Visible = false;
            grdCSFJ.Columns[HUpManCol].Visible = false;
            grdCSFJ.Columns[HROperatorCol].Visible = false;
            grdCSFJ.Columns[iFileIDCSCol].Visible = false;
            DBUtility.ClsPub.GetGridView(grdCSFJ, this.Name + "grdCSFJ", DBUtility.ClsPub.AppPath);
        }
        private void initGridJSFJ()//huan
        {
            grdJSFJ.ColumnCount = 7;                       //×ÜÁÐÊý
            DBUtility.Xt_BaseBillFun.initGridFst(grdJSFJ, this.Name + "grdJSFJ");
            grdJSFJ.ReadOnly = true;
            grdJSFJ.RowCount = 0;
            //= 
            grdJSFJ.Columns[HFileNameJSCol].HeaderText = "ÎļþÃû³Æ";
            grdJSFJ.Columns[HFilePathJSCol].HeaderText = "Îļþ·¾¶";
            grdJSFJ.Columns[HUpManJSCol].HeaderText = "ÉÏ´«ÈË";
            grdJSFJ.Columns[HROperatorJSCol].HeaderText = "½ÓÊÕÈË";
            grdJSFJ.Columns[LoadDateJSCol].HeaderText = "´«ËÍʱ¼ä";
            grdJSFJ.Columns[HBillStatusCol].HeaderText = "״̬";
            grdJSFJ.Columns[iFileIDJSCol].HeaderText = "ID";
 
            grdJSFJ.Columns[HFilePathCol].Visible = false;
            grdJSFJ.Columns[HUpManCol].Visible = false;
            grdJSFJ.Columns[HROperatorCol].Visible = false;
            grdJSFJ.Columns[iFileIDJSCol].Visible = false;
            DBUtility.ClsPub.GetGridView(grdJSFJ, this.Name + "grdJSFJ", DBUtility.ClsPub.AppPath);
        }
        private void button5_Click(object sender, EventArgs e)
        {
            OpenFileDialog oDlg = new OpenFileDialog();
            oDlg.Filter = "ËùÓÐÎļþ|*.*";
            if (oDlg.ShowDialog() == DialogResult.OK)
            {
                if (oDlg.FileName != "")
                {   
                    //ÉÏ´«¸½¼þ      huanxin
                    BLL.ClsXt_FileCtrl oFile = new BLL.ClsXt_FileCtrl();
                    string LoadDate = DateTime.Now.ToString();
                    grdCSFJ.Rows.Add();
                    grdCSFJ.Rows[grdCSFJ.Rows.Count - 1].Cells[HFileNameCol].Value = oDlg.SafeFileName;
                    grdCSFJ.Rows[grdCSFJ.Rows.Count - 1].Cells[HFilePathCol].Value = oDlg.FileName;
                    grdCSFJ.Rows[grdCSFJ.Rows.Count - 1].Cells[HUpManCol].Value = DBUtility.ClsPub.CurUserName;
                    grdCSFJ.Rows[grdCSFJ.Rows.Count - 1].Cells[HROperatorCol].Value = tooperator;
                    grdCSFJ.Rows[grdCSFJ.Rows.Count - 1].Cells[LoadDateJSCol].Value = LoadDate;
                   
                        grdCSFJ.Rows[grdCSFJ.Rows.Count - 1].Cells[HBillStatusCol].Value = "δÏÂÔØ";
                   
                    if (oFile.LoadUpFile2(iFileIDCSCol, oDlg.FileName, 0, oDlg.SafeFileName, DBUtility.ClsPub.CurUserName, tooperator, LoadDate,0) == false)
                    {
                        MessageBox.Show("ÉÏ´«Îļþʱʧ°Ü!");
                    }
 
                   
                }
            }
        }
 
        private void button6_Click(object sender, EventArgs e)
        {
            SQLHelper.ClsCN oCn = new SQLHelper.ClsCN();
            if (grdJSFJ.CurrentRow == null)
            {
               
                return;
            }
            //ÏÂÔØ¸½¼þµ½±¾µØ£¬²¢Ö´ÐÐ
            BLL.ClsXt_FileCtrl oFile2 = new BLL.ClsXt_FileCtrl();
            SQLHelper.ClsCNK3 oCNK32 = new SQLHelper.ClsCNK3();
            if (oFile2.WriteFile2("Pic"
                , DBUtility.ClsPub.AppPath + @"\a\" + DBUtility.ClsPub.isStrNull(grdJSFJ.Rows[grdJSFJ.CurrentRow.Index].Cells[HFileNameCol].Value)
                , DBUtility.ClsPub.isLong(grdJSFJ.Rows[grdJSFJ.CurrentRow.Index].Cells[iFileIDJSCol].Value), oCNK32) == false)
            {
                MessageBox.Show("¶ÁÈ¡Îļþʱʧ°Ü!");
                return;
            }
 System.Diagnostics.Process.Start(DBUtility.ClsPub.AppPath + @"\a\" + DBUtility.ClsPub.isStrNull(grdJSFJ.Rows[grdJSFJ.CurrentRow.Index].Cells[HFileNameCol].Value));
       
        }
 
        private void button8_Click(object sender, EventArgs e)
        {
            SQLHelper.ClsCNK3 oCn = new SQLHelper.ClsCNK3();
 
            if (grdJSFJ.CurrentRow == null)
            {
 
                return;
            }
            oCn.RunProc("Update  oa_PicBill set " +
                      "HBillStatus= 2 Where ID =" + DBUtility.ClsPub.isLong(grdJSFJ.Rows[grdJSFJ.CurrentRow.Index].Cells[iFileIDJSCol].Value), ref DBUtility.ClsPub.sExeReturnInfo);
            //if (DBUtility.ClsPub.isStrNull(grdJSFJ.Rows[grdJSFJ.CurrentRow.Index].Cells[HUpManCol].Value) != DBUtility.ClsPub.CurUserName)
            //{
                //MessageBox.Show("Ö»ÄÜɾ³ý×Ô¼ºÉÏ´«µÄ¸½¼þ£¡");
                //return;
            //}
            //DialogResult dr = MessageBox.Show("È·¶¨ÒªÉ¾³ý´Ëµ¥¾ÝÂð£¿", "Ìáʾ", MessageBoxButtons.YesNo, MessageBoxIcon.Warning);
            //if (dr == DialogResult.Yes)
            //{
                //if (!DBUtility.ClsPub.Security_Log("OA_Manager", 1, true, DBUtility.ClsPub.CurUserName))
                //{
                //    return;
                //}
                //ɾ³ý¸½¼þ
                //BLL.ClsXt_FileCtrl oFile = new BLL.ClsXt_FileCtrl();
                //SQLHelper.ClsCNK3 oCNK3 = new SQLHelper.ClsCNK3();
                //if (oFile.DeleteFile3(DBUtility.ClsPub.isLong(grdJSFJ.Rows[grdJSFJ.CurrentRow.Index].Cells[iFileIDJSCol].Value), ref DBUtility.ClsPub.sExeReturnInfo, oCNK3) == false)
                //{
                //    MessageBox.Show("ɾ³ýÎļþʱʧ°Ü!");
                //}
                //
                //grdJSFJ.Rows.RemoveAt(grdJSFJ.CurrentRow.Index);
            //}
            //else
            //{
            //}
        }
 
        private void button7_Click(object sender, EventArgs e)
        {
            if (grdJSFJ.CurrentRow == null)
            {
 
                return;
            } 
            //FolderBrowserDialog fbd = new FolderBrowserDialog();
            //fbd.ShowDialog();
            //string folderName = fbd.SelectedPath; //»ñµÃÑ¡ÔñµÄÎļþ¼Ð·¾¶
 
            SaveFileDialog sfd = new SaveFileDialog();
            sfd.FileName = DBUtility.ClsPub.isStrNull(grdJSFJ.Rows[grdJSFJ.CurrentRow.Index].Cells[HFileNameCol].Value);
            //sfd.Filter = "all|*.*"; //ɾѡ¡¢É趨ÎļþÏÔʾÀàÐÍ
            sfd.AddExtension = false;
            sfd.ShowDialog();
            string path = sfd.FileName;
            //ÏÂÔØ¸½¼þµ½±¾µØ£¬²¢Ö´ÐÐ
            BLL.ClsXt_FileCtrl oFile2 = new BLL.ClsXt_FileCtrl();
            SQLHelper.ClsCNK3 oCNK32 = new SQLHelper.ClsCNK3();
            if (oFile2.WriteFile2("Pic"
                , path 
                , DBUtility.ClsPub.isLong(grdJSFJ.Rows[grdJSFJ.CurrentRow.Index].Cells[iFileIDJSCol].Value), oCNK32) == false)
            {
                MessageBox.Show("¶ÁÈ¡Îļþʱʧ°Ü!");
                return;
            }
            MessageBox.Show("±£´æ³É¹¦!");
            //System.Diagnostics.Process.Start(folderName + @"\" + DBUtility.ClsPub.isStrNull(grdJSFJ.Rows[grdJSFJ.CurrentRow.Index].Cells[HFileNameCol].Value));
           
        }
 
      
 
    
        
    }
}