Imports System.Drawing Imports System.Drawing.Printing Imports System.Math Imports System.Drawing.Image Imports System.IO Imports ThoughtWorks.QRCode.Codec '//QRÄÚµå Imports ThoughtWorks.QRCode.Codec.Util Imports ThoughtWorks.QRCode.Codec.Data Public Class printform Dim DrStyle As PatternDS.TStyleRow = Nothing Dim DtPattern As PatternDS.TPatternDataTable = Nothing Dim AllLabels() As Str_Alllabels '//Àüü°¹¼ö´Â Ãß°¡ÇÒ´ë ¼ÂÆÃÇÑ´Ù. Dim S±¸°ü¸®Àü»ê(0) As MyControlOLEDBv2.MyLabel Dim S°ü¸®±¸(4) As MyControlOLEDBv2.MyLabel Dim SÀü»ê¹øÈ£(2) As MyControlOLEDBv2.MyLabel Dim S¼±·Î¸í(10) As MyControlOLEDBv2.MyLabel Dim SÀüÁÖ¹øÈ£(20) As MyControlOLEDBv2.MyLabel Dim S½Ã°ø³â¿ù(3) As MyControlOLEDBv2.MyLabel Dim S°ü¸®±¸ÀüÁÖ¹øÈ£(0) As MyControlOLEDBv2.MyLabel Dim SÀåô(2) As MyControlOLEDBv2.MyLabel Dim S½Ã°øÀÚ(0) As MyControlOLEDBv2.MyLabel Dim SÁ¢Áö(1) As MyControlOLEDBv2.MyLabel Dim S°¨µ¶ÀÚ(9) As MyControlOLEDBv2.MyLabel Dim SÁ¡°ËÀÏÀÚ(0) As MyControlOLEDBv2.MyLabel Dim SÀϷùøÈ£(0) As MyControlOLEDBv2.MyLabel ' Dim Sºñ°í¸í(3) As MyControlOLEDBv2.MyLabel '2013/06/13 Àμö 3°³¿¡¼­ 0À¸·Î Dim Sºñ°í¸í(0) As MyControlOLEDBv2.MyLabel Dim S»ç¿ëÀÚ1(0) As MyControlOLEDBv2.MyLabel 'U Dim S»ç¿ëÀÚ2(0) As MyControlOLEDBv2.MyLabel 'A Dim S»ç¿ëÀÚ3(0) As MyControlOLEDBv2.MyLabel 'B Dim S»ç¿ëÀÚ4(0) As MyControlOLEDBv2.MyLabel 'D Dim S»ç¿ëÀÚ5(0) As MyControlOLEDBv2.MyLabel 'E Dim Sº»ÁÖ¹øÈ£(0) As MyControlOLEDBv2.MyLabel Dim Sº»ÁÖÀüÁÖ¹øÈ£(0) As MyControlOLEDBv2.MyLabel Dim SÀüÁÖ¹øÈ£ÇÑÁÙ(0) As MyControlOLEDBv2.MyLabel '//150201 Ãß°¡ Dim SÈÞÁî¿ë·®(9) As MyControlOLEDBv2.MyLabel Dim S»óÇ¥½ÃÂû1´Ü(2) As MyControlOLEDBv2.MyLabel Dim S»óÇ¥½ÃÂû2´Ü(2) As MyControlOLEDBv2.MyLabel Dim S±¸¼±·ÎÀüÁÖ¹øÈ£(0) As MyControlOLEDBv2.MyLabel 'v Dim S½Å¼±·ÎÀüÁÖ¹øÈ£(0) As MyControlOLEDBv2.MyLabel 'w Dim SÁ¡°Ë(0) As MyControlOLEDBv2.MyLabel 'HI 'Dim S°íÁ¤¹®ÀÚ1 As MyControlOLEDBv2.MyLabel 'x 'Dim S°íÁ¤¹®ÀÚ2 As MyControlOLEDBv2.MyLabel 'y Dim SÁ¡°ËÇÊ(0) As MyControlOLEDBv2.MyLabel Dim SÁ¡°ËÀÚ(0) As MyControlOLEDBv2.MyLabel Dim SÇѱ¹Àü·Â(0) As MyControlOLEDBv2.MyLabel Dim S°íÀå½Å°í(0) As MyControlOLEDBv2.MyLabel Dim ±¸°ü¸®±¸ As String = "" Dim ±¸Àü»ê¹øÈ£ As String = "" Dim ±¸°ü¸®Àü»ê As String = "" Dim °ü¸®±¸ As String = "" Dim Àü»ê¹øÈ£ As String = "" Dim ¼±·Î¸í As String = "" Dim ¹øÈ£ As String = "" Dim Àåô As String = "" Dim ½Ã°ø³â¿ù As String = "" Dim ½Ã°øÀÚ As String = "" Dim °¨µ¶ÀÚ As String = "" Dim Á¡°ËÀÏÀÚ As String = "" Dim Á¢Áö1 As String = "" Dim Á¢Áö2 As String = "" Dim ºñ°í¸í As String = "" Dim º»ÁÖ¹øÈ£ As String = "" Dim º»ÁÖÀüÁÖ¹øÈ£ As String = "" Dim ÀüÁÖ¹øÈ£ÇÑÁÙ As String = "" 'Dim Á¡°Ë As String = "" '//150201 Dim ÈÞÁî¿ë·® As String = "" Dim »óÇ¥½ÃÂû1´Ü As String = "" Dim »óÇ¥½ÃÂû2´Ü As String = "" Dim ±¸¼±·ÎÀüÁÖ¹øÈ£ As String = "" Dim ½Å¼±·ÎÀüÁÖ¹øÈ£ As String = "" Dim ±¸¼±·Î¸í As String = "" Dim ±¸ÀüÁÖ¹øÈ£ As String = "" Dim Á¡°ËÇÊ As String = "" Dim Á¡°ËÀÚ As String = "" Dim Çѱ¹Àü·Â As String = "" Dim °íÀå½Å°í As String = "" '//170711 Dim ¼±·ÎÀü¹æ As String = "" Dim ¼±·ÎÁÂÃø As String = "" Dim ¼±·Î¿ìÃø As String = "" ''QRº¯¼ö ¼±¾ð 'Dim q½Ã°øÀÚ As String = "" 'Dim qȨÆäÀÌÁö As String = "" 'Dim q°ü¸® As String = "" 'Dim q°ü¸®1 As String = "" 'Dim q°ü¸®2 As String = "" Dim qrȨÆäÀÌÁö1 As String = "" Dim qrȨÆäÀÌÁö2 As String = "" Dim qrȨÆäÀÌÁö3 As String = "" Dim qrȨÆäÀÌÁö4 As String = "" Dim rqr±âŸ1 As String = "" Dim rqr±âŸ2 As String = "" Dim rqr±âŸ3 As String = "" Dim rqr±âŸ4 As String = "" Dim NoView As Boolean = False '//LOAD_STYLE À» Àá½Ã ½ÇÇàÇÏÁö ¾Ê±âÀ§ÇÞ(Áߺ¹½ÇÇà¹æÁö)¼­ µÐ´Ù. Dim °ü¸®±¸Á¶ÀÛµÊ As Boolean = True Dim Àü»ê¹øÈ£Á¶ÀÛµÊ As Boolean = True Dim ¼±·Î¸íÁ¶ÀÛµÊ As Boolean = True Dim ÀüÁÖ¹øÈ£Á¶ÀÛµÊ As Boolean = True Dim ½Ã°ø³â¿ùÁ¶ÀÛµÊ As Boolean = True Dim Á¤°ËÀÏÀÚÁ¶ÀÛµÊ As Boolean = True Dim SrcIdx As Integer = -1 '//¿øº» ¸®ºä¿¡¼­ Ŭ¸¯µÈ À妽º Dim Srcnum As Integer = -1 '//¿øº» ¸®ºå¿¡¼­ Ŭ¸¯µÈ ¹øÈ£°ª Dim Srcrow As DataRowView Dim FirstIdx As Integer = -1 '//»õ·Î »ý¼ºµÈ ¸®ºä¿¡¼­ Àû¿ëµÉ À妽º 'Public File As String = My.Application.Info.DirectoryPath & "\style.ini" '//½ºÅ¸ÀÏ ÆÄÀÏ Dim StyleDir As New System.IO.DirectoryInfo(My.Application.Info.DirectoryPath & "\style") Public FileC As String = My.Application.Info.DirectoryPath & "\styleC.ini" '//»ç¿ëÀÚ ½ºÅ¸ÀÏ ÆÄÀÏ Private WithEvents pDoc As New PrintDocument() Dim SelCon As New ArrayList '//¼±ÅÃµÈ ·¹À̺íµéÀÌ ÀúÀåµÈ ¹è¿­ÀÌ´Ù. Dim onlyOne As MyControlOLEDBv2.MyLabel '//Æ÷Ä¿½º¸¦ °¡Áø ·¹À̺íÀÌ´Ù. Dim srcTable As ireaDataSet.jjutableDataTable '//µ¥ÀÌÅͰ¡ ÀúÀåµÉ Å×À̺í Dim Dv As DataView '//µ¥ÀÌÅͺä(½ÇÁ¦·Î ÀÌ ºäÀÇ µ¥ÀÌÅ͸¦ °¡Áö°í Ãâ·ÂÀ» ÇàÇÑ´Ù.) Dim printindex As Integer = 0 '//ÇÁ¸°Æ®µÇ´Â ÆäÀÌÁö ¹øÈ£ À̰ªÀÌ -1 À̸é ÇöÀçÆäÀÌÁöÀ̹ǷΠ°»½ÅÇÏÁö ¾Ê°í Ãâ·ÂÇÑ´Ù. Dim PrintArray() As Integer '//ÇÁ¸°Æ®ÇÒ ÆäÀÌÁöÀÇ ¹è¿­¹øÈ£ Dim SettingFile As String = My.Application.Info.DirectoryPath & "\epole.ini" '//ȯ°æ¼³Á¤ ÆÄÀÏ Dim PrintMode As Boolean = False '//½ÇÁ¦Ãâ·ÂÀ϶§´Â true À» °¡Áø´Ù. Dim LastStyleName As String '//¸¶Áö¸·À¸·Î»ç¿ëÇѽºÅ¸Àϸí Public MyProperty_Paper As PropertyGrid_Paper Public Sub New() InitializeComponent() AddLog(Admin, "New()", "\Alllog.txt") End Sub Public Sub New(ByRef Src As ireaDataSet.jjutableDataTable, Optional ByVal IRow As DataRowView = Nothing) InitializeComponent() 'QR Ãß°¡ 'q½Ã°øÀÚ = d1 'qȨÆäÀÌÁö = d2 'q°ü¸® = d3 'q°ü¸®1 = d4 'q°ü¸®2 = d5 AddLog(Admin, "New(srctable,srcRow)", "\Alllog.txt") srcTable = Src '//°¡Á®¿Â Å×À̺íÀ» ÀÓ½ÃÅ×ÀÌºí¿¡ ÀúÀåÀ» ÇØµÎ°í »ç¿ëÇÑ´Ù. Srcrow = IRow '//À̰ÍÀº Ŭ¸¯µÈ Çà¹øÈ£ÀÌ´Ù. ÀÌ Çà¹øÈ£¸¦ °¡Áö°í ½ºÅ¸ÀÏÀ» ÆÇº°ÇÑ´Ù End Sub Private Sub printform_FormClosing(ByVal sender As Object, ByVal e As System.Windows.Forms.FormClosingEventArgs) Handles Me.FormClosing 'If Not BackWork Is Nothing Then BackWork = Nothing 'Me.CustFP1.ColSize_Save() Me.dataview.Setting_Save(False, "printjjung", "\viewConfig\main_") AddLog(Admin, "Form_Close", "\Alllog.txt") Save_Setting() End Sub Dim wat As New System.Diagnostics.Stopwatch Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Me.dataview.Setting_Load(False, "printjjung", "\viewConfig\main_") Me.SetStyle(ControlStyles.AllPaintingInWmPaint Or ControlStyles.UserPaint Or ControlStyles.DoubleBuffer, True) '//´õºí¹öÆÛ¸µ AddLog(Admin, "Form_Load()", "\Alllog.txt") GetPrintersName() '//ÇÁ¸°Å͸íÀ» °¡Á®¿É´Ï´Ù. Load_Setting() SetControls() '//ÄÁÆ®·ÑÀ» ÃʱâÈ­ÇÏ°í ¼ÂÆÃÇÑ´Ù. If srcTable Is Nothing Then MsgBox("¿øº»µ¥ÀÌÅͼҽº°¡ Á¤ÀǵÇÁö ¾Ê¾Ò½À´Ï´Ù", MsgBoxStyle.Critical, "È®ÀÎ") AddLog(Admin, "°³¹ßÀÚ ±âº»¼ÂÆÃÀ¸·Î Àüȯ()", "\Alllog.txt") Common.Admin = True Me.NoView = True 'Me.detTableAdapter1.Connection.ConnectionString = ConString 'Me.detTableAdapter1.Fill(Me.IreaDataSet1.jjutable, 1) 'Me.srcTable = Me.IreaDataSet1.jjutable Admin = True End If AddLog(Admin, "°³¹ßÀÚ¸ðµå=" & Admin.ToString, "\Alllog.txt") If Admin Then '//°³¹ßÀÚ¸ðµå´Â üũ¹Ú½º¸¦ »ç¿ëÇÒ¼ö ÀÖ°ÔÇÑ´Ù. showlog() For Each A As Control In Me.TabPage3.Controls If A.GetType.Name.ToUpper = "CHECKBOX" Then A.Visible = True End If Next End If Me.SETTOOLTIP() Console.WriteLine("Form_Load GetStyle List Start") wat.Restart() GetStyleList() '//style.ini ¿¡¼­ ½ºÅ¸Àϸñ·Ï¸í¸¸ °¡Á®¿Â´Ù. Console.WriteLine("Form_Load GetStyle List Time : " + wat.ElapsedMilliseconds.ToString() + "ms") wat.Stop() If Srcrow Is Nothing Then '//°¡Á®¿Â Çà°ªÀÌÀ妽º°¡ ¾øÀ¸¹Ç·Î 1¹øÂ° ½ºÅ¸ÀÏÀ» ÁöÁ¤ÇÑ´Ù. AddLog(Admin, "°¡Á®¿Â Çà°ªÀÌ ¾ø½À´Ï´Ù. firstidx=0 / ÀϹݿëÀ¸·Î ¼ÂÆÃÇÕ´Ï´Ù()", "\Alllog.txt") FirstIdx = 0 '//¶ÇÇÑ ¸Ç óÀ½ µ¥ÀÌÅ͸¦ Ç¥½ÃÇϰԵȴÙ. Me.cmb_style.Text = "ÀϹݿë" '//¿©±â¼­ µ¥ÀÌÅͰ¡ °É·¯Áö°ÔµÈ´Ù. Return End If '//¿©±â¼­ Çà°ªÀ» ºÐ¼®Çؼ­ ÄÞº¸¹Ü¸¦ ¼ÂÆÃÇØÁØ´Ù; '//ÀüºÎ ¼ÂÆÃµÈÈÄ ÇØ´ç °ªÀ» ¶Ç ã¾Æ¾ß ÇÑ´Ù. Srcnum = Srcrow("¹øÈ£") 'srcTable.Rows(SrcIdx).Item("¹øÈ£") AddLog(Admin, "¼±ÅõǼ­ ³Ñ¿À¿Âµ¥ÀÌÅÍÀÇ ¹øÈ£¸¦ ã½À´Ï´Ù=" & Srcnum, "\Alllog.txt") Console.WriteLine("Form_Load Events Step 2-1 : " + wat.ElapsedMilliseconds.ToString() + "ms") wat.Restart() Dim ±âÀÔ As Boolean = Srcrow("±âÀÔ") Dim ÀÎÀÔ As Boolean = Srcrow("ÀÎÀÔ") If Srcrow("dl¸í").ToString <> "" Then AddLog(Admin, "±â±â¿ëÀ¸·Î ÆÇº°()", "\Alllog.txt") Me.cmb_style.Text = "±â±â¿ë" '//¿©±â¼­ µ¥ÀÌÅͰ¡ °É·¯Áö°ÔµÈ´Ù. ElseIf ±âÀÔ AndAlso Not ÀÎÀÔ Then AddLog(Admin, "±âÀÔ¿ëÀ¸·Î ÆÇº°()", "\Alllog.txt") Me.cmb_style.Text = "±âÀÔ¿ë" '//¿©±â¼­ µ¥ÀÌÅͰ¡ °É·¯Áö°ÔµÈ´Ù. ElseIf ÀÎÀÔ Then AddLog(Admin, "ÀÎÀÔ¿ë =¼ÒÁÖ·Î ÆÇº°()", "\Alllog.txt") Me.cmb_style.Text = "ÀÎÀÔ¿ë" '//¿©±â¼­ µ¥ÀÌÅͰ¡ °É·¯Áö°ÔµÈ´Ù. End If If Me.cmb_style.SelectedIndex = -1 Then AddLog(Admin, "ÀϹݿëÀ¸·Î¼ÂÆÃÇÑ´Ù.()", "\Alllog.txt") If Me.LastStyleName.Trim = "Áß±Ô°Ý" Then Me.cmb_style.Text = "Áß±Ô°Ý" '//¿©±â¼­ µ¥ÀÌÅͰ¡ °É·¯Áö°ÔµÈ´Ù. Else Me.cmb_style.Text = "ÀϹݿë" '//¿©±â¼­ µ¥ÀÌÅͰ¡ °É·¯Áö°ÔµÈ´Ù. End If End If Me.cmb_jisun.SelectedIndex = 1 End Sub Private Sub printform_KeyDown(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles Me.KeyDown 'If SelCon Is Nothing Then Return 'Dim Tobj As MyControlOLEDBv2.MyLabel Select Case e.KeyCode Case Keys.Up If e.Shift Then '//±Û¾¾³ôÀÌ Me.CtrSize(True, -1) Else Me.CtrPos(True, -1) End If 'Me.ViewProperty(SelCon(0)) e.Handled = True Case Keys.Down If e.Shift Then Me.CtrSize(True, 1) Else Me.CtrPos(True, 1) End If 'ViewProperty(Tobj) e.Handled = True Case Keys.Left If e.Shift Then Me.CtrSize(False, -1) Else Me.CtrPos(False, -1) End If 'ViewProperty(Tobj) e.Handled = True Case Keys.Right If e.Shift Then Me.CtrSize(False, 1) Else Me.CtrPos(False, 1) End If 'ViewProperty(Tobj) e.Handled = True Case Keys.S If e.Control Then Me.bt_pattern_no.PerformClick() End If Case Keys.F4 '//°ü¸®±¸5¹øÀúÀå Me.Button8.PerformClick() Case Keys.F7 Me.bt_print.PerformButtonClick() Case Keys.F8 Me.bt_prnpreview.PerformClick() End Select End Sub Private Sub AddControl(ByRef CtlCnt As Short, ByVal ¼³¸í As String, ByVal tag As String, ByRef Labels() As MyControlOLEDBv2.MyLabel, ByRef Cb As CheckBox, ByVal bPattern As String) '//äũ¹Ú½º ½ÌÅ© Cb.Tag = tag Cb.Text = ¼³¸í For i As Integer = 0 To Labels.GetUpperBound(0) '//¸ðµç¹®ÀÚ¸¦ ÇÒ´çÇÑ´Ù. Labels(i) = New MyControlOLEDBv2.MyLabel Labels(i).¼³¸í = ¼³¸í & i + 1 Labels(i).DIV = tag Labels(i).Name = tag & i + 1 Labels(i).TextValue = "" Labels(i).Repeat = 0 Labels(i).RepeatX = 0 Labels(i).RepeatY = 0 Labels(i).Pattern = bPattern ReDim Preserve AllLabels(CtlCnt) Me.AllLabels(CtlCnt).ctl = Labels(i) Me.cmb_controls.Items.Add(Labels(i).¼³¸í) CtlCnt += 1 Next Labels(0).CheckBox = Cb Labels(0).Pattern = bPattern End Sub Private Sub SetControls() AddLog(Admin, "SetControls()", "\Alllog.txt") Dim CtlCnt As Short = 0 '//üũ¹Ú½º ¿À·ù AddControl(CtlCnt, "°ü¸®±¸", "H", Me.S°ü¸®±¸, Me.cb_kwang, "HNUMBERPATTERN") AddControl(CtlCnt, "ºñ°í¸í", "K", Me.Sºñ°í¸í, Me.cb_dl, "DLPATTERN") AddControl(CtlCnt, "Àü»ê¹øÈ£", "S", Me.SÀü»ê¹øÈ£, Me.cb_sunsannum, "JNUMPATTERN") AddControl(CtlCnt, "¼±·Î¸í", "L", Me.S¼±·Î¸í, Me.cb_sunglo, "LINEPATTERN") AddControl(CtlCnt, "ÀüÁÖ¹øÈ£", "X", Me.SÀüÁÖ¹øÈ£, Me.cb_jjnum, "NUMBERPATTERN") AddControl(CtlCnt, "½Ã°ø³â¿ù", "Y", Me.S½Ã°ø³â¿ù, Me.cb_yymm, "YYMMPATTERN") AddControl(CtlCnt, "°ü¸®±¸ÀüÁÖ¹øÈ£", "G", Me.S°ü¸®±¸ÀüÁÖ¹øÈ£, Me.cb_kwanjun, "NUMBERPATTERN") AddControl(CtlCnt, "Àåô", "J", Me.SÀåô, Me.cb_jangck, "CHOKPATTERN") '"NUMBERPATTERN") AddControl(CtlCnt, "½Ã°øÀÚ", "C", Me.S½Ã°øÀÚ, Me.cb_maker, "MAKERPATTERN") AddControl(CtlCnt, "Á¢Áö", "Z", Me.SÁ¢Áö, Me.cb_jji, "NUMBERPATTERN") AddControl(CtlCnt, "°¨µ¶ÀÚ", "M", Me.S°¨µ¶ÀÚ, Me.cb_man, "NUMBERPATTERN") AddControl(CtlCnt, "Á¡°ËÀÏÀÚ", "O", Me.SÁ¡°ËÀÏÀÚ, Me.cb_date, "LINEPATTERN") AddControl(CtlCnt, "Á¡°Ë", "HI", Me.SÁ¡°Ë, Me.cb_date1, "LINEPATTERN") AddControl(CtlCnt, "ÀϷùøÈ£", "N", Me.SÀϷùøÈ£, Me.cb_seq, "NUMBERPATTERN") AddControl(CtlCnt, "»ç¿ëÀÚ¹®ÀÚ1", "U", Me.S»ç¿ëÀÚ1, Me.cb_u1, "NUMBERPATTERN") AddControl(CtlCnt, "»ç¿ëÀÚ¹®ÀÚ2", "A", Me.S»ç¿ëÀÚ2, Me.cb_u2, "NUMBERPATTERN") AddControl(CtlCnt, "»ç¿ëÀÚ¹®ÀÚ3", "B", Me.S»ç¿ëÀÚ3, Me.cb_u3, "NUMBERPATTERN") AddControl(CtlCnt, "»ç¿ëÀÚ¹®ÀÚ4", "D", Me.S»ç¿ëÀÚ4, Me.cb_u4, "NUMBERPATTERN") AddControl(CtlCnt, "»ç¿ëÀÚ¹®ÀÚ5", "E", Me.S»ç¿ëÀÚ5, Me.cb_u5, "NUMBERPATTERN") AddControl(CtlCnt, "±¸°ü¸®Àü»ê¹øÈ£", "O1", Me.S±¸°ü¸®Àü»ê, Me.cb_oldjun, "NUMBERPATTERN") AddControl(CtlCnt, "º»ÁÖÁÙ¹øÈ£", "P", Me.Sº»ÁÖ¹øÈ£, Me.cb_mainrow, "NUMBERPATTERN") AddControl(CtlCnt, "º»ÁÖÀüÁÖ¹øÈ£", "Q", Me.Sº»ÁÖÀüÁÖ¹øÈ£, Me.cb_mainnum, "NUMBERPATTERN") AddControl(CtlCnt, "Á¡°ËÇÊ", "Z1", Me.SÁ¡°ËÇÊ, Me.cb_jump, "NUMBERPATTERN") AddControl(CtlCnt, "Á¡°ËÀÚ", "Z2", Me.SÁ¡°ËÀÚ, Me.cb_jumj, "NUMBERPATTERN") AddControl(CtlCnt, "Çѱ¹Àü·Â", "Z3", Me.SÇѱ¹Àü·Â, Me.cb_han, "NUMBERPATTERN") AddControl(CtlCnt, "°íÀå½Å°í", "Z4", Me.S°íÀå½Å°í, Me.cb_gojang, "NUMBERPATTERN") '//150201 AddControl(CtlCnt, "COSÈÞÁî¿ë·®", "F", Me.SÈÞÁî¿ë·®, Me.cb_ÈÞÁî¿ë·®, "FUSEPATTERN") AddControl(CtlCnt, "»óÇ¥½ÃÂû1´Ü", "I", Me.S»óÇ¥½ÃÂû1´Ü, Me.cb_»ó1´Ü, "SANG1PATTERN") AddControl(CtlCnt, "»óÇ¥½ÃÂû2´Ü", "T", Me.S»óÇ¥½ÃÂû2´Ü, Me.cb_»ó2´Ü, "SANG2PATTERN") '//ÀÌ°Ç Áö¼±ÁÖ¿¡°Å ¾´´Ù.Á¦¾î¿ëÀ¸·Î ¾¸ SÀüÁÖ¹øÈ£ÇÑÁÙ(0) = New MyControlOLEDBv2.MyLabel SÀüÁÖ¹øÈ£ÇÑÁÙ(0).¼³¸í = "ÇÑÁÙÀüÁÖ¹øÈ£" SÀüÁÖ¹øÈ£ÇÑÁÙ(0).Name = "R" SÀüÁÖ¹øÈ£ÇÑÁÙ(0).MyText = "" SÀüÁÖ¹øÈ£ÇÑÁÙ(0).Visible = False ReDim Preserve AllLabels(CtlCnt) Me.AllLabels(CtlCnt).ctl = SÀüÁÖ¹øÈ£ÇÑÁÙ(0) Me.cmb_controls.Items.Add(SÀüÁÖ¹øÈ£ÇÑÁÙ(0).¼³¸í) CtlCnt += 1 AddControl(CtlCnt, "±¸¼±·ÎÀüÁÖ¹øÈ£", "V", Me.S±¸¼±·ÎÀüÁÖ¹øÈ£, Me.cb_numo, "NUMBERPATTERN") AddControl(CtlCnt, "½Å¼±·ÎÀüÁÖ¹øÈ£", "W", Me.S½Å¼±·ÎÀüÁÖ¹øÈ£, Me.cb_numn, "NUMBERPATTERN") Me.cmb_jisun.SelectedIndex = 0 End Sub Private Sub SETTOOLTIP() AddLog(Admin, "Settooltip()", "\Alllog.txt") Dim TMSG As New System.Text.StringBuilder() TMSG.AppendLine() TMSG.AppendLine("¼±Åð¡´ÉÇÑ °³Ã¼¸ñ·ÏÀ» º¼ ¼ö ÀÕ½À´Ï´Ù") TMSG.AppendLine() TMSG.AppendLine("È­¸é¿¡ º¸ÀÌÁö ¾Ê´Â °³Ã¼µµ ¼±ÅÃÀÌ °¡´ÉÇÕ´Ï´Ù") TMSG.AppendLine() Me.ToolTip1.SetToolTip(Me.cmb_controls, TMSG.ToString) TMSG = New System.Text.StringBuilder("") TMSG.AppendLine() TMSG.AppendLine("¼±ÅÃµÈ °³Ã¼µéÀÇ È­¸éÇ¥½Ã¿©ºÎ¸¦ °áÁ¤Á¤ÇÕ´Ï´Ù") Me.ToolTip1.SetToolTip(Me.cb_visible, TMSG.ToString) TMSG = New System.Text.StringBuilder() TMSG.AppendLine() TMSG.AppendLine("¡å ¿¬¼ÓµÈ ÆäÀÌÁö´Â -(¸¶À̳ʽº) ·Î ±¸ºÐÇÕ´Ï´Ù") TMSG.AppendLine(" ¿¹) 2ÆäÀÌÁö¿¡¼­ 8ÆäÀÌÁö±îÁö : 2-8") TMSG.AppendLine() TMSG.AppendLine("¡å ºÒ±ÔÄ¢ ÆäÀÌÁö´Â ,(ÄÞ¸¶) ·Î ±¸ºÐÇÕ´Ï´Ù") TMSG.AppendLine(" ¿¹) 1,3,4,10 ÆäÀÌÁö : 1,3,4,7") TMSG.AppendLine() TMSG.AppendLine("¡å °¢Á¶°ÇÀÇ ±¸ºÐÀº /(½½·¡½¬) ·Î ±¸ºÐÇÕ´Ï´Ù") TMSG.AppendLine(" ¿¹) 2~8ÆäÀÌÁö¿Í 11,15¹ø ÆäÀÌÁö : 2-8/11,15") TMSG.AppendLine() Me.ToolTip1.SetToolTip(Me.rad_print_area, TMSG.ToString) TMSG = New System.Text.StringBuilder() TMSG.AppendLine() TMSG.AppendLine("<°³Ã¼µéÀÇ »óŸ¦ È®ÀÎÇÒ ¼ö ÀÖ½À´Ï´Ù>") TMSG.AppendLine() TMSG.AppendLine("´õºíŬ¸¯½Ã ÀÓ½ÃÀûÀ¸·Î ÇØ´ç ¹®ÀÚ¸¦ ¼öÁ¤ÇÒ ¼ö ÀÖ½À´Ï´Ù.") TMSG.AppendLine("¿ÞÂÊŬ¸¯½Ã ÇØ´ç°³Ã¼¸¸ ¼±Åõ˴ϴÙ.") TMSG.AppendLine("Ctrl + ¿ÞÂÊŬ¸¯½Ã ÇØ´ç°³Ã¼°¡ ¼ÓÇÑ ±×·ìÀÌ ¼±Åõ˴ϴÙ.") TMSG.AppendLine("¿ìŬ¸¯½Ã ¼±ÅÃµÈ °³Ã¼°¡ Ãß°¡µË´Ï´Ù(´ÙÁß¼±Åñâ´É)") TMSG.AppendLine() TMSG.AppendLine("[¹øÈ£Ãâ·Â½Ã »ö»ó±¸ºÐ]") TMSG.AppendLine("Èæ»ö : ¹®ÀÚÆÐÅÏ Àû¿ë") TMSG.AppendLine("³ì»ö : ±æÀÌÆÐÅÏ Àû¿ë") TMSG.AppendLine("Àû»ö : ±æÀÌ,¹®ÀÚÆÐÅÏ ¹ÌÀû¿ë") TMSG.AppendLine() TMSG.AppendLine(">>ȯ°æ¼³Á¤¿¡¼­ »ö»ó±¸ºÐÀÌ °¡´ÉÇϵµ·Ï ¼³Á¤µÇ¾î¾ß ÇÕ´Ï´Ù") TMSG.AppendLine() Me.ToolTip1.SetToolTip(Me.PictureBox1, TMSG.ToString) TMSG = New System.Text.StringBuilder() TMSG.AppendLine() TMSG.AppendLine("<»ç¿ëÇÒ ÇÁ¸°Å͸¦ ¼±ÅÃÇϼ¼¿ä>") TMSG.AppendLine() TMSG.AppendLine("¾Æ¹«°Íµµ ÀԷµÇÁö ¾Ê¾ÒÀ¸¸é ±âº»ÇÁ¸°ÅÍ·Î Ãâ·ÂµË´Ï´Ù.") TMSG.AppendLine("ÇöÀç ¼³Ä¡µÇ¾îÀÖ´Â ÇÁ¸°ÅÍ ¸ñ·ÏÀÌ Ç¥½ÃµË´Ï´Ù.") TMSG.AppendLine() Me.combobox5.ToolTipText = TMSG.ToString 'Me.ToolTip1.SetToolTip(Me.ComboBox5, TMSG.ToString) TMSG = New System.Text.StringBuilder() TMSG.AppendLine() TMSG.AppendLine("<È­¸í Áß¾ÓÀÇ 1/2 ¹Ì¸®º¸±â âÀÇ È°¼ºÈ­ ¿©ºÎ>") TMSG.AppendLine() TMSG.AppendLine("Ŭ¸¯ÇØÁ¦½Ã Áß¾Ó ¹Ì¸®º¸±â È­¸éÀÌ Ç¥½ÃµÇÁö ¾Ê½À´Ï´Ù") TMSG.AppendLine() 'Me.ToolTip1.SetToolTip(Me.chb_preview, TMSG.ToString) 'Me.ToolTip1.SetToolTip(Me.ComboBox5, TMSG.ToString) TMSG = New System.Text.StringBuilder() TMSG.AppendLine() TMSG.AppendLine("<2¹øÂ° ÀåÀÌ Ãâ·ÂµÉ À§Ä¡¸¦ °áÁ¤Çϼ¼¿ä.>") TMSG.AppendLine() TMSG.AppendLine("2¹øÂ° ÀåÀÌ Ãâ·ÂµÉ¶§ 1¹øÂ°Àå°úÀÇ ¿ÞÂʰŸ® °ªÀÔ´Ï´Ù. 0 À¸·ÎÇÒ°æ¿ì µ¿ÀÏÇÑ X°ªÀÌ µË´Ï´Ù.") TMSG.AppendLine("°°Àº ÁÙ ¾Æ·¡ÂÊ¿¡ Ç¥½Ã¸¦ ÇÏ·Á¸é X=0 À¸·ÎµÎ°í Y=°ªÀ» ÀÓÀÇ·Î ÀÔ·ÂÇϼ¼¿ä") TMSG.AppendLine() Me.ToolTip1.SetToolTip(Me.tb_secX, TMSG.ToString) TMSG = New System.Text.StringBuilder() TMSG.AppendLine() TMSG.AppendLine("<2¹øÂ° ÀåÀÌ Ãâ·ÂµÉ À§Ä¡¸¦ °áÁ¤Çϼ¼¿ä.>") TMSG.AppendLine() TMSG.AppendLine("2¹øÂ° ÀåÀÌ Ãâ·ÂµÉ¶§ 1¹øÂ°Àå°úÀÇ À§ÂʰŸ® °ªÀÔ´Ï´Ù. 0 À¸·ÎÇÒ°æ¿ì µ¿ÀÏÇÑ Y°ªÀÌ µË´Ï´Ù.") TMSG.AppendLine("°°Àº ÁÙ ¾Æ·¡ÂÊ¿¡ Ç¥½Ã¸¦ ÇÏ·Á¸é X=0 À¸·ÎµÎ°í Y=°ªÀ» ÀÓÀÇ·Î ÀÔ·ÂÇϼ¼¿ä") TMSG.AppendLine() Me.ToolTip1.SetToolTip(Me.tb_secY, TMSG.ToString) TMSG = New System.Text.StringBuilder() TMSG.AppendLine() TMSG.AppendLine("<2Àå Ãâ·Â½Ã µ¥ÀÌÅÍÀÇ Ãâ·Â¹æ¹ýÀ» ¼±ÅÃÇϼ¼¿ä.>") TMSG.AppendLine("<1Àå¿¡ µÎ¹øÀÇ µ¥ÀÌÅͰ¡ Ç¥½ÃµË´Ï´Ù.>") TMSG.AppendLine() TMSG.AppendLine("[º¹»ç]´Â ÇöÀçµ¥ÀÌÅÍ¿Í µ¿ÀÏÇÑ µ¥ÀÌÅͰ¡ Ç¥½ÃµË´Ï´Ù.") TMSG.AppendLine("[´ÙÀ½]Àº ´ÙÀ½µ¥ÀÌÅͰ¡ Ç¥½ÃµË´Ï´Ù.") TMSG.AppendLine() TMSG.AppendLine("[´ÙÀ½] Ãâ·Â½Ã ¹Ì¸®º¸±â»óÅ¿¡´Â ÇöÀçµ¥ÀÌÅͰ¡ Ç¥½ÃµÇÁö¸¸") TMSG.AppendLine("½ÇÁ¦ Ãâ·Â½Ã¿¡´Â ´ÙÀ½µ¥ÀÌÅͰ¡ Ç¥½ÃµË´Ï´Ù.") Me.ToolTip1.SetToolTip(Me.cmb_dummy, TMSG.ToString) 'TMSG = New System.Text.StringBuilder() 'TMSG.AppendLine() 'TMSG.AppendLine("<¼±Åýà [±âŸ½ºÅ¸ÀÏ-Àåô3ÀÚ¸®»ç¿ë] ÀÌ Àû¿ëµË´Ï´Ù>") 'TMSG.AppendLine() 'TMSG.AppendLine("Àåô 3ÀÚ¸®»óÅÂÀ϶§ ¿øÇÏ´Â À§Ä¡¹× Å©±â·Î ÀåôÀ» º¯°æÇÑ ÈÄ") 'TMSG.AppendLine("ÀúÀå½Ã¿¡´Â ¹Ýµå½Ã [±âŸ½ºÅ¸ÀÏÀúÀå]À» Ŭ¸¯Çϼ¼¿ä.") 'TMSG.AppendLine() 'TMSG.AppendLine("ÀϹݽºÅ¸ÀÏÀúÀåÀ» Çϸé ÀúÀåÀ§Ä¡°¡ À߸øµÉ ¼ö ÀÖ½À´Ï´Ù.") 'Me.ToolTip1.SetToolTip(Me.cb_jc1, TMSG.ToString) TMSG = New System.Text.StringBuilder() TMSG.AppendLine("³ì»öÀº ±æÀÌÆÐÅϸ¸ Àû¿ëµÈ ¾ÆÀÌÅÛÀ̸ç") TMSG.AppendLine("Àû»öÀº ±æÀÌ,¹®ÀÚÆÐÅÏÀÌ Á¸ÀçÇÏÁö ¾Ê´Â ¾ÆÀÌÅÛÀÔ´Ï´Ù") TMSG.AppendLine("Èæ»öÀº ¹®ÀÚÆÐÅÏÀ̳ª ±æÀÌ,¹®ÀÚÆÐÅÏÀÌ Á¸ÀçÇÏ´Â °æ¿ìÀÔ´Ï´Ù.") TMSG.AppendLine() 'Me.ToolTip1.SetToolTip(Me.X1, X1.¼³¸í & vbCrLf & TMSG.ToString) 'Me.ToolTip1.SetToolTip(Me.X2, X2.¼³¸í & vbCrLf & TMSG.ToString) 'Me.ToolTip1.SetToolTip(Me.X3, X3.¼³¸í & vbCrLf & TMSG.ToString) End Sub Private Sub con_dclick(ByVal sender As Object, ByVal e As System.EventArgs) AddLog(Admin, "°³Ã¼¸¦ ´õºíŬ¸¯Çß½À´Ï´Ù.(À̰ÍÀº »ç¿ëµÇÁö ¾ÊÀ½)", "\Alllog.txt") Dim Msg As New System.Text.StringBuilder("º¯°æÇÒ °ªÀ» ÀÔ·ÂÇϼ¼¿ä") Msg.AppendLine("ÁٹٲÞÀ»ÇÏ·Á¸é \n À» ÀÔ·ÂÇϼ¼¿ä") Msg.AppendLine("¿¹) ¼¼·Î·Î 12¸¦ Ãâ·ÂÇÏ·Á¸é 1\n2 À» ÀÔ·ÂÇϼ¼¿ä") Msg.AppendLine() Msg.AppendLine("º¯°æÇÑ °ªÀº ÇöÀçÆäÀÌÁö¿¡¸¸ Àû¿ëµË´Ï´Ù") Dim A As MyControlOLEDBv2.MyLabel = sender Dim Val As String = InputBox(Msg.ToString, "º¯°æ", A.MyText) If Val = "" Then Return Val = Val.Replace("\n", vbCrLf) A.MyText = Val '//preview ´Â ¾Æ¸¶µµ ÇÈÃĹڽº ´õºíŬ¸¯¿¡¼­ Á¤ÀÇÇѵí ÇÏ´Ù. End Sub Private Sub Save_Setting() AddLog(Admin, "ÇöÀç ¼³Á¤(½ºÅ¸ÀÏ)À» ÀúÀåÇÕ´Ï´Ù.", "\Alllog.txt") Dim A As New MyINI2(SettingFile) A.Write("PRINTFORM", "printername", Me.combobox5.Text) '//ÆÐÅϰ˻çÁ¶°Ç ÄÞº¸¹Ú½º '//¸¶Áö¸·À¸·Î´Ý¾ÑÀ»¶§ÀǽºÅ¸ÀϸíÀ»±â¾ïÇÑ´Ù. ' MsgBox("½ºÅ¸ÀÏÀúÀåÇÑ´Ù " & Me.cmb_style.Text) A.Write("lastStyle", "name", Me.cmb_style.Text) End Sub Private Sub Load_Setting() AddLog(Admin, "ÇöÀç¼³Á¤(½ºÅ¸ÀÏ)À» °¡Á®¿É´Ï´Ù.()", "\Alllog.txt") AddLog(Admin, "Load_Setting()", "\Alllog.txt") Dim a As New MyINI2(SettingFile) Me.combobox5.Text = a.Read("PRINTFORM", "printername", "") Me.LastStyleName = a.Read("lastStyle", "name") End Sub Public Sub GeTviewData(ByVal index As Integer, ByVal previewWindow As Boolean, Optional ByRef ¹øÈ£ÆÐÅϰ˻ç As Integer = -1) ' Dim STARTTIME, ENDTIME As Date AddLog(Admin, "GetviewData ÁøÀÔ()", "\Alllog.txt") 'MsgBox("getview = " & index) Console.WriteLine("GetTviewData") If Dv.Count <= 0 OrElse index < 0 OrElse index > Dv.Count Then AddLog(Admin, "GetViewData : À妽º°¡ ¾ø°Å³ª ¹®Á¦°¡ Àվ ¸®ÅÏÇÕ´Ï´Ù.(" & index & ")", "\Alllog.txt") 'MsgBox("GETVIEWDATA : µ¥ÀÌÅͰ¡ ¾ø°Å³ª À߸øµÈ À妽º ÀÔ´Ï´Ù", MsgBoxStyle.Information, "È®ÀÎ") ' & index & "/" & Me.CustFP1.ActiveSheet.RowCount & ")", MsgBoxStyle.Critical, "È®ÀÎ") Return '//À߸øµÈ À妽º´Â ¸®ÅÏ End If ' STARTTIME = Now '//ÇöÀç Å×ÀÌºí¿¡¼­ µ¥ÀÌÅ͸¦ Ç¥½ÃÇÑ´Ù. Çö Å×À̺íÀº Á¾·ùº°·Î ±¸ºÐÁö¾îÁø Å×À̺íÀÌ´Ù DV '//¸ðµçµ¥ÀÌÅ͸¦ ÄÁÆ®·Ñ¿¡Ç¥½ÃÇÑÈÄ Ãâ·Â¹°ÀÇ ±¸ºÐ(ÀϹݿë/±âÀÔµî)À» Áþ´Â´Ù. 'Dim ¼±·Î¸íÆÐÅϰ˻ç As Integer = 0 'Dim ÀåôÆÐÅϰ˻è As Integer = 0 ' Me.DataGridView1.DataSource = Dv ±¸°ü¸®±¸ = GetSpread(Me.Dv, index, "±¸°ü¸®±¸") ±¸Àü»ê¹øÈ£ = GetSpread(Me.Dv, index, "±¸Àü»ê¹øÈ£") °ü¸®±¸ = GetSpread(Me.Dv, index, "°ü¸®±¸") Àü»ê¹øÈ£ = GetSpread(Me.Dv, index, "ÀüÁÖ¹øÈ£") ¼±·Î¸í = GetSpread(Me.Dv, index, "¼±·Î¸í") ¹øÈ£ = GetSpread(Me.Dv, index, "¹øÈ£1") & GetSpread(Me.Dv, index, "¹øÈ£2") & GetSpread(Me.Dv, index, "¹øÈ£3") & GetSpread(Me.Dv, index, "¹øÈ£4") & GetSpread(Me.Dv, index, "¹øÈ£5") Àåô = GetSpread(Me.Dv, index, "Àåô") ½Ã°ø³â¿ù = GetSpread(Me.Dv, index, "½Ã°ø³â¿ù") ½Ã°øÀÚ = GetSpread(Me.Dv, index, "½Ã°øÀÚ") °¨µ¶ÀÚ = GetSpread(Me.Dv, index, "°¨µ¶ÀÚ") Á¡°ËÀÏÀÚ = GetSpread(Me.Dv, index, "Á¡°ËÀÏÀÚ") 'Á¡°Ë = GetSpread(Me.Dv, index, "Á¡°Ë") 'Á¡°ËÀÚ = GetSpread(Me.Dv, index, "Á¡°ËÀÚ") 'Á¡°ËÇÊ = GetSpread(Me.Dv, index, "Á¡°ËÇÊ") 'Çѱ¹Àü·Â = GetSpread(Me.Dv, index, "Çѱ¹Àü·Â") '°íÀå½Å°í = GetSpread(Me.Dv, index, "°íÀå½Å°í") Á¢Áö1 = GetSpread(Me.Dv, index, "Á¢ÁöÀúÇ×1") Á¢Áö2 = GetSpread(Me.Dv, index, "Á¢ÁöÀúÇ×2") ºñ°í¸í = GetSpread(Me.Dv, index, "DL¸í") ±¸¼±·Î¸í = GetSpread(Me.Dv, index, "±¸¼±·Î¸í") ±¸ÀüÁÖ¹øÈ£ = GetSpread(Me.Dv, index, "±¸ÀüÁÖ¹øÈ£") '//150201 ÈÞÁî¿ë·® = GetSpread(Me.Dv, index, "COSÈÞÁî¿ë·®") »óÇ¥½ÃÂû1´Ü = GetSpread(Me.Dv, index, "»óÇ¥½ÃÂû1´Ü") »óÇ¥½ÃÂû2´Ü = GetSpread(Me.Dv, index, "»óÇ¥½ÃÂû2´Ü") '//170711 ¼±·ÎÀü¹æ = GetSpread(Me.Dv, index, "¼±·ÎÀü¹æ") ¼±·ÎÁÂÃø = GetSpread(Me.Dv, index, "¼±·ÎÁÂÃø") ¼±·Î¿ìÃø = GetSpread(Me.Dv, index, "¼±·Î¿ìÃø") AddLog(Admin, "½Ã°ø³â¿ù " & Dv(index)("½Ã°ø³â¿ù"), "\Alllog.txt") '//¿©±â¼­ Àμâ(Áö¼±ÁÖ)ÀÇ º»ÁÖ¹øÈ£¿Í º»ÁÖ¹øÈ£¸¦ Ãâ·ÂÇÑ´Ù¸é ã¾Æ¼­ º¸¿©ÁØ´Ù. 'addlog(admin, "ENTERING : Áö¼±ÁÖ(º»ÁÖÈ®ÀÎ)", "\Alllog.txt") If ¹øÈ£.IndexOf("G") > -1 OrElse ¹øÈ£.IndexOf("K") > -1 Then 'addlog(admin, "Áö¼±ÁÖÈ®ÀεÊ(" & ¹øÈ£ & ")", "\Alllog.txt") If Me.cb_mainrow.Checked OrElse Me.cb_mainnum.Checked Then '//º»ÁÖ¸¦ º¸¿©ÁÙÀÏÀÌ ÀÖÀ»°æ¿ì¶ó¸é Dim MAINNUM As String = "" If ¹øÈ£.IndexOf("K") > -1 Then MAINNUM = ¹øÈ£.Substring(0, ¹øÈ£.IndexOf("K")) If ¹øÈ£.IndexOf("G") > -1 Then MAINNUM = ¹øÈ£.Substring(0, ¹øÈ£.IndexOf("G")) Dim MAINROW As Integer = -1 For Z As Integer = index To 0 Step -1 '//ÇöÀçºÎÅÍ Ã³À½°¡Áö È®ÀÎÇÑ´Ù. If CStr(Dv(Z)("¹øÈ£1") & Dv(Z)("¹øÈ£2") & Dv(Z)("¹øÈ£3") & Dv(Z)("¹øÈ£4") & Dv(Z)("¹øÈ£5")).Trim = MAINNUM Then '//º»ÁÖ¸¦ ã¾Ò´Ù¸é MAINROW = Dv(Z)("¹øÈ£") Exit For End If Next For Z As Integer = index To Dv.Count - 1 If CStr(Dv(Z)("¹øÈ£1") & Dv(Z)("¹øÈ£2") & Dv(Z)("¹øÈ£3") & Dv(Z)("¹øÈ£4") & Dv(Z)("¹øÈ£5")).Trim = MAINNUM Then '//º»ÁÖ¸¦ ã¾Ò´Ù¸é MAINROW = Dv(Z)("¹øÈ£") Exit For End If Next 'MsgBox("OK") If MAINROW <> -1 Then PARSE_º»ÁÖ(MAINROW, MAINNUM) Else AddLog(Admin, "Áö¼±ÁÖÈ®ÀεÊ(" & ¹øÈ£ & ") Ç㳪 üũµÈ°Ô ¾ø¾î¼­ Ç¥½Ã¸¦ ÇÏÁö ¾Ê´Â´Ù.", "\Alllog.txt") Me.CLEAR_ITEM(Me.Sº»ÁÖ¹øÈ£) Me.CLEAR_ITEM(Sº»ÁÖÀüÁÖ¹øÈ£) End If Else AddLog(Admin, "Áö¼±Á־ƴÔ(" & ¹øÈ£ & ")", "\Alllog.txt") Me.CLEAR_ITEM(Me.Sº»ÁÖ¹øÈ£) Me.CLEAR_ITEM(Sº»ÁÖÀüÁÖ¹øÈ£) End If 'addlog(admin, "ENDING : Áö¼±ÁÖ(º»ÁÖÈ®ÀÎ)", "\Alllog.txt") If ±¸°ü¸®±¸ <> "" AndAlso ±¸Àü»ê¹øÈ£ <> "" Then ±¸°ü¸®Àü»ê = ±¸°ü¸®±¸ & "-" & ±¸Àü»ê¹øÈ£ Else ±¸°ü¸®Àü»ê = "" End If If ±¸¼±·Î¸í <> "" Then ±¸¼±·ÎÀüÁÖ¹øÈ£ = CStr(±¸¼±·Î¸í & "-" & ±¸ÀüÁÖ¹øÈ£).Trim Else ±¸¼±·ÎÀüÁÖ¹øÈ£ = CStr(±¸ÀüÁÖ¹øÈ£).Trim End If Á¡°ËÀÚ = CStr("Á¡°ËÀÚ :").Trim Á¡°ËÇÊ = CStr("Á¡°ËÇÊ").Trim Çѱ¹Àü·Â = CStr("Çѱ¹Àü·Â").Trim °íÀå½Å°í = gojang.Text.ToString() If ¼±·Î¸í <> "" Then ½Å¼±·ÎÀüÁÖ¹øÈ£ = CStr(¼±·Î¸í & "-" & ¹øÈ£).Trim Else ½Å¼±·ÎÀüÁÖ¹øÈ£ = CStr(¹øÈ£).Trim End If ±¸¼±·ÎÀüÁÖ¹øÈ£ = ±¸¼±·ÎÀüÁÖ¹øÈ£.Replace(";", "") ½Å¼±·ÎÀüÁÖ¹øÈ£ = ½Å¼±·ÎÀüÁÖ¹øÈ£.Replace(";", "") AddLog(Admin, "Complete : Load Data From Dataview", "\Alllog.txt") Me.Text = "°¡°ø¹øÈ£Âû Ãâ·ÂÀÛ¾÷(" & ¹øÈ£ & ")" AddLog(Admin, "PASE±¸¹®À» ½ÇÇàÇÕ´Ï´Ù.()", "\Alllog.txt") '============ ¿©±â´Â µû·Î ÇØ¼®ÀÌ ¾ø´Â°÷ÀÌ´Ù ========================================================== Me.PARSE_Á¢Áö1(Á¢Áö1) Me.PARSE_Á¢Áö2(Á¢Áö2) '==================================================================================================== AddLog(Admin, "ÆÐÅÏÀÌÀÖ´Â PASE ±¸¹®À» ½ÇÇàÇÕ´Ï´Ù.()", "\Alllog.txt") If PARSE_°¨µ¶ÀÚ(°¨µ¶ÀÚ) Then Me.PARSE_°¨µ¶ÀÚÆÐÅÏ(°¨µ¶ÀÚ) '//¼±·Î¸íÀ» ÇØ¼®ÈÄ °¡Á®¿ÂÈÄ ÆÐÅϺм®ÈÄ Àû¿ë If PARSE_°ü¸®±¸(°ü¸®±¸) Then Me.PARSE_°ü¸®±¸ÆÐÅÏ(°ü¸®±¸) '//¼±·Î¸íÀ» ÇØ¼®ÈÄ °¡Á®¿ÂÈÄ ÆÐÅϺм®ÈÄ Àû¿ë If PARSE_Àåô(Àåô) Then Me.PARSE_ÀåôÆÐÅÏ(Àåô) '//¼±·Î¸íÀ» ÇØ¼®ÈÄ °¡Á®¿ÂÈÄ ÆÐÅϺм®ÈÄ Àû¿ë If Me.PARSE(¼±·Î¸í, Me.S¼±·Î¸í) Then Me.PARSE_PATTERN(¼±·Î¸í, Me.S¼±·Î¸í) If Me.PARSE(Àü»ê¹øÈ£, Me.SÀü»ê¹øÈ£) Then Me.PARSE_PATTERN(Àü»ê¹øÈ£, Me.SÀü»ê¹øÈ£) If Me.PARSE(½Ã°ø³â¿ù, Me.S½Ã°ø³â¿ù) Then Me.PARSE_PATTERN(½Ã°ø³â¿ù, Me.S½Ã°ø³â¿ù) If Me.PARSE(½Ã°øÀÚ, Me.S½Ã°øÀÚ) Then Me.PARSE_PATTERN(½Ã°øÀÚ, Me.S½Ã°øÀÚ) If Me.PARSE(Á¡°ËÀÏÀÚ, Me.SÁ¡°ËÀÏÀÚ) Then Me.PARSE_PATTERN(Á¡°ËÀÏÀÚ, Me.SÁ¡°ËÀÏÀÚ) 'If Me.PARSE(Á¡°Ë, Me.SÁ¡°Ë) Then Me.PARSE_PATTERN(Á¡°Ë, Me.SÁ¡°Ë) If Me.PARSE(Á¡°ËÀÚ, Me.SÁ¡°ËÀÚ) Then Me.PARSE_PATTERN(Á¡°ËÀÚ, Me.SÁ¡°ËÀÚ) If Me.PARSE(Á¡°ËÇÊ, Me.SÁ¡°ËÇÊ) Then Me.PARSE_PATTERN(Á¡°ËÇÊ, Me.SÁ¡°ËÇÊ) If Me.PARSE(Çѱ¹Àü·Â, Me.SÇѱ¹Àü·Â) Then Me.PARSE_PATTERN(Çѱ¹Àü·Â, Me.SÇѱ¹Àü·Â) If Me.PARSE(°íÀå½Å°í, Me.S°íÀå½Å°í) Then Me.PARSE_PATTERN(°íÀå½Å°í, Me.S°íÀå½Å°í) '//1501201 If Me.PARSE(ÈÞÁî¿ë·®, Me.SÈÞÁî¿ë·®) Then Me.PARSE_PATTERN(ÈÞÁî¿ë·®, Me.SÈÞÁî¿ë·®) If Me.PARSE(»óÇ¥½ÃÂû1´Ü, Me.S»óÇ¥½ÃÂû1´Ü) Then Me.PARSE_PATTERN(»óÇ¥½ÃÂû1´Ü, Me.S»óÇ¥½ÃÂû1´Ü) If Me.PARSE(»óÇ¥½ÃÂû2´Ü, Me.S»óÇ¥½ÃÂû2´Ü) Then Me.PARSE_PATTERN(»óÇ¥½ÃÂû2´Ü, Me.S»óÇ¥½ÃÂû2´Ü) 'If PARSE_DL¸í(ºñ°í¸í) Then Me.PARSE_DL¸íÆÐÅÏ(ºñ°í¸í) '/ºñ°í¸í Ãß°¡Çß´Ù. 2013/06/13 Àӽà ¸·¾Æ³õÀ½... If Me.PARSE(ºñ°í¸í, Me.Sºñ°í¸í) Then Me.PARSE_PATTERN(ºñ°í¸í, Me.Sºñ°í¸í) ' addlog(admin, "New()", "\Alllog.txt") If PARSE_¹øÈ£(¹øÈ£, GetSpread(Me.Dv, index, "Àμâ")) Then '//¿©±â¼­ False ´Â Ãâ·ÂÀÇÀǹ̰¡ ¾ø´Ù ¹øÈ£ÆÐÅϰ˻ç = Me.PARSE_¹øÈ£ÆÐÅÏ(¹øÈ£) '//¼±·Î¸íÀ» ÇØ¼®ÈÄ ÆÐÅϺм® Àû¿ë AddLog(Admin, "¹øÈ£ÆÐÅϰ˻簡 ¿Ï·áµÇ¾ú½À´Ï´Ù.=" & ¹øÈ£ÆÐÅϰ˻ç, "\Alllog.txt") If NUMCOLOR Then '//ȯ°æ¼³Á¤¿¡¼­ »ö»óº¸±â°¡ ¼±ÅõǾîÀÖ´Ù¸é If ¹øÈ£ÆÐÅϰ˻ç = 3 Then '//µÑ´Ù¾ø´Ù. '//µÑ´Ù¾ø´Â ºÎºÐÀÌ¶ó¼­ ¿©±â¼­´Â µðÆúÆ®¸¦ Àâ¾ÆÁØ´Ù. For i As Short = 0 To Me.SÀüÁÖ¹øÈ£.GetUpperBound(0) Me.SÀüÁÖ¹øÈ£(i).MyForeColor = Drawing.Color.Red Next ElseIf ¹øÈ£ÆÐÅϰ˻ç = 2 Then '//¹®ÀÚ°¡¾ø°í ±æÀ̸¸ ÀÖ´Ù. For i As Short = 0 To Me.SÀüÁÖ¹øÈ£.GetUpperBound(0) Me.SÀüÁÖ¹øÈ£(i).MyForeColor = Drawing.Color.Green Next Else '//¹®ÀÚ¸¸ Àְųª µÑ´ÙÀÖ´Ù. '//0À̸é ÀÌ¸é µÑ´ÙÀÖ´Ù 1ÀÌ¸é ¹®ÀÚµµ ¾ø°í ±æÀ̵µ ¾ø´Ù ±æÀ̰¡ ¾ø´Ù For i As Short = 0 To Me.SÀüÁÖ¹øÈ£.GetUpperBound(0) Me.SÀüÁÖ¹øÈ£(i).MyForeColor = Drawing.Color.Black Next End If End If End If AddLog(Admin, "±¸°ü¸®Àü»ê,ÀϷùøÈ£,°ü¸®Àü»êÇ¥½Ã¿©ºÎ¸¦ pase ÇÕ´Ï´Ù.()", "\Alllog.txt") '========================= ±âŸ ================================================= '//ÀÌ·¯¸é Ç¥½ÃÇØ¾ßÇÑ´Ù. 'MsgBox(±¸°ü¸®Àü»ê) If ±¸°ü¸®Àü»ê <> "" AndAlso Me.cb_oldjun.Checked Then 'MsgBox("±¸°ü¸®Àü»ê=" & ±¸°ü¸®Àü»ê) Me.S±¸°ü¸®Àü»ê(0).MyText = ±¸°ü¸®Àü»ê Me.S±¸°ü¸®Àü»ê(0).Visible = True Else Me.S±¸°ü¸®Àü»ê(0).Visible = False End If If ±¸¼±·ÎÀüÁÖ¹øÈ£ <> "" AndAlso Me.cb_numo.Checked Then Me.S±¸¼±·ÎÀüÁÖ¹øÈ£(0).MyText = ±¸¼±·ÎÀüÁÖ¹øÈ£ Me.S±¸¼±·ÎÀüÁÖ¹øÈ£(0).Visible = True Else Me.S±¸¼±·ÎÀüÁÖ¹øÈ£(0).Visible = False End If ' If chk_draw.Checked Then If cb_date1.Checked Then '//Á¡°ËÀÚ ' If Me.cb_jumj.Checked Then Me.SÁ¡°ËÀÚ(0).MyText = Á¡°ËÀÚ Me.SÁ¡°ËÀÚ(0).Visible = True ' Else ' Me.SÁ¡°ËÀÚ(0).Visible = False ' End If '//Á¡°ËÇÊ 'If cb_jump.Checked Then Me.SÁ¡°ËÇÊ(0).MyText = Á¡°ËÇÊ Me.SÁ¡°ËÇÊ(0).Visible = True 'Else 'Me.SÁ¡°ËÇÊ(0).Visible = False 'End If '//Çѱ¹Àü·Â 'If cb_han.Checked Then Me.SÇѱ¹Àü·Â(0).MyText = Çѱ¹Àü·Â Me.SÇѱ¹Àü·Â(0).Visible = True 'Else ' Me.SÇѱ¹Àü·Â(0).Visible = False 'End If ' End If Else Me.SÁ¡°ËÀÚ(0).Visible = False Me.SÁ¡°ËÇÊ(0).Visible = False Me.SÇѱ¹Àü·Â(0).Visible = False End If Me.S°íÀå½Å°í(0).Visible = cb_gojang.Checked '//150201 Me.SÈÞÁî¿ë·®(0).Visible = cb_ÈÞÁî¿ë·®.Checked If cb_»ó1´Ü.Checked AndAlso »óÇ¥½ÃÂû1´Ü <> "" Then Me.S»óÇ¥½ÃÂû1´Ü(0).Visible = True Me.S»óÇ¥½ÃÂû1´Ü(1).Visible = True Me.S»óÇ¥½ÃÂû1´Ü(2).Visible = True Else Me.S»óÇ¥½ÃÂû1´Ü(0).Visible = False Me.S»óÇ¥½ÃÂû1´Ü(1).Visible = False Me.S»óÇ¥½ÃÂû1´Ü(2).Visible = False End If If cb_»ó2´Ü.Checked AndAlso »óÇ¥½ÃÂû2´Ü <> "" Then Me.S»óÇ¥½ÃÂû2´Ü(0).Visible = True Me.S»óÇ¥½ÃÂû2´Ü(1).Visible = True Me.S»óÇ¥½ÃÂû2´Ü(2).Visible = True Else Me.S»óÇ¥½ÃÂû2´Ü(0).Visible = False Me.S»óÇ¥½ÃÂû2´Ü(1).Visible = False Me.S»óÇ¥½ÃÂû2´Ü(2).Visible = False End If If ½Å¼±·ÎÀüÁÖ¹øÈ£ <> "" AndAlso Me.cb_numn.Checked Then Me.S½Å¼±·ÎÀüÁÖ¹øÈ£(0).MyText = ½Å¼±·ÎÀüÁÖ¹øÈ£ Me.S½Å¼±·ÎÀüÁÖ¹øÈ£(0).Visible = True Else Me.S½Å¼±·ÎÀüÁÖ¹øÈ£(0).Visible = False End If If Me.cb_seq.Checked Then Me.SÀϷùøÈ£(0).MyText = GetSpread(Me.Dv, index, "¹øÈ£") 'index + 1 Me.SÀϷùøÈ£(0).Visible = True Else Me.SÀϷùøÈ£(0).Visible = False End If If °ü¸®±¸ <> "" AndAlso Àü»ê¹øÈ£ <> "" AndAlso Me.cb_kwanjun.Checked Then Me.S°ü¸®±¸ÀüÁÖ¹øÈ£(0).MyText = °ü¸®±¸ & "-" & Àü»ê¹øÈ£ Me.S°ü¸®±¸ÀüÁÖ¹øÈ£(0).Visible = True Else Me.S°ü¸®±¸ÀüÁÖ¹øÈ£(0).Visible = False End If 'If ¹øÈ£.Trim <> "" AndAlso Me.cb_jnumrow.Checked Then '//ÇÑÁÙÀüÁÖ¹øÈ£ Ç¥½Ã¿©ºÎ ' Me.SÀüÁÖ¹øÈ£ÇÑÁÙ.MyText = ¹øÈ£ ' Me.SÀüÁÖ¹øÈ£ÇÑÁÙ.Visible = True 'Else ' Me.SÀüÁÖ¹øÈ£ÇÑÁÙ.Visible = False 'End If AddLog(Admin, "»ç¿ëÀÚ¹®ÀÚÀÇ Ç¥½Ã¿©ºÎ¸¦ °áÁ¤ÇÕ´Ï´Ù.()", "\Alllog.txt") '»ç¿ëÀÚ¹®ÀÚÀÇ Ç¥½Ã¿©ºÎ u a b d e If Not Me.cb_u1.Checked Then Me.S»ç¿ëÀÚ1(0).Visible = False If Not Me.cb_u2.Checked Then Me.S»ç¿ëÀÚ2(0).Visible = False If Not Me.cb_u3.Checked Then Me.S»ç¿ëÀÚ3(0).Visible = False If Not Me.cb_u4.Checked Then Me.S»ç¿ëÀÚ4(0).Visible = False If Not Me.cb_u5.Checked Then Me.S»ç¿ëÀÚ5(0).Visible = False 'ENDTIME = Now ' Me.Text = "°É¸°½Ã°£ = " & (ENDTIME - STARTTIME).ToString 'ÈÞ ³¡³µ´Ù....................................................... AddLog(Admin, "Pewview À©µµ¿ì¸¦ ½ÇÇàÇÕ´Ï´Ù.()", "\Alllog.txt") 'Me.preview_window() If previewWindow Then Me.preview_window() End Sub Public Function ChkNumPattern(ByVal index As Integer) As Int16 AddLog(Admin, "¹øÈ£ÆÐÅÏÀ» üũÇÕ´Ï´Ù. int16À» ¹ÝȯÇÕ´Ï´Ù.()", "\Alllog.txt") If Dv.Count <= 0 Or index < 0 OrElse index > Dv.Count Then 'MsgBox("µ¥ÀÌÅͰ¡ ¾ø°Å³ª À߸øµÈ À妽º ÀÔ´Ï´Ù(" & index & "/" & Me.CustFP1.ActiveSheet.RowCount & ")", MsgBoxStyle.Critical, "È®ÀÎ") Return -1 '//À߸øµÈ À妽º´Â ¸®ÅÏ End If Dim °Ë»ç¹øÈ£ÆÐÅϰ˻ç As Integer = 0 Dim °Ë»ç¹øÈ£ As String °Ë»ç¹øÈ£ = GetSpread(Me.Dv, index, "¹øÈ£1") & GetSpread(Me.Dv, index, "¹øÈ£2") & _ GetSpread(Me.Dv, index, "¹øÈ£3") & GetSpread(Me.Dv, index, "¹øÈ£4") & GetSpread(Me.Dv, index, "¹øÈ£5") If °Ë»ç¹øÈ£.Trim = "" Then Return -1 '//°Ë»ç¹øÈ£ÀÚü¿¡ ¹®Á¦°¡ÀÕÀ»½Ã ¿¡ ¸®ÅÏ Dim Wlen As Short = °Ë»ç¹øÈ£.Length : If Wlen <= 0 Then Return -1 '//¾ø´Â ±Û±Í°¡ ¿ÓÀ»¶§ ÅÏÇØ¹ö¸°´Ù. Dim SRC() As Char = °Ë»ç¹øÈ£.ToCharArray Dim Log As String = "\Parse_°Ë»ç¹øÈ£ÆÐÅÏ.txt" Dim SepPos As Short = °Ë»ç¹øÈ£.IndexOf(";") Dim retval As Integer = 0 ''0Àº Á¤»ó 1Àº ±æÀÌÆÐÅϾøÀ½ 2´Â 3Àº ±æÀÌ+¹®ÀÚ¾øÀ½ '//°Ë»ç¹øÈ£´Â ±æÀÌÆÐÅÏÀ» ÇÏÁö¾Ê°í ¹®ÀÚÆÐÅϸ¸ ÇÑ´Ù. Dim pname As String Dim Arinini As New MyINI2(DrStyle.FILE) Dim PATTERN As String = PATTERN_ENC(°Ë»ç¹øÈ£) '//¸ÕÀú¹®ÀÚ°¡ÀÖ´ÂÁö È®ÀÎÇÑ´Ù. 'MsgBox(°Ë»ç¹øÈ£ & "/" & PATTERN) pname = "JJNUMPATTERNII" & PATTERN Dim Dr() As DataRow Dr = dtpattern.Select("NAME = '" & pname & "DESC'") AddLog(Admin, "¹®ÀÚÆÐÅÏÀÇ Á¸Àç¿©ºÎ = " & Dr.GetUpperBound(0) & ":" & pname, "\Alllog.txt") If Dr.GetUpperBound(0) <> -1 Then '//ÀÖ´Ù. retval += 2 'addlog(admin, "°ü¸®±¸5¹ø ¹®ÀÚ¸¦ ã¾Ò½À´Ï´Ù (" & pname & "DESC" & ")", Log) End If 'If Arinini.Read(pname, "DESC") = vbNullString Then retval += 2 '//ÆÐÅÏÀÌ ¾øÀ¸¹Ç·Î ¹Ù·Î ³Ñ±ä´Ù. pname = "JJNUMPATTERN" & Wlen Dr = dtpattern.Select("NAME = '" & pname & "DESC'") AddLog(Admin, "±æÀÌÆÐÅÏÀÇ Á¸Àç¿©ºÎ = " & Dr.GetUpperBound(0) & ";" & pname, "\Alllog.txt") If Dr.GetUpperBound(0) <> -1 Then '//ÀÖ´Ù. retval += 1 'addlog(admin, "°ü¸®±¸5¹ø ¹®ÀÚ¸¦ ã¾Ò½À´Ï´Ù (" & pname & "DESC" & ")", Log) End If Return retval '// 0ÀÌ ¸®ÅϵɰÍÀÌ´Ù. ÆÐÅÏÀÌ ¸ðµÎ Á¤»óÀ̶õ ¶æÀÌ´Ù End Function Public Sub CLEAR_ITEM(ByVal labels() As MyControlOLEDBv2.MyLabel) WLog2(Auto_Log, "Clear_item div=", "\ÁöÁß(ÄÉÀ̺í¶óº§)¼øÂ÷·Î±×.txt") For i As Short = 0 To labels.GetUpperBound(0) labels(i).MyText = "" labels(i).Visible = False Next End Sub Public Sub GetStyleList() Dim wat As New System.Diagnostics.Stopwatch AddLog(Auto_Log, "GetStyleListÁøÀÔ()", "\ÁöÁß(ÄÉÀ̺í¶óº§)¼øÂ÷·Î±×.txt") '//½ºÅ¸ÀϸíÀ» °¡Á®¿Í¼­ ÄÞº¸¹Ú½º¿¡ Ç¥½ÃÇÕ´Ï´Ù. '//style Æú´õ¾Æ·¡ÀÇ ini ÆÄÀÏÀüü¸¦ ½ºÅ¸ÀÏ À̶óÇÑ´Ù. '//ÆÄÀÏÀ» Àо ¸Þ¸ð¸®¿¡ ÀúÀåÇÑ´Ù. ' Dim Arinini As MyINI Dim CurIdx As Integer = 0 If StyleDir.Exists = False Then StyleDir.Create() Dim StyleCnt As Short = StyleDir.GetFiles("*.ini").GetUpperBound(0) ReDim Common.StyleList(StyleCnt) ReDim Common.PDS(StyleCnt) '//ÆÐÅϵ¥ÀÌÅͼÂÀÇ °¹¼ö¸¦ ÀúÀåÇÑ´Ù Dim Section, Value As New ArrayList Dim SectionIdx As Integer = 0 AddLog(Auto_Log, "GetStyleList(ÆÄÀÏ¿¡¼­ ½ºÅ¸ÀϸñÀ» °¡Á®¿Â´Ù)", "\ÁöÁß(ÄÉÀ̺í¶óº§)¼øÂ÷·Î±×.txt") '//½ºÅ¸ÀÏÆÄÀϸíÀ» Å×ÀÌºí¿¡ ÀÓ½ÃÀúÀåÇÑ´Ù(Àϰý·Î ºÒ·¯¿À±âÀ§ÇÔÀÌ´Ù.) Dim Dt As New System.Data.DataTable : Dt.Columns.Add("ÆÄÀϸí") For Each FI As IO.FileInfo In StyleDir.GetFiles("*.ini") Dt.Rows.Add(FI.FullName) Next wat.Restart() For Each Dr As DataRow In Dt.Select("", "ÆÄÀϸí asc") Dim FileName As String = Dr("ÆÄÀϸí") AddLog(Auto_Log, "ÆÄÀϸí=(" & FileName & ") ÀÇ ½ºÅ¸ÀÏÀ» °¡Á®¿É´Ï´Ù ¸Þ¸ð¸®·Î", "\ÁöÁß¼øÂ÷·Î±×.txt") '//pattern table Common.PDS(CurIdx) = New PatternDS '//default setting Common.StyleList(CurIdx) = New SStyle() Common.StyleList(CurIdx).LoadOK = False Common.StyleList(CurIdx).Desc = String.Empty Common.StyleList(CurIdx).File = String.Empty Console.WriteLine("Getstyle List : GetallSection File=" + FileName) wat.Restart() '//¿©±â¼­´Â ÀڷḦ ÀÐÁö¾Ê°í ¸ñ·Ï¸¸ ó¸®ÇÑ´Ù. 'GetAllsection(FileName, CurIdx) '//ÀÌÆÄÀÏÀÇ Á¤º¸¸¦ Àд´Ù. Common.StyleList(CurIdx).File = FileName Dim ini As New tinyIni(FileName) Common.StyleList(CurIdx).Desc = ini.Read("STYLE", "DESC") Console.WriteLine("Getstyle List : GetallSection + " + wat.ElapsedMilliseconds.ToString() + "ms") wat.Restart() Me.cmb_style.Items.Add(Common.StyleList(CurIdx).Desc) CurIdx += 1 Next wat.Stop() End Sub Private Sub µ¥ÀÌÅÍÅ×ÀÌºí°»½Å() AddLog(Admin, "µ¥ÀÌÅÍÅ×ÀÌºí °»½Å()", "\Alllog.txt") GetAllsection(DrStyle.FILE, Me.cmb_style.SelectedIndex) '//´Ù½Ã¼³Á¤ 170222 DrStyle = Common.PDS(cmb_style.SelectedIndex).TStyle.Rows(0) DtPattern = Common.PDS(cmb_style.SelectedIndex).TPattern End Sub Private Function Prepare_Print() As Boolean '//¹üÀ§³»ÀÇ ÆäÀÌÁö¹øÈ£¿Í ÀÏÄ¡ÇÏ´Â ¹øÈ£¸¦ ã¾Æ¼­ ¹è¿­¿¡ ÇÒ´çÇÑ´Ù. AddLog(Admin, "Func(PrePare_Print) ÀÎ¼â¹øÈ£ ÇÒ´ç Áغñ", "\Alllog.txt") Dim Number As Integer = 0 Dim FindNum As Boolean = False Me.printindex = 0 '//¹è¿­ÀÇ Ã¹¹øÀ¸·Î Ãâ·ÂÀ» ÁغñÇÑ´Ù. 'Me.PrintArray = Nothing '//Ãâ·Â¹øÈ£ ¹è¿­À» ÀúÀåÇÒ °ÍÀÌ´Ù.\ ReDim PrintArray(0) PrintArray(0) = 1 'log = False 'AddLog("==============Ãâ·ÂÁغñÁß==============", True) Me.pDoc.DefaultPageSettings.Margins.Left = 0 'Me.tb_marginx.Text '//ÁÂ,¿ì ¿©¹é ¼³Á¤ Me.pDoc.DefaultPageSettings.Margins.Top = 0 'Me.tb_marginy.Text Me.pDoc.DefaultPageSettings.Landscape = IIf(Me.cmb_landscape.SelectedIndex = 0, False, True) '//°¡·Î,¼¼·Î Ãâ·Â°áÁ¤ '//ÇÁ¸°Å͸íÀÌ ÁöÁ¤µÇ¾îÀÖ´Ù¸é ÇØ´ç ÇÁ¸°Åͷμ³Á¤,¾øÀ¸¸é ±âº»ÇÁ¸°ÅÍ If Me.combobox5.Text <> "" Then Me.pDoc.PrinterSettings.PrinterName = Me.combobox5.Text '//¹üÀ§Àε¥ °ªÀÌ ºñ¾îÀÖÀ¸¸é ÇöÀçÃâ·ÂÀ¸·Î If Me.rad_print_area.Checked AndAlso Me.tb_printrange.Text.Trim = "" Then Me.rad_print_cur.Checked = True If Me.rad_print_repeat.Checked Then If IsNumeric(Me.tb_printrange.Text) = False Then MsgBox("Ãâ·ÂÀå¼ö¿¡ ¼ýÀÚ¸¸ ÀÔ·ÂÇϼ¼¿ä", MsgBoxStyle.Critical, "È®ÀÎ") Return False End If ReDim PrintArray(Val(Me.tb_printrange.Text) - 1) For i As Integer = 0 To Val(Me.tb_printrange.Text) - 1 PrintArray(i) = Me.BindingNavigatorPositionItem.Text - 1 Next End If If Me.rad_print_all.Checked Then '//ÀüüÃâ·ÂÀ̹ǷΠ¹è¿­¿¡ ¸ðµç°ÍÀ» ¸®ÅÏÇÑ´Ù : ¸ðµçµ¥ÀÌÅÍÀÇ ·¹ÄÚµå À妽º¸¦ ÀúÀåÇÑ´Ù. 'MsgBox("rad1") ReDim Me.PrintArray(Me.Dv.Count - 1) For i As Integer = 0 To Dv.Count - 1 Me.PrintArray(i) = i Next End If If Me.rad_print_cur.Checked Then '//ÇöÀçÆäÀÌÁö : ÇöÀ纸°íÀÖ´Ù´Â Æä¿¡ÁöÀÇ ·¹ÄÚµåÀ妽º¸¸ ÀúÀåÇÑ´Ù. 'MsgBox("Rad2" & Me.BindingNavigatorPositionItem.Text - 1) ReDim Me.PrintArray(0) Me.PrintArray(0) = Me.BindingNavigatorPositionItem.Text - 1 '/ÇöÀçÄ«¿îÆ®º¸´Ù 1ÀÛ´Ù ¹è¿­Àº 0ºÎÅÍ ½ÃÀÛÇϱ⋚¹®¿¡ 'Me.printindex = -1 End If '//2007-12-21ÀÏ º¯°æ½ÃÀÛ If Me.rad_print_area.Checked Then '//¹üÀ§ÁöÁ¤ : ÁöÁ¤µÈ¹üÀ§³»ÀÇ ¹øÈ£°ªÀ» °¡Áö°í ÇØ´ç À妽º¸¦ ã¾Æ¼­ ¹è¿­¿¡ ÇÒ´çÇÑ´Ù. 'Dim buff() As String = Me.tb_printrange.Text.Split("/") 'Dim curpos As Integer = 0 'MsgBox("rad3") Dim buff As String = Me.tb_printrange.Text ReDim Me.PrintArray(0) : Me.PrintArray(0) = -1 '//¸ÕÀú -°¡ ÀÖ³ª¾ø³ª ÆÇ´ÜÇØ¼­ ÇÑÆäÀÌÁö¿ëÀÎÁö ¹üÀ§¿ëÀÎÁö ±¸ºÐÇÑ´Ù. If buff.IndexOf("-") >= 0 Then '//¹üÀ§ÀÌ´Ù. Dim SubBuff() As String = buff.Split("-") Dim Sttnum As Integer = CInt(SubBuff(0)) '//½ÃÀÛ Dim endnum As Integer = CInt(SubBuff(1)) '//Á¾·á°ª For SI As Integer = 0 To endnum - Sttnum '//¹üÀ§°¹¼ö¸¸Å­ µ·´Ù FindNum = False Number = CInt(Sttnum + SI) '//ÆäÀÌÁö¸¸ Àû¾ùÀ» °ÍÀ̹ǷΠFor ni As Integer = 0 To Dv.Count - 1 '//ÇöÀçºäÀÇ ¸ðµçµ¥ÀÌÅ͸¦ °¡Áö°í °Ë»öÇÑ´Ù ÁÂ->¿ì ¼øÂ÷°Ë»ö If Number = Dv(ni).Row("¹øÈ£") Then If PrintArray(0) = -1 Then '//óÀ½µ¥ÀÌÅÍÀ̹ǷΠMe.PrintArray(0) = ni Else '//óÀ½À̾ƴϹǷΠ¹è¿­À» Áõ°¡½ÃŰ°í ±âÀÔÇÑ´Ù. ReDim Preserve PrintArray(PrintArray.GetUpperBound(0) + 1) '//¹è¿­1Áõ°¡ Me.PrintArray(PrintArray.GetUpperBound(0)) = ni End If FindNum = True Exit For End If Next Next Else '//ÆäÀÌÁö¹øÈ£¸¸ Àû¾úÀ»¶§´Ù If IsNumeric(buff) Then Number = CInt(buff) '//ÆäÀÌÁö¸¸ Àû¾ùÀ» °ÍÀ̹ǷΠFor ni As Integer = 0 To Dv.Count - 1 '//ÇöÀçºäÀÇ ¸ðµçµ¥ÀÌÅ͸¦ °¡Áö°í °Ë»öÇÑ´Ù ÁÂ->¿ì ¼øÂ÷°Ë»ö If Number = Dv(ni).Row("¹øÈ£") Then PrintArray(0) = ni Exit For End If Next Else MsgBox("¹üÀ§(-)¸¦ Á¦¿ÜÇÏ°í ¼ýÀÚ¸¸ ÀÔ·ÂÇϼ¼¿ä", MsgBoxStyle.Critical, "ÀԷ¿À·ù") End If End If End If If PrintArray(0) = -1 Then '//¹è¿­¿¡ ¾Æ¹«°Íµµ ¾ø´Ù¸é Return False Else Return True End If End Function Private Sub Print_Preview() AddLog(Admin, "print_preview ¹Ì¸®º¸±â ¹öưÀ» ´­·¶À»¶§´Ù.()", "\Alllog.txt") Me.PrintMode = True If Not Prepare_Print() Then MsgBox("ÀμâÇÒ ¸ñ·ÏÀÌ ¾ø½À´Ï´Ù", MsgBoxStyle.Critical, "È®ÀÎ") Return End If Dim Preview As New PrintPreviewDialog() Try Preview.Document = pDoc Preview.ShowDialog() Catch EX As Exception MsgBox(EX.Message) End Try End Sub Private Sub pDoc_PrintPage(ByVal sender As Object, ByVal e As System.Drawing.Printing.PrintPageEventArgs) Handles pDoc.PrintPage AddLog(Admin, "proc_printpage ÇÁ¸°Æ®ÆÐÀÌÁö¸¦ ÀÛ¼ºÇÑ´Ù Áß¿äÇÏ´Ù.()", "\Alllog.txt") Dim fmt As New StringFormat(StringFormatFlags.LineLimit) Dim MyFont As Font Dim NewFontSize As Int16 = 10 Dim dummy As Boolean = False '//À̰ªÀÌ true À̸é Ãâ·Â½Ã º¯À§¸¦ ÁöÁ¤Çؼ­ Ãâ·ÂÇÑ´Ù. Dim C As MyControlOLEDBv2.MyLabel Dim NewLeft, NewTop As Integer 'ÆäÀÌÁö ±¸ºÐÀ» ÀÌÇØÇÏ°í ¸î°³¸¦ ÂïÀ»Áö °áÁ¤ÇÑ´Ù. 'Debug.Print("ÇÁ¸°ÅÍÀ妽º=" & Me.printindex) 'Debug.Print("ÇÁ¸°Å͹迭=" & Me.PrintArray.GetUpperBound(0)) If Me.printindex <> -1 Then If Me.rad_print_repeat.Checked = False Then Me.GeTviewData(Me.PrintArray(Me.printindex), False) '//ÆäÀÌÁö¸¦ °»½ÅÇϰí Ãâ·ÂÀ» ½ÃÀÛÇÑ´Ù. Else MsgBox("ÇÁ¸°Æ® À妽º°¡ ¾ø½À´Ï´Ù", MsgBoxStyle.Critical, "È®ÀÎ") End If e.Graphics.ScaleTransform(Me.tb_scalex.Text, Me.tb_scaley.Text) If Me.Chk_BgImageprint.Checked AndAlso Me.chk_DisplayBG.Checked AndAlso Not Me.bakimg.BackgroundImage Is Nothing Then If Me.PrintMode = False Then '//¹Ì¸®º¸±âÀ϶§ Àμ⸶ÁøÀ» ³ÖÁö¾Ê´Â´Ù. e.Graphics.DrawImage(Me.bakimg.BackgroundImage, CInt(Me.tb_bakx.Text), CInt(Me.tb_baky.Text), CInt(Me.tb_bakw.Text), CInt(Me.tb_bakh.Text)) '//¹è°æ±×¸² Else e.Graphics.DrawImage(Me.bakimg.BackgroundImage, CInt(Me.tb_bakx.Text) + CInt(Me.tb_marginx.Text), CInt(Me.tb_baky.Text) + CInt(Me.tb_marginy.Text), CInt(Me.tb_bakw.Text), CInt(Me.tb_bakh.Text)) '//¹è°æ±×¸² End If End If If Me.chk_draw.Checked Then '//¶óÀÎÀ» ±×¸°´Ù. For Each Rect As S_Line In Draw_Line If Rect.Field <> "" Then Select Case Rect.Field Case "COSÈÞÁî¿ë·®" If Me.ÈÞÁî¿ë·® = "" OrElse Not cb_ÈÞÁî¿ë·®.Checked Then Continue For End If Case "»óÇ¥½ÃÂû1´Ü" If Me.»óÇ¥½ÃÂû1´Ü = "" OrElse Not cb_»ó1´Ü.Checked Then Continue For End If Case "»óÇ¥½ÃÂû2´Ü" If Me.»óÇ¥½ÃÂû2´Ü = "" OrElse Not cb_»ó2´Ü.Checked Then Continue For End If Case "Á¡°ËÀÏÀÚ" If Me.Á¡°ËÀÏÀÚ = "" OrElse Not cb_date.Checked Then Continue For End If Case "¼±·ÎÀü¹æ" If Me.¼±·ÎÀü¹æ = "" Then Continue For End If Case "¼±·ÎÁÂÃø" If Me.¼±·ÎÁÂÃø = "" Then Continue For End If Case "¼±·Î¿ìÃø" If Me.¼±·Î¿ìÃø = "" Then Continue For End If End Select End If Dim Pen As New Drawing.Pen(Rect.PenColor, Rect.PenWidth) If Me.PrintMode Then e.Graphics.DrawLine(Pen, Rect.X + CInt(Me.tb_marginx.Text), Rect.Y + CInt(Me.tb_marginy.Text), Rect.X2 + CInt(Me.tb_marginx.Text), Rect.Y2 + CInt(Me.tb_marginy.Text)) Else e.Graphics.DrawLine(Pen, Rect.X, Rect.Y, Rect.X2, Rect.Y2) End If Next '//¹Ú½º¸¦ ±×¸°´Ù. For Each Rect As S_Box In Draw_Box If Rect.Field <> "" Then Select Case Rect.Field Case "COSÈÞÁî¿ë·®" If Me.ÈÞÁî¿ë·® = "" OrElse Not cb_ÈÞÁî¿ë·®.Checked Then Continue For End If Case "»óÇ¥½ÃÂû1´Ü" If Me.»óÇ¥½ÃÂû1´Ü = "" OrElse Not cb_»ó1´Ü.Checked Then Continue For End If Case "»óÇ¥½ÃÂû2´Ü" If Me.»óÇ¥½ÃÂû2´Ü = "" OrElse Not cb_»ó2´Ü.Checked Then Continue For End If Case "Á¡°ËÀÏÀÚ" If Me.Á¡°ËÀÏÀÚ = "" OrElse Not cb_date.Checked Then Continue For End If Case "¼±·ÎÀü¹æ" If Me.¼±·ÎÀü¹æ = "" Then Continue For End If Case "¼±·ÎÁÂÃø" If Me.¼±·ÎÁÂÃø = "" Then Continue For End If Case "¼±·Î¿ìÃø" If Me.¼±·Î¿ìÃø = "" Then Continue For End If End Select End If Dim Pen As New Drawing.Pen(Rect.PenColor, Rect.PenWidth) If Me.PrintMode Then e.Graphics.DrawRectangle(Pen, Rect.X + CInt(Me.tb_marginx.Text), Rect.Y + CInt(Me.tb_marginy.Text), Rect.Width, Rect.Height) Else e.Graphics.DrawRectangle(Pen, Rect.X, Rect.Y, Rect.Width, Rect.Height) End If Next '//¿ø¸¦ ±×¸°´Ù. For Each Rect As S_Circle In Draw_Circle If Rect.Field <> "" Then Select Case Rect.Field Case "COSÈÞÁî¿ë·®" If Me.ÈÞÁî¿ë·® = "" OrElse Not cb_ÈÞÁî¿ë·®.Checked Then Continue For End If Case "»óÇ¥½ÃÂû1´Ü" If Me.»óÇ¥½ÃÂû1´Ü = "" OrElse Not cb_»ó1´Ü.Checked Then Continue For End If Case "»óÇ¥½ÃÂû2´Ü" If Me.»óÇ¥½ÃÂû2´Ü = "" OrElse Not cb_»ó2´Ü.Checked Then Continue For End If Case "Á¡°ËÀÏÀÚ" If Me.Á¡°ËÀÏÀÚ = "" OrElse Not cb_date.Checked Then Continue For End If Case "¼±·ÎÀü¹æ" If Me.¼±·ÎÀü¹æ = "" Then Continue For End If Case "¼±·ÎÁÂÃø" If Me.¼±·ÎÁÂÃø = "" Then Continue For End If Case "¼±·Î¿ìÃø" If Me.¼±·Î¿ìÃø = "" Then Continue For End If End Select End If Dim Pen As New Drawing.Pen(Rect.PenColor, Rect.PenWidth) If Me.PrintMode Then e.Graphics.DrawEllipse(Pen, Rect.X + CInt(Me.tb_marginx.Text), Rect.Y + CInt(Me.tb_marginy.Text), Rect.Width, Rect.Height) Else e.Graphics.DrawEllipse(Pen, Rect.X, Rect.Y, Rect.Width, Rect.Height) End If Next '//±×¸²À» ±×¸°´Ù. For Each Rect As S_Image In Draw_Image If Rect.Field <> "" Then Select Case Rect.Field Case "COSÈÞÁî¿ë·®" If Me.ÈÞÁî¿ë·® = "" OrElse Not cb_ÈÞÁî¿ë·®.Checked Then Continue For End If Case "»óÇ¥½ÃÂû1´Ü" If Me.»óÇ¥½ÃÂû1´Ü = "" OrElse Not cb_»ó1´Ü.Checked Then Continue For End If Case "»óÇ¥½ÃÂû2´Ü" If Me.»óÇ¥½ÃÂû2´Ü = "" OrElse Not cb_»ó2´Ü.Checked Then Continue For End If Case "Á¡°ËÀÏÀÚ" If Me.Á¡°ËÀÏÀÚ = "" OrElse Not cb_date.Checked Then Continue For End If Case "¼±·ÎÀü¹æ" If Me.¼±·ÎÀü¹æ = "" Then Continue For End If Case "¼±·ÎÁÂÃø" If Me.¼±·ÎÁÂÃø = "" Then Continue For End If Case "¼±·Î¿ìÃø" If Me.¼±·Î¿ìÃø = "" Then Continue For End If End Select End If Dim F As String = Rect.FileName If F.Trim <> "" Then F = F.Replace(".\", My.Application.Info.DirectoryPath & "\") If System.IO.File.Exists(F) Then Dim Image As Image = Image.FromFile(F) If Rect.Width = 0 OrElse Rect.Height = 0 Then ' Ga.DrawImage(Image, Rect.X + MyProperty_Paper.Ãâ·Â¿©¹éX, Rect.Y + MyProperty_Paper.Ãâ·Â¿©¹éY) e.Graphics.DrawImage(Image, Rect.X, Rect.Y) Else ' Ga.DrawImage(Image, Rect.X + MyProperty_Paper.Ãâ·Â¿©¹éX, Rect.Y + MyProperty_Paper.Ãâ·Â¿©¹éY, Rect.Width, Rect.Height) e.Graphics.DrawImage(Image, Rect.X, Rect.Y, Rect.Width, Rect.Height) End If End If End If Next '//È­»ìÇ¥¸¦ ±×¸°´Ù. 170711 For Each Rect As S_Arrow In Draw_Arrow Select Case Rect.Direction Case 0 If Me.¼±·ÎÀü¹æ = "" Then Continue For End If Case 1 If Me.¼±·ÎÁÂÃø = "" Then Continue For End If Case 2 If Me.¼±·Î¿ìÃø = "" Then Continue For End If End Select '//°¢Æ÷ÀÎÆ®¸¦ »ý¼ºÇÑ´Ù. Dim pts As New List(Of Point) If Rect.Direction = 1 Then '//ÁÂÃø pts.Add(New Point(Rect.RectX - Rect.TriWidth, Rect.RectY + Rect.RectH / 2)) pts.Add(New Point(Rect.RectX, Rect.RectY - Rect.TriHeight)) pts.Add(New Point(Rect.RectX, Rect.RectY)) pts.Add(New Point(Rect.RectX + Rect.RectW, Rect.RectY)) pts.Add(New Point(Rect.RectX + Rect.RectW, Rect.RectY + Rect.RectH)) pts.Add(New Point(Rect.RectX, Rect.RectY + Rect.RectH)) pts.Add(New Point(Rect.RectX, Rect.RectY + Rect.RectH + Rect.TriHeight)) pts.Add(New Point(Rect.RectX - Rect.TriWidth, Rect.RectY + Rect.RectH / 2)) ElseIf Rect.Direction = 2 Then '//¿ìÃø pts.Add(New Point(Rect.RectX, Rect.RectY)) pts.Add(New Point(Rect.RectX + Rect.RectW, Rect.RectY)) pts.Add(New Point(Rect.RectX + Rect.RectW, Rect.RectY - Rect.TriHeight)) pts.Add(New Point(Rect.RectX + Rect.RectW + Rect.TriWidth, Rect.RectY + Rect.RectH / 2)) pts.Add(New Point(Rect.RectX + Rect.RectW, Rect.RectY + Rect.RectH + Rect.TriHeight)) pts.Add(New Point(Rect.RectX + Rect.RectW, Rect.RectY + Rect.RectH)) pts.Add(New Point(Rect.RectX, Rect.RectY + Rect.RectH)) pts.Add(New Point(Rect.RectX, Rect.RectY)) ElseIf Rect.Direction = 0 Then '//Àü¹æ pts.Add(New Point(Rect.RectX, Rect.RectY + Rect.RectH)) pts.Add(New Point(Rect.RectX, Rect.RectY)) pts.Add(New Point(Rect.RectX - Rect.TriWidth, Rect.RectY)) pts.Add(New Point(Rect.RectX + Rect.RectW / 2, Rect.RectY - Rect.TriHeight)) pts.Add(New Point(Rect.RectX + Rect.RectW + Rect.TriWidth, Rect.RectY)) pts.Add(New Point(Rect.RectX + Rect.RectW, Rect.RectY)) pts.Add(New Point(Rect.RectX + Rect.RectW, Rect.RectY + Rect.RectH)) pts.Add(New Point(Rect.RectX, Rect.RectY + Rect.RectH)) End If If Me.PrintMode Then For i As Integer = 0 To pts.Count - 1 Dim pt As Point = pts(i) pt.X += CInt(Me.tb_marginx.Text) pts(i) = pt Next ' e.Graphics.DrawEllipse(Pen, Rect.X + CInt(Me.tb_marginx.Text), Rect.Y + CInt(Me.tb_marginy.Text), Rect.Width, Rect.Height) End If Dim Pen As New Drawing.SolidBrush(Rect.PenColor) e.Graphics.FillPolygon(Pen, pts.ToArray()) Next If °ü¸®±¸ <> "" Then '//QRÄڵ带 ±×¸°´Ù. For Each Rect As S_QRCode In Draw_QRcode 'Dim scale As Int16 Dim version As Int16 Dim image As Image Dim data As String Dim errorCorrect As String Dim qrCodeEncoder1 As New QRCodeEncoder() Dim encoding As String encoding = cboEncoding.Text If encoding = "3" Then qrCodeEncoder1.QRCodeEncodeMode = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ENCODE_MODE.BYTE ElseIf encoding = "1" Then qrCodeEncoder1.QRCodeEncodeMode = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ENCODE_MODE.ALPHA_NUMERIC ElseIf encoding = "2" Then qrCodeEncoder1.QRCodeEncodeMode = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ENCODE_MODE.NUMERIC Try version = Convert.ToInt16(cboVersion.Text) qrCodeEncoder1.QRCodeVersion = version Catch ex As Exception MessageBox.Show("Invaild Version!") End Try End If errorCorrect = cboCorrectionLevel.Text If errorCorrect = "1" Then qrCodeEncoder1.QRCodeErrorCorrect = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ERROR_CORRECTION.L ElseIf errorCorrect = "2" Then qrCodeEncoder1.QRCodeErrorCorrect = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ERROR_CORRECTION.M ElseIf errorCorrect = "3" Then qrCodeEncoder1.QRCodeErrorCorrect = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ERROR_CORRECTION.Q ElseIf errorCorrect = "4" Then qrCodeEncoder1.QRCodeErrorCorrect = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ERROR_CORRECTION.H End If qrȨÆäÀÌÁö1 = home1.Text qrȨÆäÀÌÁö2 = home2.Text qrȨÆäÀÌÁö3 = home3.Text qrȨÆäÀÌÁö4 = home4.Text Try 'data = q½Ã°øÀÚ & qȨÆäÀÌÁö & q°ü¸® & q°ü¸®1 & q°ü¸®2 data = qrȨÆäÀÌÁö1 & "/" & qrȨÆäÀÌÁö2 & "/" & qrȨÆäÀÌÁö3 & "/" & qrȨÆäÀÌÁö4 & "=" & °ü¸®±¸ & "-" & Àü»ê¹øÈ£ & "&name=" & ½Å¼±·ÎÀüÁÖ¹øÈ£ & ":" & Àåô & "M" ' ½Ã°øÀÚ: " & ½Ã°øÀÚ & " °¨µ¶ÀÚ : " & °¨µ¶ÀÚ If lbQrBg.BackColor <> Drawing.Color.White Then qrCodeEncoder1.QRCodeBackgroundColor = lbQrBg.BackColor If lbQrFG.BackColor <> Drawing.Color.Black Then qrCodeEncoder1.QRCodeForegroundColor = lbQrFG.BackColor image = qrCodeEncoder1.Encode(data, e.Graphics.DpiX, e.Graphics.DpiY) 'MessageBox.Show("±¸°ü¸®±¸ : " & ±¸°ü¸®±¸ & "±¸Àü»ê¹øÈ£ : " & ±¸Àü»ê¹øÈ£ & "°ü¸®±¸ : " & °ü¸®±¸ & "Àü»ê¹øÈ£ : " & Àü»ê¹øÈ£ & "¼±·Î¸í : " & ¼±·Î¸í & "¹øÈ£ : " & ¹øÈ£ & "Àåô : " & Àåô & "½Ã°ø³â¿ù : " & ½Ã°ø³â¿ù & "½Ã°øÀå : " & ½Ã°øÀÚ & "°¨µ¶ÀÚ : " & °¨µ¶ÀÚ & "Á¡°ËÀÏÀÚ : " & Á¡°ËÀÏÀÚ & "Á¢Áö1 : " & Á¢Áö1 & "Á¢Áö2 : " & Á¢Áö2 & "DI¸í : " & Dl¸í & "º»ÁÖ¹øÈ£ : " & º»ÁÖ¹øÈ£ & "º»ÁÖÀüÁÖ¹øÈ£ : " & º»ÁÖÀüÁÖ¹øÈ£ & "ÀüÁÖ¹øÈ£ÇÑÁÙ : " & ÀüÁÖ¹øÈ£ÇÑÁÙ & "±¸°ü¼±·ÎÀüÁÖ¹øÈ£ : " & ±¸¼±·ÎÀüÁÖ¹øÈ£ & "½Å¼­·ÎÀüÁÖ¹øÈ£ : " & ½Å¼±·ÎÀüÁÖ¹øÈ£ & "±¸¼±·Î¸í : " & ±¸¼±·Î¸í & "±¸ÀüÁÖ¹øÈ£ : " & ±¸ÀüÁÖ¹øÈ£) 'À§ÀÇ MBOX´Â ¾î¶² Ç׸ñÀÎÁö¸¦ È®ÀÎÇϱâ À§ÇÔÀÌ´Ù.. If Me.PrintMode Then e.Graphics.DrawImage(image, Rect.X + CInt(Me.tb_marginx.Text), Rect.Y + CInt(Me.tb_marginy.Text), Rect.Width, Rect.Height) Else e.Graphics.DrawImage(image, Rect.X, Rect.Y, Rect.Width, Rect.Height) End If Catch ex As Exception MessageBox.Show("QRÄڵ带 ±×¸®´Âµ¥ ±×¸®·Á´Â DATA°¡ ¼ýÀÚÀÎÁö ¿µ¼ýÀÚÀÎÁö ¸ðµÎÀÎÁö È®ÀÎ ÈÄ ¼±ÅÃÇÏ¿© ÁÖ¼¼¿ä") End Try ' If Rect.Width = 0 OrElse Rect.Height = 0 Then ' Ga.DrawImage(Image, Rect.X + MyProperty_Paper.Ãâ·Â¿©¹éX, Rect.Y + MyProperty_Paper.Ãâ·Â¿©¹éY) 'e.Graphics.DrawImage(image, Rect.X + CInt(Me.tb_marginx.Text), Rect.Y + CInt(Me.tb_marginy.Text)) 'Else ' Ga.DrawImage(Image, Rect.X + MyProperty_Paper.Ãâ·Â¿©¹éX, Rect.Y + MyProperty_Paper.Ãâ·Â¿©¹éY, Rect.Width, Rect.Height) 'e.Graphics.DrawImage(image, Rect.X, Rect.Y, Rect.Width, Rect.Height) 'End If Next End If End If For Each Rect As S_QRCode1 In Draw_QRcode1 'Dim scale As Int16 Dim version As Int16 Dim image As Image Dim data As String Dim errorCorrect As String Dim qrCodeEncoder1 As New QRCodeEncoder() Dim encoding As String encoding = cboEncoding.Text If encoding = "3" Then qrCodeEncoder1.QRCodeEncodeMode = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ENCODE_MODE.BYTE ElseIf encoding = "1" Then qrCodeEncoder1.QRCodeEncodeMode = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ENCODE_MODE.ALPHA_NUMERIC ElseIf encoding = "2" Then qrCodeEncoder1.QRCodeEncodeMode = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ENCODE_MODE.NUMERIC Try version = Convert.ToInt16(cboVersion.Text) qrCodeEncoder1.QRCodeVersion = version Catch ex As Exception MessageBox.Show("Invaild Version!") End Try End If errorCorrect = cboCorrectionLevel.Text If errorCorrect = "1" Then qrCodeEncoder1.QRCodeErrorCorrect = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ERROR_CORRECTION.L ElseIf errorCorrect = "2" Then qrCodeEncoder1.QRCodeErrorCorrect = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ERROR_CORRECTION.M ElseIf errorCorrect = "3" Then qrCodeEncoder1.QRCodeErrorCorrect = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ERROR_CORRECTION.Q ElseIf errorCorrect = "4" Then qrCodeEncoder1.QRCodeErrorCorrect = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ERROR_CORRECTION.H End If rqr±âŸ1 = gita1.Text rqr±âŸ2 = gita2.Text rqr±âŸ3 = gita3.Text rqr±âŸ4 = gita4.Text Try 'data = q½Ã°øÀÚ & qȨÆäÀÌÁö & q°ü¸® & q°ü¸®1 & q°ü¸®2 If rqr±âŸ1 <> "" And rqr±âŸ2 <> "" And rqr±âŸ3 <> "" And rqr±âŸ4 <> "" Then data = rqr±âŸ1 & "/" & rqr±âŸ2 & "/" & rqr±âŸ3 & "/" & rqr±âŸ4 ElseIf rqr±âŸ1 <> "" And rqr±âŸ2 <> "" And rqr±âŸ3 <> "" Then data = rqr±âŸ1 & "/" & rqr±âŸ2 & "/" & rqr±âŸ3 ElseIf rqr±âŸ1 <> "" And rqr±âŸ2 <> "" Then data = rqr±âŸ1 & "/" & rqr±âŸ2 ElseIf rqr±âŸ1 <> "" Then data = rqr±âŸ1 Else data = rqr±âŸ1 & "/" & rqr±âŸ2 & "/" & rqr±âŸ3 & "/" & rqr±âŸ4 End If If lbQrBg.BackColor <> Drawing.Color.White Then qrCodeEncoder1.QRCodeBackgroundColor = lbQrBg.BackColor If lbQrFG.BackColor <> Drawing.Color.Black Then qrCodeEncoder1.QRCodeForegroundColor = lbQrFG.BackColor image = qrCodeEncoder1.Encode(data, e.Graphics.DpiX, e.Graphics.DpiY) 'MessageBox.Show("±¸°ü¸®±¸ : " & ±¸°ü¸®±¸ & "±¸Àü»ê¹øÈ£ : " & ±¸Àü»ê¹øÈ£ & "°ü¸®±¸ : " & °ü¸®±¸ & "Àü»ê¹øÈ£ : " & Àü»ê¹øÈ£ & "¼±·Î¸í : " & ¼±·Î¸í & "¹øÈ£ : " & ¹øÈ£ & "Àåô : " & Àåô & "½Ã°ø³â¿ù : " & ½Ã°ø³â¿ù & "½Ã°øÀå : " & ½Ã°øÀÚ & "°¨µ¶ÀÚ : " & °¨µ¶ÀÚ & "Á¡°ËÀÏÀÚ : " & Á¡°ËÀÏÀÚ & "Á¢Áö1 : " & Á¢Áö1 & "Á¢Áö2 : " & Á¢Áö2 & "DI¸í : " & Dl¸í & "º»ÁÖ¹øÈ£ : " & º»ÁÖ¹øÈ£ & "º»ÁÖÀüÁÖ¹øÈ£ : " & º»ÁÖÀüÁÖ¹øÈ£ & "ÀüÁÖ¹øÈ£ÇÑÁÙ : " & ÀüÁÖ¹øÈ£ÇÑÁÙ & "±¸°ü¼±·ÎÀüÁÖ¹øÈ£ : " & ±¸¼±·ÎÀüÁÖ¹øÈ£ & "½Å¼­·ÎÀüÁÖ¹øÈ£ : " & ½Å¼±·ÎÀüÁÖ¹øÈ£ & "±¸¼±·Î¸í : " & ±¸¼±·Î¸í & "±¸ÀüÁÖ¹øÈ£ : " & ±¸ÀüÁÖ¹øÈ£) 'À§ÀÇ MBOX´Â ¾î¶² Ç׸ñÀÎÁö¸¦ È®ÀÎÇϱâ À§ÇÔÀÌ´Ù.. If Me.PrintMode Then e.Graphics.DrawImage(image, Rect.X + CInt(Me.tb_marginx.Text), Rect.Y + CInt(Me.tb_marginy.Text), Rect.Width, Rect.Height) Else e.Graphics.DrawImage(image, Rect.X, Rect.Y, Rect.Width, Rect.Height) End If Catch ex As Exception MessageBox.Show("QRÄڵ带 ±×¸®´Âµ¥ ±×¸®·Á³ª´Â DATA°¡ ¼ýÀÚÀÎÁö ¿µ¼ýÀÚÀÎÁö ¸ðµÎÀÎÁö È®ÀÎ ÈÄ ¼±ÅÃÇÏ¿© ÁÖ¼¼¿ä") End Try Next '//¿¬¼ÓÆäÀÌÁö ¿À·ùÁ¤Á¤ If Me.tb_pagerepeat.Text = "" Or Me.tb_pagerepeat.Text < 1 Then Me.tb_pagerepeat.Text = "1" For pi As Short = 0 To Me.tb_pagerepeat.Text - 1 '//ÆäÀÌÁö´ç ¿¬¼ÓÃâ·ÂÇÒ È½¼ö For i As Integer = 0 To Me.AllLabels.GetUpperBound(0) C = Me.AllLabels(i).ctl If C.Visible = True AndAlso C.MyText <> "" Then For rcnt As Short = 0 To C.Repeat '//¹Ýº¹±â´ÉÃß°¡ '//myfont ´Â ±Û²ÃÀÇ ÀϰýÅ©±âº¯°æ ¿É¼ÇÀÇÀÇÇØ¼­ »ý¼ºµÊ NewFontSize = C.MyFont.Size + Me.tb_myfontsize.Text If NewFontSize < 0 Then NewFontSize = 0 MyFont = New Font(C.MyFont.FontFamily, NewFontSize, C.MyFont.Style) NewLeft = C.Left + IIf(Me.PrintMode, Me.tb_marginx.Text, 0) + Me.tb_secX.Text * pi + rcnt * C.RepeatX NewTop = C.Top + IIf(Me.PrintMode, Me.tb_marginy.Text, 0) + Me.tb_secY.Text * pi + rcnt * C.RepeatY If C.ÀåÆò = 100 AndAlso C.Àå³ôÀÌ = 100 Then '//ÀåÆò¹Ì»ç¿ë ¹®ÀÚ¿­ ó¸® e.Graphics.DrawString(C.ÃÖÁ¾¹®ÀÚ, MyFont, Brushes.Black, New Point(NewLeft, NewTop)) Else '//ÀåÆò»ç¿ë À̹ÌÁö ó¸® Dim NewX, Newy As Integer Dim SrcDpix, SrcDPiY As Single 'MsgBox(Tobj.Àå³ôÀÌ) SrcDpix = C.CreateGraphics.DpiX SrcDPiY = C.CreateGraphics.DpiY NewX = C.GetSize(MyFont).Width * (C.ÀåÆò / 100) * (e.Graphics.DpiX / SrcDpix) Newy = C.GetSize(MyFont).Height * (C.Àå³ôÀÌ / 100) * (e.Graphics.DpiY / SrcDPiY) Dim BMP As New Bitmap(NewX, Newy, e.Graphics) Dim G As Graphics = Graphics.FromImage(BMP) G.ScaleTransform((C.ÀåÆò / 100), (C.Àå³ôÀÌ / 100)) G.DrawString(C.ÃÖÁ¾¹®ÀÚ, MyFont, Brushes.Black, 0, 0) G.Dispose() e.Graphics.DrawImage(BMP, New Point(NewLeft, NewTop)) ', CInt(GetSize.Width * (vÀåÆò / 100)), GetSize.Height) End If Next End If Next '//Çѵ¥ÀÌÅÍÃâ·ÂÇÏ°í³ª¼­ ¹Ýº¹Æä¿¡ÁöȽ¼ö°¡ ÀÖ´ÂÁöÈ®ÀÎÇÑ´Ù. If Me.tb_pagerepeat.Text > 1 Then ' If Me.cmb_dummy.SelectedIndex <> 0 Then '//´ÙÀ½µ¥ÀÌÅÍÀÇ Ãâ·ÂÀÌ¸é ¿©±â¼­ µ¥ÀÌÅ͸¦ °»½ÅÇØÁØ´Ù. If Me.cmb_dummy.SelectedIndex <> 0 Then '//´ÙÀ½ÀåÀÌÀÖ´Ù. If Me.printindex >= 0 AndAlso Me.printindex < Me.PrintArray.GetUpperBound(0) Then '//·çÇÁ°¡ ³¡³´´ÂÁö Ãß°¡Ã¼Å©ÇÑ´Ù. 170308 If pi < Me.tb_pagerepeat.Text - 1 Then Me.printindex += 1 '/1Àå³Ñ±â°í If Me.cmb_dummy.SelectedIndex <> 0 AndAlso Me.rad_print_repeat.Checked = False Then ' MsgBox("´ÙÀ½µ¥ÀÌÅͰ»½Å") Me.GeTviewData(Me.PrintArray(Me.printindex), False) '//µ¥ÀÌÅÍ ¹Ù²Ù´Âµ¥..È­¸éÀº °»½ÅÇÏÁö ¾Ê´Â´Ù. End If End If Else '//´ÙÀ½ÀåÀÇ Ãâ·ÂÀε¥ µ¥ÀÌÅͰ¡¾ø´Ù¸é ·çÇÁ¸¦ ´õÀÌ»ó µ¹¸é¾ÈµÈ´Ù. Exit For End If End If End If Next '//pi ¹Ýº¹ÇҰŸ¦ ¸ðµÎ Ãâ·ÂÇßÀ»½Ã¿¡ If Me.printindex >= 0 AndAlso Me.printindex < Me.PrintArray.GetUpperBound(0) Then '//´ÙÀ½ÀåÀÌÀÖ´Ù. If Me.tb_pagerepeat.Text < 2 Then Me.printindex += 1 '//ÆäÀÌÁö¹øÈ£¸¦ Áõ°¡ Else Me.printindex += 1 End If e.HasMorePages = True Else e.HasMorePages = False End If e.Graphics.Dispose() End Sub Private Sub Print() If MsgBox("Àμ⸦ ÇϽðڽÀ´Ï±î?", MsgBoxStyle.Information + MsgBoxStyle.OkCancel, "È®ÀÎ") = MsgBoxResult.Ok Then AddLog(Admin, "print ¹Ù·Î Ãâ·ÂÀ» Ç϶ó´Â ¸í·ÉÀÌ´Ù()", "\Alllog.txt") Me.PrintMode = True If Me.Prepare_Print() Then pDoc.Print() GeTviewData(BindingSource1.Position, True) ' preview_window() Else MsgBox("ÀμⰡ´ÉÇÑ ¸ñ·ÏÀÌ ¾ø½À´Ï´Ù", MsgBoxStyle.Critical, "È®ÀÎ") End If Else NOTICE("ÀμⰡ Ãë¼ÒµÇ¾ú½À´Ï´Ù", Drawing.Color.Tomato, Me.lb_msg) End If End Sub Private Sub con_Mmove(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) AddLog(Admin, "con _move °³Ã¼À̵¿ÇÒ ÇÁ·Î½ÃÁ®Àε¥ ÇöÀç ¾È¾´´Ù.()", "\Alllog.txt") If My.Computer.Keyboard.CtrlKeyDown AndAlso e.Button = System.Windows.Forms.MouseButtons.Left Then ' Me.Text = CType(sender, Label).Left & "/" & e.X CType(sender, MyControlOLEDBv2.MyLabel).Left += e.X CType(sender, MyControlOLEDBv2.MyLabel).Top += e.Y End If End Sub '''¿ìÃø¿¡ °³Ã¼ÀÇ »óŸ¦ º¸¿©ÁÝ´Ï´Ù. ''' Public Sub ViewProperty(ByVal sender As MyControlOLEDBv2.MyLabel) AddLog(Admin, "view properfty °³Ã¼ÀÇ »óꏱâ()", "\Alllog.txt") If Not Me.GroupBox2.Enabled Then Me.GroupBox2.Enabled = True Me.TB_FONTNAME.Text = sender.MyFont.Name.ToString Me.tb_left.Text = sender.Left Me.tb_top.Text = sender.Top Me.tb_foncol.BackColor = sender.MyForeColor Me.cb_visible.Checked = sender.Visible Me.cb_bold.Checked = sender.MyFont.Bold 'Me.cb_italic.Checked = sender.MyFont.Italic ' Me.cb_uline.Checked = sender.MyFont.Underline Me.tb_fsize.Text = sender.MyFont.Size Me.tb_wordwidth.Text = sender.ÀåÆò Me.tb_wordheight.Text = sender.Àå³ôÀÌ Me.tb_space.Text = sender.°ø¹é Me.tb_rep.Text = sender.Repeat.ToString Me.tb_repx.Text = sender.RepeatX.ToString Me.tb_repy.Text = sender.RepeatY.ToString Me.GroupBox2.Text = "À§Ä¡/Å©±â/±Û²Ã(" & sender.MyText & ") W=" & sender.GetSize.Width & ",H=" & sender.GetSize.Height If Not sender.Tag Is Nothing Then '//¿©±â¼­ °³Ã¼ÀÇ ÆÐÅÏÀû¿ë¿©ºÎ¸¦ Ç¥½ÃÇÕ´Ï´Ù. ' MsgBox(sender.Tag.ToString) Me.lb_countpattern.ForeColor = IIf(sender.Tag.ToString.IndexOf("L") >= 0, Drawing.Color.Green, Drawing.Color.Black) Me.lb_strpattern.ForeColor = IIf(sender.Tag.ToString.IndexOf("C") >= 0, Drawing.Color.Green, Drawing.Color.Black) 'Me.CB_LPATTERN.Checked = IIf(sender.Tag.ToString.IndexOf("L") >= 0, True, False) 'Me.CB_CHARPATTERN.Checked = IIf(sender.Tag.ToString.IndexOf("C") >= 0, True, False) Else Me.lb_countpattern.ForeColor = Drawing.Color.Black Me.lb_strpattern.ForeColor = Drawing.Color.Black End If End Sub Private Sub ViewBackImage() WLog2(Auto_Log, "viewBackImage ¹è°æÀ̹ÌÁö¸¦ Ç¥½ÃÇÕ´Ï´Ù.()", "\Á¤¾×µî¼øÂ÷·Î±×.txt") Dim Picimg As String If Me.tb_picfile.Text.IndexOf(":") > -1 Then '//µå¶óÀ̺ê¸íÀÌ ÀÖÀ¸¸é ±×´ë·Î¾²°í ¾Æ´Ï¸é ºÙ¿©¼­¾´´Ù. Picimg = Me.tb_picfile.Text Else Picimg = My.Application.Info.DirectoryPath & "\image\" & Me.tb_picfile.Text End If If Not System.IO.File.Exists(Picimg) Then Me.chk_DisplayBG.Checked = False ElseIf Me.chk_DisplayBG.Checked Then Me.PictureBox1.BackgroundImage = Image.FromFile(Picimg) End If End Sub Private Sub CheckBox4_CheckedChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles chk_DisplayBG.CheckedChanged AddLog(Admin, "¹è°æº¸±â üũ¹Ú½º¸¦ Ŭ¸¯Çß´Ù.)", "\Alllog.txt") 'Me.PictureBox1.Visible = IIf(CType(sender, CheckBox).Checked, True, False) If CType(sender, System.Windows.Forms.CheckBox).Checked Then Me.ViewBackImage() Else Me.PictureBox1.BackgroundImage = Nothing End If End Sub Private Sub Label11_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Label11.Click Dim A As New OpenFileDialog AddLog(Admin, "ÆÄÀÏã±â ¹öưÀÌ Å¬¸¯µÊ", "\Alllog.txt") If System.IO.File.Exists(Me.tb_picfile.Text) Then A.FileName = Me.tb_picfile.Text Else A.FileName = My.Application.Info.DirectoryPath & "\image\normal.jpg" End If If A.ShowDialog() <> System.Windows.Forms.DialogResult.OK Then Return Me.tb_picfile.Text = A.FileName Me.chk_DisplayBG.Checked = True Me.ViewBackImage() '//¹è°æÀÌ“GÇ¥½Ã End Sub Public Sub CtrPos(ByVal vertical As Boolean, ByVal offset As Short) AddLog(Admin, "ctrpos (¼±ÅÃµÈ °³Ã¼µéÀÇ À§Ä¡°ªÀ» º¯°æÇÕ´Ï´Ù)", "\Alllog.txt") If SelCon Is Nothing OrElse SelCon.Count < 1 Then Exit Sub For Each sender As Control In SelCon If vertical Then '//Á¿ìÃø If My.Computer.Keyboard.CtrlKeyDown Then If offset < 0 Then sender.Top -= 10 Else sender.Top += 10 End If Else sender.Top += offset End If Else '//»óÇÏÃø If My.Computer.Keyboard.CtrlKeyDown Then If offset < 0 Then sender.Left -= 10 Else sender.Left += 10 End If Else sender.Left += offset End If End If Next AddLog(Admin, "ctrpos =[ preview È£ÃâÇÕ´Ï´Ù]", "\Alllog.txt") Me.preview_window() 'Me.ViewProperty(sender) End Sub Private Sub ShowMsg(ByVal Message As String) AddLog(Admin, "showmsg ¸Þ¼¼Áö¸¦ º¸¿©ÁÝ´Ï´Ù =" & Message, "\Alllog.txt") Me.lb_msg.Text = "¢¹ " & Message & Space(1) & TimeOfDay.ToString End Sub Public Sub SetFont() '//üũ¹Ú½º »óÅ¿¡µû¶ó¼­ ÆùÆ®¸¦ º¯°æÇÕ´Ï´Ù. AddLog(Admin, "set font üũ¹Ú½º »óÅ¿¡ µû¶ó¼­ ÆùÆ®¸¦ º¯°æÇÕ´Ï´Ù.", "\Alllog.txt") Dim B As System.Drawing.FontStyle If Me.cb_bold.Checked = True Then B = FontStyle.Bold Dim Tobj As MyControlOLEDBv2.MyLabel For Each A As Control In SelCon Tobj = CType(A, MyControlOLEDBv2.MyLabel) Tobj.MyFont = New Font(Tobj.MyFont, B) Next AddLog(Admin, "setfont = preview È£ÃâÇÕ´Ï´Ù.", "\Alllog.txt") Me.preview_window() End Sub Private Sub cmb_style_KeyUp(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles cmb_style.KeyUp AddLog(Admin, "½ºÅ¸ÀÏÄÞº¸¹Ú½º¿¡¼­ keyip ÀÌ °¨ÁöµÇ¾úÀ¸³ª ÇÚµéÀ» true ·Î ÇØ¹ö¸°´Ù.", "\Alllog.txt") e.Handled = True End Sub Private Sub cmb_style_MouseUp(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles cmb_style.MouseUp End Sub Private Sub cmb_style_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles cmb_style.SelectedIndexChanged Dim wat As New System.Diagnostics.Stopwatch wat.Restart() AddLog(Admin, "¡æ Change : Style Index...", "\Alllog.txt") If Me.cmb_style.SelectedIndex < 0 Then Me.cmb_style.SelectedIndex = 0 Console.WriteLine("style index changed") '//½ºÅ¸ÀÏÀÌ ·ÎµùµÇÁö ¾Ê¾Ò´Ù¸é ·ÎµùÀ» ¸ÕÀúÇÑ´Ù. If Not Common.StyleList(cmb_style.SelectedIndex).LoadOK Then GetAllsection(Common.StyleList(cmb_style.SelectedIndex).File, cmb_style.SelectedIndex) Common.StyleList(cmb_style.SelectedIndex).LoadOK = True End If DrStyle = Common.PDS(Me.cmb_style.SelectedIndex).TStyle.Rows(0) DtPattern = Common.PDS(Me.cmb_style.SelectedIndex).TPattern Dim DataFilter As String = DrStyle.FILTER If DataFilter.Trim = "" Then DataFilter = "Ãâ·Â = true" '//ÀμâÇʵå´Â Áö¼±ÁÖ ±¸ºÐ¿ëÀ¸·Î Àç»ç¿ëÇÑ´Ù. Else DataFilter &= " AND Ãâ·Â = true" '//Áö¼±ÁÖ´Â ÀμⰡ True °ªÀ̱⶧¹®¿¡ ÇØ´ç °ªÀ» Á¦¿ÜÇÑ´Ù End If Console.WriteLine("Style Index Changed :: filter=" + DataFilter) Me.BindingSource1.Sort = "" Me.BindingSource1.DataSource = Nothing Dv = New DataView(srcTable, DataFilter, "Á¤·Ä¹øÈ£,¹øÈ£", DataViewRowState.CurrentRows) Dim AlphaPos As Short = 0 If Me.cmb_style.Text.IndexOf("Áß±Ô°Ý") >= 0 Then 'MsgBox("Á߱԰ݼ­Žœ¤·") Dim Fullnum As String Dim TDT As DataTable = Dv.ToTable For Each DR As DataRow In TDT.Rows '//°¢ÇàÀÇ °ªÀ» °¡Áö°í ÆÇ´ÜÇÑ´Ù. Fullnum = CStr(DR("¹øÈ£1") & DR("¹øÈ£2") & DR("¹øÈ£3") & DR("¹øÈ£4") & DR("¹øÈ£5")).Trim If Fullnum.Length = 6 Then '//Áï 6ÀÚ¸®Àϰæ¿ì¿¡ ÆÇ´ÜÇÑ´Ù. '//¿¡¸¦µé¾î 34R213 ÀÌ·±°æ¿ìÀÌ´Ù Ç㳪 34R1R2ÀÌ·±°æ¿ìµµÀÖ°í 1R1231 ±×·³ µÚ¿¡¼­ºÎÅÍ ¹ß°ßµÈ ¾ËÆÄºª´ÙÀ½À¸·Î 3ÀÚ¸®°¡ ÀÕÀ¸¸é¾ÈµÈ´Ù. '//asc °¡ 57º¸´ÙÅ©¸é ¾ËÆÄºªÀ̶óÇÑ´Ù. For i As Integer = 0 To Fullnum.ToCharArray.GetUpperBound(0) If Asc(Fullnum.ToCharArray()(i)) > 57 Then AlphaPos = i '//¿©±â¼­ ¸¶Áö¸· ¾ËÆÄºªÀÇ À§Ä¡°¡ Á¤ÇØÁø´Ù. Next DR("±âÀÔ") = IIf(AlphaPos <= 2, True, False) Else DR("±âÀÔ") = True End If Next Dv = New DataView(TDT, "", "Á¤·Ä¹øÈ£,¹øÈ£", DataViewRowState.CurrentRows) ElseIf Me.cmb_style.Text.IndexOf("ȰÀÔÁÖ") >= 0 Then '//ȰÀÔÁÖ´Â H¿ÜÀÇ ¾ËÆÄºªÀÌ ÀÖÀ¸¸é¾ÈµÇ´Â H°¡ µé¾î°£°Å´Ù Dim Fullnum As String Dim TDT As DataTable = Dv.ToTable For Each DR As DataRow In TDT.Rows '//°¢ÇàÀÇ °ªÀ» °¡Áö°í ÆÇ´ÜÇÑ´Ù. Fullnum = CStr(DR("¹øÈ£1") & DR("¹øÈ£2") & DR("¹øÈ£3") & DR("¹øÈ£4") & DR("¹øÈ£5")).ToUpper.Trim If Fullnum.IndexOf("H") >= 0 Then '//ÀÏ´Ü H °¡ ÀÖ¾î¾ßÇÑ´Ù. DR("±âÀÔ") = True For i As Integer = 0 To Fullnum.ToCharArray.GetUpperBound(0) If Asc(Fullnum.ToCharArray()(i)) > 57 AndAlso Fullnum.ToCharArray()(i) <> "H" Then '//¹®ÀÚÀε¥ H °¡¾Æ´Ï¸é false DR("±âÀÔ") = False Exit For End If Next Else DR("±âÀÔ") = False End If Next Dv = New DataView(TDT, "±âÀÔ=true", "Á¤·Ä¹øÈ£,¹øÈ£", DataViewRowState.CurrentRows) End If 'ÇÊÅ͸¦ Àû¿ëÇØ¼­ ºä¸¦ ±¸¼ºÇÑ´ÙÀ½¿¡ ÇØ´ç ºä¸¦ µ¥ÀÌÅͼҽº·Î º¯°æÇÑ´Ù. Me.SaveReadLayOut(True) Me.SaveDrawData(True) Console.WriteLine("Change Style Áغñ½Ã°£ : " + wat.ElapsedMilliseconds.ToString() + "ms") If Dv.Count <= 0 Then '//µ¥ÀÌÅͰ¡¾ø´Ù¸é MsgBox(Me.cmb_style.Text & "¿¡ ÇØ´çÇÏ´Â µ¥ÀÌÅͰ¡Á¸ÀçÇÏÁö ¾Ê½À´Ï´Ù" & vbCrLf & vbCrLf & "´Ù¸¥ ½ºÅ¸ÀÏÀ» ¼±ÅÃÇϼ¼¿ä", MsgBoxStyle.Information, "È®ÀÎ") Me.PictureBox1.Refresh() Else AddLog(Admin, "FindData : Count = " & Dv.Count, "\Alllog.txt") Me.TB_Pattern_End.Text = Dv.Count - 1 '//ÆÐÅϰ˻ç½Ã Á¾·áÄ«¿îÅÍÀÌ´Ù... Me.VScrollBar1.Minimum = 0 '//½ºÅ©·Ñ¹Ù°¡ Àß ¾È¿òÁ÷ÀδÙ.(Â÷ÈÄ¿¡ ¼öÁ¤¿ä¸Á) Me.VScrollBar1.Maximum = Dv.Count - 1 Me.LOAD_STYLE() '//½ºÅ¸ÀϺҷ¯¿À±â(¿©±â¼­ ¸ðµçÄÁÆ®·ÑÀÇ ±âº» À§Ä¡¿Í ±Û²ÃÀÌ °áÁ¤µÈ´Ù) Console.WriteLine("Change Style Loading ½Ã°£ : " + wat.ElapsedMilliseconds.ToString() + "ms") Debug.Print("½ºÅ©·Ñ¹Ù°ª ¼³Á¤ " & Me.VScrollBar1.Minimum & "/" & Me.VScrollBar1.Maximum) If Me.FirstIdx = -1 Then For i As Integer = 0 To Dv.Count - 1 '//¸Ç÷º¸¿©ÁÙ³ðÀ» ã´Â´Ù. DV¿Í ¿ø·¡ À妽º°ªÀÌ ´Ù¸£±â¶§¹®¿¡ ã¾Æ¾ßÇÑ´Ù. If Dv(i)("¹øÈ£") = Srcnum Then FirstIdx = i Exit For End If Next End If If FirstIdx = -1 OrElse FirstIdx > Dv.Count - 1 Then FirstIdx = 0 '//ãÁö¸øÇÏ°í ³ª¿ÓÀ»°æ¿ì¿¡´Â 1¹ø¤Š ·¹Äڵ带 º¸¿©ÁÖµµ·Ï ÇÑ´Ù. NoView = True '//For Validate Index =0 If FirstIdx = 0 Then '//Index is first AddLog(Admin, "View : First Record // Set = 0", "\Alllog.txt") Else '//index is not first AddLog(Admin, "View : Index Count = " & FirstIdx, "\Alllog.txt") End If Me.BindingSource1.DataSource = Dv 'Dv '//¿©±â¼­¼ÂÆÃµÇ¸é¼­ ¹Ù·Î tview °¡ ÀÛµ¿µÈ´Ù. Me.BindingSource1.Sort = "Á¤·Ä¹øÈ£,¹øÈ£" ',¹øÈ£" Me.VScrollBar1.Value = FirstIdx Me.BindingSource1.Position = FirstIdx Me.dataview.DataSource = Me.BindingSource1 'MsgBox("ASDF" & Me.BindingNavigatorPositionItem.Text) If FirstIdx = 0 Then Me.GeTviewData(Me.BindingNavigatorPositionItem.Text - 1, True) End If Console.WriteLine("Change Style Àüü ½Ã°£ : " + wat.ElapsedMilliseconds.ToString() + "ms") wat.Stop() 'addlog(admin, "cmb_style selectindexchanged ¿¡¼­ preview ¸¦ È£ÃâÇÔ", "\Alllog.txt") 'Me.preview_window() End Sub Public Sub LOAD_STYLE(Optional ByVal Div As String = "Z") '//ÀúÀåµÈ ½ºÅ¸ÀÏÀ» ºÒ·¯¿É´Ï´Ù. If Div = "Z" Then Console.WriteLine("Load Style ** ¸ðµç ¶óº§À» ºÒ·¯¿É´Ï´Ù ** : Z") Else Console.WriteLine("Load Style : °³º°Ç׸ñ ºÒ·¯¿À±â DIV=" + Div) End If AddLog(Admin, "load_style : ½ºÅ¸ÀÏÀ» ºÒ·¯¿É´Ï´Ù. div= " & Div, "\Alllog.txt") Dim pos(), font(), visible, mytext As String Dim Tobj As MyControlOLEDBv2.MyLabel Dim DR() As DataRow Dim idx As Integer = 0 ''//±âÁ¸ÅÛÀÇ Á¤º¸¸¦ ¸ðµÎ Ŭ¸®¾îÇÑ´Ù. 'Dim f As New fProgress() 'f.ProgressBar1.Minimum = 0 'f.ProgressBar1.Maximum = Me.AllLabels.Length 'f.ProgressBar1.Value = 0 'f.ProgressBar1.Style = ProgressBarStyle.Blocks 'f.Label1.Text = String.Format("±âÁ¸ ½ºÅ¸ÀÏÀ» ÃʱâÈ­ ÇÕ´Ï´Ù." + vbCrLf + "Control") ''f.TopMost = True 'f.Show() 'Application.DoEvents() For i As Integer = 0 To Me.AllLabels.GetUpperBound(0) Tobj = Me.AllLabels(i).ctl ' f.ProgressBar1.Value += 1 If Div.ToUpper = "Z" OrElse Tobj.Name.ToUpper.StartsWith(Div) Then '//¸ðµç¾ÆÀÌÅÛÀ» °¡Á®¿À°í Tobj.Location = New Point(0, 0) Tobj.Size = New Size(10, 10) Tobj.ÀåÆò = 10 Tobj.Àå³ôÀÌ = 10 Tobj.MyFont = Me.Font Tobj.Visible = False 'Tobj.MyText = String.Empty '//±ÛÀÚ´Â parse ¿¡¼­ ÇÒ´çµÈ »óÅÂÀ̹ǷΠÁ¦°ÅÇϸé¾ÈµÈ´Ù. Tobj.°ø¹é = 0 Tobj.Repeat = False Tobj.RepeatX = 0 Tobj.RepeatY = 0 End If Next 'f.ProgressBar1.Value = 0 'f.Label1.Text = "½ºÅ¸ÀÏÀ» ºÒ·¯¿É´Ï´Ù" 'f.Show() 'Application.DoEvents() '//¸ðµç¾ÆÀÌÅÛÀ» µ·´Ù For i As Integer = 0 To Me.AllLabels.GetUpperBound(0) '//¸ðµç¾ÆÀÌÅÛÀ» µ·´Ù. 'f.ProgressBar1.Value = i + 1 'f.ProgressBar1.Refresh() Tobj = Me.AllLabels(i).ctl If Div.ToUpper = "Z" Then '//¸ðµç¾ÆÀÌÅÛÀ» °¡Á®¿À°í '//¸Þ¸ð¸®¿¡¼­ ã´Â´Ù. Tobj.Tag = "" DR = DtPattern.Select("NAME = 'STYLE" & Tobj.Name.ToUpper & "POS'") If DR.GetUpperBound(0) = 0 Then pos = DR(0)(1).ToString.Split(",") Tobj.Location = New Point(pos(0), pos(1)) Tobj.Size = New Size(pos(2), pos(3)) End If DR = DtPattern.Select("NAME = 'STYLE" & Tobj.Name.ToUpper & "FONT'") If DR.GetUpperBound(0) = 0 Then font = DR(0)(1).ToString.Split(",") Tobj.ÀåÆò = font(5) Tobj.Àå³ôÀÌ = font(6) Tobj.MyFont = New Font(font(0), font(1), IIf(font(3).ToUpper = "TRUE", FontStyle.Bold, FontStyle.Regular), GraphicsUnit.Point) End If DR = DtPattern.Select("NAME = 'STYLE" & Tobj.Name.ToUpper & "VISIBLE'") If DR.GetUpperBound(0) = 0 Then visible = DR(0)(1).ToString Tobj.Visible = CType(visible, Boolean) End If DR = DtPattern.Select("NAME = 'STYLE" & Tobj.Name.ToUpper & "MYTEXT'") If DR.GetUpperBound(0) = 0 Then mytext = DR(0)(1).ToString Select Case Tobj.Name.ToUpper.Substring(0, 1) Case "U", "A", "B", "D", "E" '//»ç¿ëÀÚ¹®ÀÚÀϰæ¿ì¿¡´Â ¹®ÀÚ¿­µµ ÀúÀåÇØ¾ßÇÑ´Ù. If mytext <> "" Then Tobj.MyText = TextDec(mytext) '//ini±¸Á¶»ó ¹Ù·ÎÀúÀåÇϸé¾ÈµÇ±â¶§¹®¿¡ º¯È¯Çؼ­ ÀúÀåÇÑ´Ù. End Select End If DR = DtPattern.Select("NAME = 'STYLE" & Tobj.Name.ToUpper & "SPACE'") If DR.GetUpperBound(0) = 0 Then Tobj.°ø¹é = DR(0)(1).ToString DR = DtPattern.Select("NAME = 'STYLE" & Tobj.Name.ToUpper & "REPEAT'") If DR.GetUpperBound(0) = 0 Then Dim strdata() As String = DR(0)(1).ToString.Split(",") Tobj.Repeat = CInt(strdata(0)) Tobj.RepeatX = CInt(strdata(1)) Tobj.RepeatY = CInt(strdata(2)) Else Tobj.Repeat = False Tobj.RepeatX = 0 Tobj.RepeatY = 0 End If Else '//ƯÁ¤¾ÆÀÌÅÛ±¸ºÐÀ϶§ If Tobj.Name.ToUpper.StartsWith(Div) Then If Div.ToUpper = "H" Then '//HÀǰæ¿ì´Â µû·Î ã¾Æº»´Ù. If Me.°ü¸®±¸Á¶ÀÛµÊ = True Then '//°ü¸®±¸ºÒ·¯¿Â´Ù '//¸Þ¸ð¸®¿¡¼­ ã´Â´Ù. Tobj.Tag = "" DR = DtPattern.Select("NAME = 'STYLE" & Tobj.Name.ToUpper & "POS'") If DR.GetUpperBound(0) = 0 Then pos = DR(0)(1).ToString.Split(",") Tobj.Location = New Point(pos(0), pos(1)) Tobj.Size = New Size(pos(2), pos(3)) End If DR = DtPattern.Select("NAME = 'STYLE" & Tobj.Name.ToUpper & "FONT'") If DR.GetUpperBound(0) = 0 Then font = DR(0)(1).ToString.Split(",") Tobj.ÀåÆò = font(5) Tobj.Àå³ôÀÌ = font(6) Tobj.MyFont = New Font(font(0), font(1), IIf(font(3).ToUpper = "TRUE", FontStyle.Bold, FontStyle.Regular), GraphicsUnit.Point) End If DR = DtPattern.Select("NAME = 'STYLE" & Tobj.Name.ToUpper & "VISIBLE'") If DR.GetUpperBound(0) = 0 Then visible = DR(0)(1).ToString Tobj.Visible = CType(visible, Boolean) End If DR = DtPattern.Select("NAME = 'STYLE" & Tobj.Name.ToUpper & "MYTEXT'") If DR.GetUpperBound(0) = 0 Then mytext = DR(0)(1).ToString Select Case Tobj.Name.ToUpper.Substring(0, 1) Case "U", "A", "B", "D", "E" '//»ç¿ëÀÚ¹®ÀÚÀϰæ¿ì¿¡´Â ¹®ÀÚ¿­µµ ÀúÀåÇØ¾ßÇÑ´Ù. If mytext <> "" Then Tobj.MyText = TextDec(mytext) '//ini±¸Á¶»ó ¹Ù·ÎÀúÀåÇϸé¾ÈµÇ±â¶§¹®¿¡ º¯È¯Çؼ­ ÀúÀåÇÑ´Ù. End Select End If DR = DtPattern.Select("NAME = 'STYLE" & Tobj.Name.ToUpper & "SPACE'") If DR.GetUpperBound(0) = 0 Then Tobj.°ø¹é = DR(0)(1).ToString DR = DtPattern.Select("NAME = 'STYLE" & Tobj.Name.ToUpper & "REPEAT'") If DR.GetUpperBound(0) = 0 Then Dim strdata() As String = DR(0)(1).ToString.Split(",") Tobj.Repeat = CInt(strdata(0)) Tobj.RepeatX = CInt(strdata(1)) Tobj.RepeatY = CInt(strdata(2)) Else Tobj.Repeat = False Tobj.RepeatX = 0 Tobj.RepeatY = 0 End If End If Else '//¸Þ¸ð¸®¿¡¼­ ã´Â´Ù. Tobj.Tag = "" DR = DtPattern.Select("NAME = 'STYLE" & Tobj.Name.ToUpper & "POS'") If DR.GetUpperBound(0) = 0 Then pos = DR(0)(1).ToString.Split(",") Tobj.Location = New Point(pos(0), pos(1)) Tobj.Size = New Size(pos(2), pos(3)) End If DR = DtPattern.Select("NAME = 'STYLE" & Tobj.Name.ToUpper & "FONT'") If DR.GetUpperBound(0) = 0 Then font = DR(0)(1).ToString.Split(",") Tobj.ÀåÆò = font(5) Tobj.Àå³ôÀÌ = font(6) Tobj.MyFont = New Font(font(0), font(1), IIf(font(3).ToUpper = "TRUE", FontStyle.Bold, FontStyle.Regular), GraphicsUnit.Point) End If DR = DtPattern.Select("NAME = 'STYLE" & Tobj.Name.ToUpper & "VISIBLE'") If DR.GetUpperBound(0) = 0 Then visible = DR(0)(1).ToString Tobj.Visible = CType(visible, Boolean) End If DR = DtPattern.Select("NAME = 'STYLE" & Tobj.Name.ToUpper & "MYTEXT'") If DR.GetUpperBound(0) = 0 Then mytext = DR(0)(1).ToString Select Case Tobj.Name.ToUpper.Substring(0, 1) Case "U", "A", "B", "D", "E" '//»ç¿ëÀÚ¹®ÀÚÀϰæ¿ì¿¡´Â ¹®ÀÚ¿­µµ ÀúÀåÇØ¾ßÇÑ´Ù. If mytext <> "" Then Tobj.MyText = TextDec(mytext) '//ini±¸Á¶»ó ¹Ù·ÎÀúÀåÇϸé¾ÈµÇ±â¶§¹®¿¡ º¯È¯Çؼ­ ÀúÀåÇÑ´Ù. End Select End If DR = DtPattern.Select("NAME = 'STYLE" & Tobj.Name.ToUpper & "SPACE'") If DR.GetUpperBound(0) = 0 Then Tobj.°ø¹é = DR(0)(1).ToString End If DR = DtPattern.Select("NAME = 'STYLE" & Tobj.Name.ToUpper & "REPEAT'") If DR.GetUpperBound(0) = 0 Then Dim strdata() As String = DR(0)(1).ToString.Split(",") Tobj.Repeat = CInt(strdata(0)) Tobj.RepeatX = CInt(strdata(1)) Tobj.RepeatY = CInt(strdata(2)) Else Tobj.Repeat = False Tobj.RepeatX = 0 Tobj.RepeatY = 0 End If End If End If End If Next 'f.Label1.Text = "±âŸÁ¤º¸¸¦ ºÒ·¯¿É´Ï´Ù" 'f.Refresh() If Div.ToUpper <> "Z" Then Return '//¸ðµçÅÛÀ̾ƴϴ٠AddLog(Admin, "load_style ±âº»°ª üũ¹Ú½ºµîÀÇ °ªÀ» ºÒ·¯¿Â´Ù. À̰ÍÀº ¸Ç÷¿¡¸¸ ºÒ·¯¿À¸é µÈ´Ù. ", "\Alllog.txt") Dim Arinini As New MyINI2(DrStyle.FILE) '''''''''''''''''''''¿ìÃø ½ºÅ¸ÀÏ Ã¼Å©¹Ú½º¸¦ °¡Á®¿Â´Ù. For Each B As Control In Me.TabPage1.Controls If B.GetType.Name.ToUpper = "CHECKBOX" Then '//üũ¹Ú½º¶ó¸é ű׸¦ ÀúÀåÇÑ´Ù. CType(B, System.Windows.Forms.CheckBox).Checked = Arinini.Read("STYLE", B.Name.ToString, False) '//±âº»°ª false End If Next For Each B As Control In Me.TabPage3.Controls If B.GetType.Name.ToUpper = "CHECKBOX" Then '//üũ¹Ú½º¶ó¸é ű׸¦ ÀúÀåÇÑ´Ù. CType(B, System.Windows.Forms.CheckBox).Checked = Arinini.Read("STYLE", B.Name.ToString, False) '//±âº»°ª false End If Next For Each B As Control In Me.TabPage5.Controls If B.GetType.Name.ToUpper = "CHECKBOX" Then '//üũ¹Ú½º¶ó¸é ű׸¦ ÀúÀåÇÑ´Ù. CType(B, System.Windows.Forms.CheckBox).Checked = Arinini.Read("STYLE", B.Name.ToString, False) '//±âº»°ª false End If Next ''''''''''''''''''''''''''''¿Ü''''''''''''''''''''''''''''''''' Me.tb_marginx.Text = DrStyle.MARGINX 'Arinini.Read("STYLE", "MarginX", 10) Me.tb_marginy.Text = DrStyle.MARGINY ' Arinini.Read("STYLE", "MarginY", 10) Me.tb_scalex.Text = DrStyle.SCALEX ' Arinini.Read("STYLE", "ScaleX", "1.5") Me.tb_scaley.Text = DrStyle.SCALEY ' Arinini.Read("STYLE", "ScaleY", "1.3") ''''''''''''2Áß '//´õ¹Ì´Â ÀÌÁ¦ »ç¿ëÇÏÁö¾Ê´Â´Ù.20090729 º¯°æ 'Dim UseDummy As Boolean = StyleList(Me.cmb_style.SelectedIndex).Dummy 'Arinini.Read("STYLE", "dummy", False) 'Try Me.tb_pagerepeat.Text = DrStyle.DUMMYCNT If Me.tb_pagerepeat.Text.Trim = "" OrElse Me.tb_pagerepeat.Text < 1 Then Me.tb_pagerepeat.Text = "1" 'Catch ex As Exception ' If UseDummy Then ' Me.tb_pagerepeat.Text = "2" ' Else ' Me.tb_pagerepeat.Text = "1" ' End If 'End Try Me.cmb_dummy.SelectedIndex = DrStyle.DUMMYTYPE ' Arinini.Read("STYLE", "dummytype", 0) Me.tb_secX.Text = DrStyle.DUMMMYX ' Arinini.Read("STYLE", "dummmyx", "0") Me.tb_secY.Text = DrStyle.DUMMMYY ' Arinini.Read("STYLE", "dummmyy", "300") '//QRÄÚµå Try Me.cboCorrectionLevel.Text = Arinini.Read("STYLE", "qrlevel", 1) Me.cboEncoding.Text = Arinini.Read("STYLE", "qrencoding", 2) Me.cboVersion.Text = Arinini.Read("STYLE", "qrvison", 1) Dim qrbgstr As String = Arinini.Read("STYLE", "qrbg", "") Dim qrfgstr As String = Arinini.Read("STYLE", "qrfg", "") If qrbgstr = "" Then lbQrBg.BackColor = Drawing.Color.White Else lbQrBg.BackColor = Drawing.Color.FromArgb(CInt(qrbgstr)) End If If qrfgstr = "" Then lbQrFG.BackColor = Drawing.Color.Black Else lbQrFG.BackColor = Drawing.Color.FromArgb(CInt(qrfgstr)) End If Catch ex As Exception MessageBox.Show(ex.ToString()) End Try '//QRȨÆäÀÌÁö '//Try Me.home1.Text = Arinini.Read("STYLE", "qrhome1", "http://cyber.kepco.co.kr") Me.home2.Text = Arinini.Read("STYLE", "qrhome2", "jeonbuk") Me.home3.Text = Arinini.Read("STYLE", "qrhome3", "mjeonbuk") Me.home4.Text = Arinini.Read("STYLE", "qrhome4", "report.jsp?location") '//Catch ex As Exception '// MessageBox.Show(ex.ToString()) '//End Try '//QR±âŸ Ãâ·ÂºÎºÐ Me.gita1.Text = Arinini.Read("STYLE", "rqrgita1", "") Me.gita2.Text = Arinini.Read("STYLE", "rqrgita2", "") Me.gita3.Text = Arinini.Read("STYLE", "rqrgita3", "") Me.gita4.Text = Arinini.Read("STYLE", "rqrgita4", "") Me.gojang.Text = Arinini.Read("STYLE", "gojang1", "°íÀå½Å°íµµ ½º¸¶Æ®ÇϰÔ") If DrStyle.BACKIMG.IndexOf("\") = -1 Then Me.tb_picfile.Text = My.Application.Info.DirectoryPath & "\image\" & DrStyle.BACKIMG Else Me.tb_picfile.Text = DrStyle.BACKIMG ' Arinini.Read("STYLE", "backimg", My.Application.Info.DirectoryPath & "\image\wall.bmp").ToString.Trim(Chr(0)) End If Me.ViewBackImage() '//¹è°æÀ̹ÌÁö¸¦ Ç¥½ÃÇÑ´Ù. Me.pDoc.DefaultPageSettings.Landscape = DrStyle.LANDSCAPE ' Arinini.Read("STYLE", "LandScape", False) Me.cmb_landscape.SelectedIndex = IIf(Me.pDoc.DefaultPageSettings.Landscape, 1, 0) Me.chk_DisplayBG.Checked = DrStyle.VIEWIMAGE ' Arinini.Read("STYLE", "ViewImage", True) Me.tb_myfontsize.Text = DrStyle.PRINTFONTOFFSET ' Arinini.Read("STYLE", "PrintFontOffset", 0) NOTICE(Me.cmb_style.Text & "½ºÅ¸ÀÏÀ» ºÒ·¯¿Ô½À´Ï´Ù.", Me.lb_msg) Application.DoEvents() End Sub Public Sub SAVE_STYLE() AddLog(Admin, "iniÆÄÀÏ¿¡ ½ºÅ¸ÀÏÀ» ÀúÀåÇÕ´Ï´Ù. ", "\Alllog.txt") Dim Arinini As New MyINI2(DrStyle.FILE) Dim Arininic As New MyINI2(CStr(DrStyle.FILE).ToLower.Replace("ini", "cfg")) Dim Tobj As MyControlOLEDBv2.MyLabel '//ÇöÀç ¼±ÅÃµÈ ½ºÅ¸ÀÏÀ» ÀúÀåÇÕ´Ï´Ù. If Me.cmb_style.SelectedIndex < 0 Then erp.SetError(Me.cmb_style, "ÀúÀåÇÒ ½ºÅ¸ÀÏÀÌ ¼±ÅõǾîÀÖÁö ¾Ê½À´Ï´Ù") NOTICE("½ºÅ¸ÀÏÀ» ¼±ÅÃÇϼ¼¿ä", Me.lb_msg) Return End If erp.SetError(Me.cmb_style, vbNullString) Dim f As New fProgress() f.ProgressBar1.Minimum = 0 f.ProgressBar1.Maximum = Me.AllLabels.Length f.ProgressBar1.Value = 0 f.ProgressBar1.Style = ProgressBarStyle.Blocks f.Label1.Text = String.Format("½ºÅ¸ÀÏÀ» ÀúÀåÇÕ´Ï´Ù" + vbCrLf + "Control") 'f.TopMost = True f.Show() Application.DoEvents() Dim Div As Char For i As Integer = 0 To Me.AllLabels.GetUpperBound(0) f.ProgressBar1.Value += 1 f.Refresh() Tobj = Me.AllLabels(i).ctl Arinini.Write("STYLE", Tobj.Name & "pos", Tobj.Left & "," & Tobj.Top & "," & Tobj.Width & "," & Tobj.Height) Arinini.Write("STYLE", Tobj.Name & "font", Tobj.MyFont.Name & "," & Tobj.MyFont.Size & "," & Tobj.MyFont.Underline & "," & Tobj.MyFont.Bold & "," & Tobj.MyFont.Italic & "," & Tobj.ÀåÆò & "," & Tobj.Àå³ôÀÌ) Arinini.Write("STYLE", Tobj.Name & "visible", "true") '±âº»°ªÀ¸·Î Ç¥½Ã·Î Á¤Çسõ°í üũ¹Ú½º üũÇÑ´Ù. Arinini.Write("STYLE", Tobj.Name & "space", Tobj.°ø¹é) Arinini.Write("STYLE", Tobj.Name & "repeat", Tobj.Repeat.ToString() + "," + Tobj.RepeatX.ToString() + "," + Tobj.RepeatY.ToString()) '//170222 Select Case Tobj.Name.ToUpper.Substring(0, 1) Case "U", "A", "B", "D", "E", "Z" Arinini.Write("STYLE", Tobj.Name & "mytext", TextEnc(Tobj.MyText)) Case "F", "I", "T" ' Debug.WriteLine("new datarow") End Select Div = Tobj.Name.Substring(0, 1) '1ÀÚ¸®¸¸²÷¾î¼­ üũ¹Ú½º ű׶û ¿¬°áÇÑ´Ù. For Each B As Control In Me.TabPage1.Controls If B.GetType.Name.ToUpper = "CHECKBOX" Then '//üũ¹Ú½º¶ó¸é ű׸¦ ÀúÀåÇÑ´Ù. If B.Tag <> Nothing AndAlso B.Tag.ToString.ToUpper = Div.ToString.ToUpper Then '//ÇØ´ç üũ¹Ú½º¸¦ ã¾ÒÀ¸¸é üũ¹Ú½º »óÅ·ΠÀúÀåÀ»ÇÑ´Ù. Arinini.Write("STYLE", Tobj.Name & "visible", CType(B, System.Windows.Forms.CheckBox).Checked) 'A.Visible) Exit For End If End If Next Next f.Label1.Text = String.Format("½ºÅ¸ÀÏÀ» ÀúÀåÇÕ´Ï´Ù" + vbCrLf + "CheckBox") f.Show() Application.DoEvents() f.ProgressBar1.Style = ProgressBarStyle.Marquee For Each TC As TabPage In Me.TabControl1.TabPages '//ÅÇÄÁÆ®·Ñ1ÀÇ ¸ðµç ÆäÀÌÁö¿¡¼­ üũ¹Ú½ºÀÇ »óŸ¦ ÀúÀåÇÑ´Ù. For Each B As Control In TC.Controls If B.GetType.Name.ToUpper = "CHECKBOX" Then '//üũ¹Ú½º¶ó¸é ű׸¦ ÀúÀåÇÑ´Ù. Arinini.Write("STYLE", B.Name, CType(B, System.Windows.Forms.CheckBox).Checked) 'A.Visible) End If Next Next 'For Each B As Control In Me.TabPage1.Controls ' If B.GetType.Name.ToUpper = "CHECKBOX" Then '//üũ¹Ú½º¶ó¸é ű׸¦ ÀúÀåÇÑ´Ù. ' Arinini.Write("STYLE", B.Name.ToString, CType(B, System.Windows.Forms.CheckBox).Checked) 'A.Visible) ' End If 'Next 'For Each B As Control In Me.TabPage3.Controls ' If B.GetType.Name.ToUpper = "CHECKBOX" Then '//üũ¹Ú½º¶ó¸é ű׸¦ ÀúÀåÇÑ´Ù. ' Arinini.Write("STYLE", B.Name.ToString, CType(B, System.Windows.Forms.CheckBox).Checked) 'A.Visible) ' End If 'Next f.Label1.Text = String.Format("½ºÅ¸ÀÏÀ» ÀúÀåÇÕ´Ï´Ù" + vbCrLf + "ÀϹÝÁ¤º¸") f.Show() Application.DoEvents() Arinini.Write("STYLE", "CanvasX", Me.PictureBox1.Width) '//ĵ¹ö½º»çÀÌÁîÀúÀåÇÑ´Ù. Arinini.Write("STYLE", "CanvasY", Me.PictureBox1.Height) Arinini.Write("STYLE", "ViewImage", Me.chk_DisplayBG.Checked) If Not IsNumeric(tb_marginx.Text) Then MsgBox("Àμ⿩¹é(°¡·Î) °ªÀ» ¼ýÀÚ·Î ÀÔ·ÂÇϼ¼¿ä." + vbCrLf + "ÇöÀçÀԷ°ª:" + tb_marginx.Text, MsgBoxStyle.Information, "È®ÀÎ") Else Arininic.Write("printer", "MarginX", Me.tb_marginx.Text) End If If Not IsNumeric(tb_marginy.Text) Then MsgBox("Àμ⿩¹é(¼¼·Î) °ªÀ» ¼ýÀÚ·Î ÀÔ·ÂÇϼ¼¿ä." + vbCrLf + "ÇöÀçÀԷ°ª:" + tb_marginy.Text, MsgBoxStyle.Information, "È®ÀÎ") Else Arininic.Write("printer", "MarginY", Me.tb_marginy.Text) End If If Not IsNumeric(tb_scalex.Text) Then MsgBox("È®´ëºñÀ²(°¡·Î) °ªÀ» ¼ýÀÚ·Î ÀÔ·ÂÇϼ¼¿ä." + vbCrLf + "ÇöÀçÀԷ°ª:" + tb_scalex.Text, MsgBoxStyle.Information, "È®ÀÎ") Else Arininic.Write("printer", "ScaleX", Me.tb_scalex.Text) End If If Not IsNumeric(tb_scaley.Text) Then MsgBox("È®´ëºñÀ²(¼¼·Î) °ªÀ» ¼ýÀÚ·Î ÀÔ·ÂÇϼ¼¿ä." + vbCrLf + "ÇöÀçÀԷ°ª:" + tb_scaley.Text, MsgBoxStyle.Information, "È®ÀÎ") Else Arininic.Write("printer", "ScaleY", Me.tb_scaley.Text) End If If Me.tb_picfile.Text.Trim = "" Then Arinini.Write("STYLE", "backimg", "") Else Dim newpath As String = CStr(My.Application.Info.DirectoryPath & "\image\").ToUpper Dim NEwpathp As Short = (Me.tb_picfile.Text.ToUpper.IndexOf(newpath)) If NEwpathp = -1 Then Arinini.Write("STYLE", "backimg", Me.tb_picfile.Text) Else Arinini.Write("STYLE", "backimg", Me.tb_picfile.Text.Substring(NEwpathp + newpath.Length)) End If End If Arininic.Write("printer", "PrintFontOffset", Me.tb_myfontsize.Text) Arinini.Write("STYLE", "LandScape", Me.pDoc.DefaultPageSettings.Landscape) '//´õ¹Ì üũ¹Ú½º¶û ´õ¹ÌÄÞº¸¹Ú½º À妽º¶û º¯À§ x,y ' Arinini.Write("STYLE", "dummy", Me.cb_dummy.Checked) Arinini.Write("STYLE", "dummycnt", Me.tb_pagerepeat.Text) Arinini.Write("STYLE", "dummytype", Me.cmb_dummy.SelectedIndex) Arinini.Write("STYLE", "dummmyx", Me.tb_secX.Text) Arinini.Write("STYLE", "dummmyy", Me.tb_secY.Text) ' Arinini.Write("STYLE", "picstyle", Me.ComboBox1.SelectedIndex) '//QRÄÚµå Arinini.Write("STYLE", "qrencoding", Me.cboEncoding.Text) Arinini.Write("STYLE", "qrlevel", Me.cboCorrectionLevel.Text) Arinini.Write("STYLE", "qrvison", Me.cboVersion.Text) Arinini.Write("STYLE", "qrfg", Me.lbQrFG.BackColor.ToArgb().ToString()) Arinini.Write("STYLE", "qrbg", Me.lbQrBg.BackColor.ToArgb().ToString()) '//QRȨÆäÀÌÁö Arinini.Write("STYLE", "qrhome1", Me.home1.Text) Arinini.Write("STYLE", "qrhome2", Me.home2.Text) Arinini.Write("STYLE", "qrhome3", Me.home3.Text) Arinini.Write("STYLE", "qrhome4", Me.home4.Text) '//QR±âŸ Arinini.Write("STYLE", "rqrgita1", Me.gita1.Text) Arinini.Write("STYLE", "rqrgita2", Me.gita2.Text) Arinini.Write("STYLE", "rqrgita3", Me.gita3.Text) Arinini.Write("STYLE", "rqrgita4", Me.gita4.Text) Arinini.Write("STYLE", "gojang1", Me.gojang.Text) f.Label1.Text = String.Format("½ºÅ¸ÀÏÀ» ÀúÀåÇÕ´Ï´Ù" + vbCrLf + "·¹À̾ƿô") f.Show() Application.DoEvents() Me.SaveReadLayOut(False) f.Label1.Text = String.Format("½ºÅ¸ÀÏÀ» ÀúÀåÇÕ´Ï´Ù" + vbCrLf + "±×¸®±â°³Ã¼") f.Show() Application.DoEvents() Me.SaveDrawData(False) NOTICE("±âº»½ºÅ¸ÀÏÀ» ÀúÀåÇß½À´Ï´Ù", Me.lb_msg) AddLog(Admin, "save style ¿Ï·áÈÄ µ¥ÀÌÅÍÅ×ÀÌºí °»½ÅÀ» È£­„ ", "\Alllog.txt") f.Close() f.Dispose() Application.DoEvents() Me.µ¥ÀÌÅÍÅ×ÀÌºí°»½Å() Me.preview_window() End Sub Public Sub SAVE_PATTERNII(ByVal SRCSTR As String, ByVal MIDNAME As String, ByVal DIV As Char, IncludeH As Boolean, Optional ByVal LOGFILENAME As String = "\ÆÐÅÏ.TXT") 'ÆÐÅÏÀ» ÀúÀåÇÕ´Ï´Ù. ÆÐÅÏ¿ª½Ã À§Ä¡/Å©±â/ÀåÆòµîÀÌ ÀúÀåµË´Ï´Ù. '//À̰÷Àº ¹®ÀÚÆÐÅÏÀ» ÀúÀåÇÑ´Ù. Dim Arinini As New MyINI2(DrStyle.FILE) Dim BUF() As Char = SRCSTR.ToCharArray Dim mb As String = PATTERN_ENC(SRCSTR, IncludeH) '//h ¿©ºÎ¿¡µû¶ó¼­ ÀúÀåµÈ ÆÐÅϸíÀÌ ´Þ¶óÁö°ÔµÈ´Ù. ÈÄ¿¡ ãÀ»‹š h¸¦ º¯È¯ÇÑ°É ¸ÕÀú ãÀºÈÄ Ã³¸®ÇϰÔÇÑ´Ù Dim TOBJ As MyControlOLEDBv2.MyLabel Dim Pname As String = MIDNAME & mb.ToString If MsgBox("¹®ÀÚÆÐÅÏ" + IIf(IncludeH, "(H)", "") + "À» ÀúÀåÇϽðڽÀ´Ï±î?", MsgBoxStyle.Information + MsgBoxStyle.OkCancel, "È®ÀÎ") <> MsgBoxResult.Ok Then NOTICE("¹®ÀÚÆÐÅÏ ÀúÀåÀÌ Ãë¼ÒµÇ¾ú½À´Ï´Ù", Me.lb_msg) Return End If Dim f As New fProgress() f.ProgressBar1.Minimum = 0 f.ProgressBar1.Maximum = 0 f.ProgressBar1.Style = ProgressBarStyle.Blocks f.Label1.Text = String.Format("ÆÐÅÏ({0})À» ÀúÀåÇÕ´Ï´Ù" + vbCrLf + MIDNAME, DIV) f.TopMost = True f.Show() Application.DoEvents() AddLog(Admin, " save_pattern2" + IIf(IncludeH, "(H)", "") + " ¸¦ ½ÇÇàÇÑ´Ù.", "\Alllog.txt") Select Case DIV.ToString.ToUpper Case "M" '//°¨µ¶ÀÚ f.ProgressBar1.Maximum = S°¨µ¶ÀÚ.Length f.ProgressBar1.Value = 0 f.Refresh() For i As Integer = 0 To Me.S°¨µ¶ÀÚ.GetUpperBound(0) TOBJ = Me.S°¨µ¶ÀÚ(i) ' AddLog(Admin, MIDNAME & "ÆÐÅÏÀúÀå½Ã ¾ÆÀÌÅÛ=" & TOBJ.Name & "/" & TOBJ.Name.Substring(0, 1).ToUpper, LOGFILENAME) Arinini.Write(Pname, "DESC", "ÀúÀåµÈ ¹®ÀÚÆÐÅÏ " & MIDNAME) ' AddLog(Admin, "ÃÖÁ¾¼±ÅÿϷá=" & Pname & " " & TOBJ.Name & "/" & TOBJ.Name.Substring(0, 1).ToUpper, LOGFILENAME) Arinini.Write(Pname, TOBJ.Name & "pos", TOBJ.Left & "," & TOBJ.Top & "," & TOBJ.Width & "," & TOBJ.Height) Arinini.Write(Pname, TOBJ.Name & "font", TOBJ.MyFont.Name & "," & TOBJ.MyFont.Size & "," & TOBJ.MyFont.Underline & "," & TOBJ.MyFont.Bold & "," & TOBJ.MyFont.Italic & "," & TOBJ.ÀåÆò & "," & TOBJ.Àå³ôÀÌ) Arinini.Write(Pname, TOBJ.Name & "visible", TOBJ.Visible) Arinini.Write(Pname, TOBJ.Name & "space", TOBJ.°ø¹é) f.ProgressBar1.Value += 1 Next Arinini.Write(Pname, "LineType1", Me.tb_ntype.Text) Arinini.Write(Pname, "nseparate1", Me.cmb_sep.SelectedIndex) Case "J" '//Àåô 170215 f.ProgressBar1.Maximum = SÀåô.Length f.ProgressBar1.Value = 0 f.Refresh() For i As Integer = 0 To Me.SÀåô.GetUpperBound(0) TOBJ = Me.SÀåô(i) 'AddLog(Admin, MIDNAME & "ÆÐÅÏÀúÀå½Ã ¾ÆÀÌÅÛ=" & TOBJ.Name & "/" & TOBJ.Name.Substring(0, 1).ToUpper, LOGFILENAME) Arinini.Write(Pname, "DESC", "ÀúÀåµÈ ¹®ÀÚÆÐÅÏ " & MIDNAME) ' AddLog(Admin, "ÃÖÁ¾¼±ÅÿϷá=" & Pname & " " & TOBJ.Name & "/" & TOBJ.Name.Substring(0, 1).ToUpper, LOGFILENAME) Arinini.Write(Pname, TOBJ.Name & "pos", TOBJ.Left & "," & TOBJ.Top & "," & TOBJ.Width & "," & TOBJ.Height) Arinini.Write(Pname, TOBJ.Name & "font", TOBJ.MyFont.Name & "," & TOBJ.MyFont.Size & "," & TOBJ.MyFont.Underline & "," & TOBJ.MyFont.Bold & "," & TOBJ.MyFont.Italic & "," & TOBJ.ÀåÆò & "," & TOBJ.Àå³ôÀÌ) Arinini.Write(Pname, TOBJ.Name & "visible", TOBJ.Visible) Arinini.Write(Pname, TOBJ.Name & "space", TOBJ.°ø¹é) f.ProgressBar1.Value += 1 Next Case "L" '//¼±·Î¸í f.ProgressBar1.Maximum = S¼±·Î¸í.Length f.ProgressBar1.Value = 0 f.Refresh() For i As Integer = 0 To Me.S¼±·Î¸í.GetUpperBound(0) TOBJ = Me.S¼±·Î¸í(i) 'AddLog(Admin, MIDNAME & "ÆÐÅÏÀúÀå½Ã ¾ÆÀÌÅÛ=" & TOBJ.Name & "/" & TOBJ.Name.Substring(0, 1).ToUpper, LOGFILENAME) Arinini.Write(Pname, "DESC", "ÀúÀåµÈ ¹®ÀÚÆÐÅÏ " & MIDNAME) 'AddLog(Admin, "ÃÖÁ¾¼±ÅÿϷá=" & Pname & " " & TOBJ.Name & "/" & TOBJ.Name.Substring(0, 1).ToUpper, LOGFILENAME) Arinini.Write(Pname, TOBJ.Name & "pos", TOBJ.Left & "," & TOBJ.Top & "," & TOBJ.Width & "," & TOBJ.Height) Arinini.Write(Pname, TOBJ.Name & "font", TOBJ.MyFont.Name & "," & TOBJ.MyFont.Size & "," & TOBJ.MyFont.Underline & "," & TOBJ.MyFont.Bold & "," & TOBJ.MyFont.Italic & "," & TOBJ.ÀåÆò & "," & TOBJ.Àå³ôÀÌ) Arinini.Write(Pname, TOBJ.Name & "visible", TOBJ.Visible) Arinini.Write(Pname, TOBJ.Name & "space", TOBJ.°ø¹é) f.ProgressBar1.Value += 1 Next Case "C" '//¼±·Î¸í f.ProgressBar1.Maximum = S½Ã°øÀÚ.Length f.ProgressBar1.Value = 0 f.Refresh() For i As Integer = 0 To Me.S½Ã°øÀÚ.GetUpperBound(0) TOBJ = Me.S½Ã°øÀÚ(i) 'AddLog(Admin, MIDNAME & "ÆÐÅÏÀúÀå½Ã ¾ÆÀÌÅÛ=" & TOBJ.Name & "/" & TOBJ.Name.Substring(0, 1).ToUpper, LOGFILENAME) Arinini.Write(Pname, "DESC", "ÀúÀåµÈ ¹®ÀÚÆÐÅÏ " & MIDNAME) 'AddLog(Admin, "ÃÖÁ¾¼±ÅÿϷá=" & Pname & " " & TOBJ.Name & "/" & TOBJ.Name.Substring(0, 1).ToUpper, LOGFILENAME) Arinini.Write(Pname, TOBJ.Name & "pos", TOBJ.Left & "," & TOBJ.Top & "," & TOBJ.Width & "," & TOBJ.Height) Arinini.Write(Pname, TOBJ.Name & "font", TOBJ.MyFont.Name & "," & TOBJ.MyFont.Size & "," & TOBJ.MyFont.Underline & "," & TOBJ.MyFont.Bold & "," & TOBJ.MyFont.Italic & "," & TOBJ.ÀåÆò & "," & TOBJ.Àå³ôÀÌ) Arinini.Write(Pname, TOBJ.Name & "visible", TOBJ.Visible) Arinini.Write(Pname, TOBJ.Name & "space", TOBJ.°ø¹é) f.ProgressBar1.Value += 1 Next Case "K" '//dl¸í f.ProgressBar1.Maximum = Sºñ°í¸í.Length f.ProgressBar1.Value = 0 f.Refresh() For i As Integer = 0 To Me.Sºñ°í¸í.GetUpperBound(0) TOBJ = Me.Sºñ°í¸í(i) ' AddLog(Admin, MIDNAME & "ÆÐÅÏÀúÀå½Ã ¾ÆÀÌÅÛ=" & TOBJ.Name & "/" & TOBJ.Name.Substring(0, 1).ToUpper, LOGFILENAME) Arinini.Write(Pname, "DESC", "ÀúÀåµÈ ¹®ÀÚÆÐÅÏ " & MIDNAME) ' AddLog(Admin, "ÃÖÁ¾¼±ÅÿϷá=" & Pname & " " & TOBJ.Name & "/" & TOBJ.Name.Substring(0, 1).ToUpper, LOGFILENAME) Arinini.Write(Pname, TOBJ.Name & "pos", TOBJ.Left & "," & TOBJ.Top & "," & TOBJ.Width & "," & TOBJ.Height) Arinini.Write(Pname, TOBJ.Name & "font", TOBJ.MyFont.Name & "," & TOBJ.MyFont.Size & "," & TOBJ.MyFont.Underline & "," & TOBJ.MyFont.Bold & "," & TOBJ.MyFont.Italic & "," & TOBJ.ÀåÆò & "," & TOBJ.Àå³ôÀÌ) Arinini.Write(Pname, TOBJ.Name & "visible", TOBJ.Visible) Arinini.Write(Pname, TOBJ.Name & "space", TOBJ.°ø¹é) f.ProgressBar1.Value += 1 Next Case "F" '//ÈÞÁî¿ë·® f.ProgressBar1.Maximum = SÈÞÁî¿ë·®.Length f.ProgressBar1.Value = 0 f.Refresh() For i As Integer = 0 To Me.SÈÞÁî¿ë·®.GetUpperBound(0) TOBJ = Me.SÈÞÁî¿ë·®(i) ' AddLog(Admin, MIDNAME & "ÆÐÅÏÀúÀå½Ã ¾ÆÀÌÅÛ=" & TOBJ.Name & "/" & TOBJ.Name.Substring(0, 1).ToUpper, LOGFILENAME) Arinini.Write(Pname, "DESC", "ÀúÀåµÈ ¹®ÀÚÆÐÅÏ " & MIDNAME) ' AddLog(Admin, "ÃÖÁ¾¼±ÅÿϷá=" & Pname & " " & TOBJ.Name & "/" & TOBJ.Name.Substring(0, 1).ToUpper, LOGFILENAME) Arinini.Write(Pname, TOBJ.Name & "pos", TOBJ.Left & "," & TOBJ.Top & "," & TOBJ.Width & "," & TOBJ.Height) Arinini.Write(Pname, TOBJ.Name & "font", TOBJ.MyFont.Name & "," & TOBJ.MyFont.Size & "," & TOBJ.MyFont.Underline & "," & TOBJ.MyFont.Bold & "," & TOBJ.MyFont.Italic & "," & TOBJ.ÀåÆò & "," & TOBJ.Àå³ôÀÌ) Arinini.Write(Pname, TOBJ.Name & "visible", TOBJ.Visible) Arinini.Write(Pname, TOBJ.Name & "space", TOBJ.°ø¹é) f.ProgressBar1.Value += 1 Next Case "I" '//»óÇ¥½ÃÂû 1´Ü 150201 f.ProgressBar1.Maximum = S»óÇ¥½ÃÂû1´Ü.Length f.ProgressBar1.Value = 0 f.Refresh() For i As Integer = 0 To Me.S»óÇ¥½ÃÂû1´Ü.GetUpperBound(0) TOBJ = Me.S»óÇ¥½ÃÂû1´Ü(i) ' AddLog(Admin, MIDNAME & "ÆÐÅÏÀúÀå½Ã ¾ÆÀÌÅÛ=" & TOBJ.Name & "/" & TOBJ.Name.Substring(0, 1).ToUpper, LOGFILENAME) Arinini.Write(Pname, "DESC", "ÀúÀåµÈ ¹®ÀÚÆÐÅÏ " & MIDNAME) ' AddLog(Admin, "ÃÖÁ¾¼±ÅÿϷá=" & Pname & " " & TOBJ.Name & "/" & TOBJ.Name.Substring(0, 1).ToUpper, LOGFILENAME) Arinini.Write(Pname, TOBJ.Name & "pos", TOBJ.Left & "," & TOBJ.Top & "," & TOBJ.Width & "," & TOBJ.Height) Arinini.Write(Pname, TOBJ.Name & "font", TOBJ.MyFont.Name & "," & TOBJ.MyFont.Size & "," & TOBJ.MyFont.Underline & "," & TOBJ.MyFont.Bold & "," & TOBJ.MyFont.Italic & "," & TOBJ.ÀåÆò & "," & TOBJ.Àå³ôÀÌ) Arinini.Write(Pname, TOBJ.Name & "visible", TOBJ.Visible) Arinini.Write(Pname, TOBJ.Name & "space", TOBJ.°ø¹é) f.ProgressBar1.Value += 1 Next Case "T" '//»óÇ¥½ÃÂû 2´Ü 150201 f.ProgressBar1.Maximum = S»óÇ¥½ÃÂû2´Ü.Length f.ProgressBar1.Value = 0 f.Refresh() For i As Integer = 0 To Me.S»óÇ¥½ÃÂû2´Ü.GetUpperBound(0) TOBJ = Me.S»óÇ¥½ÃÂû2´Ü(i) ' AddLog(Admin, MIDNAME & "ÆÐÅÏÀúÀå½Ã ¾ÆÀÌÅÛ=" & TOBJ.Name & "/" & TOBJ.Name.Substring(0, 1).ToUpper, LOGFILENAME) Arinini.Write(Pname, "DESC", "ÀúÀåµÈ ¹®ÀÚÆÐÅÏ " & MIDNAME) ' AddLog(Admin, "ÃÖÁ¾¼±ÅÿϷá=" & Pname & " " & TOBJ.Name & "/" & TOBJ.Name.Substring(0, 1).ToUpper, LOGFILENAME) Arinini.Write(Pname, TOBJ.Name & "pos", TOBJ.Left & "," & TOBJ.Top & "," & TOBJ.Width & "," & TOBJ.Height) Arinini.Write(Pname, TOBJ.Name & "font", TOBJ.MyFont.Name & "," & TOBJ.MyFont.Size & "," & TOBJ.MyFont.Underline & "," & TOBJ.MyFont.Bold & "," & TOBJ.MyFont.Italic & "," & TOBJ.ÀåÆò & "," & TOBJ.Àå³ôÀÌ) Arinini.Write(Pname, TOBJ.Name & "visible", TOBJ.Visible) Arinini.Write(Pname, TOBJ.Name & "space", TOBJ.°ø¹é) f.ProgressBar1.Value += 1 Next Case "X" '//ÀüÁÖ¹øÈ£ f.ProgressBar1.Maximum = SÀüÁÖ¹øÈ£.Length f.ProgressBar1.Value = 0 f.Refresh() For i As Integer = 0 To Me.SÀüÁÖ¹øÈ£.GetUpperBound(0) TOBJ = Me.SÀüÁÖ¹øÈ£(i) 'AddLog(Admin, MIDNAME & "ÆÐÅÏÀúÀå½Ã ¾ÆÀÌÅÛ=" & TOBJ.Name & "/" & TOBJ.Name.Substring(0, 1).ToUpper, LOGFILENAME) Arinini.Write(Pname, "DESC", "ÀúÀåµÈ ¹®ÀÚÆÐÅÏ " & MIDNAME) ' AddLog(Admin, "ÃÖÁ¾¼±ÅÿϷá=" & Pname & " " & TOBJ.Name & "/" & TOBJ.Name.Substring(0, 1).ToUpper, LOGFILENAME) Arinini.Write(Pname, TOBJ.Name & "pos", TOBJ.Left & "," & TOBJ.Top & "," & TOBJ.Width & "," & TOBJ.Height) Arinini.Write(Pname, TOBJ.Name & "font", TOBJ.MyFont.Name & "," & TOBJ.MyFont.Size & "," & TOBJ.MyFont.Underline & "," & TOBJ.MyFont.Bold & "," & TOBJ.MyFont.Italic & "," & TOBJ.ÀåÆò & "," & TOBJ.Àå³ôÀÌ) Arinini.Write(Pname, TOBJ.Name & "visible", TOBJ.Visible) Arinini.Write(Pname, TOBJ.Name & "space", TOBJ.°ø¹é) f.ProgressBar1.Value += 1 Next Arinini.Write(Pname, "LineType", Me.tb_ntype.Text) Arinini.Write(Pname, "nseparate", Me.cmb_sep.SelectedIndex) Case Else MsgBox("Save_PatternII ¿¡ Á¤ÀǵÇÁö¾ÊÀº ¹®ÀÚ(" & DIV & ") °¡ ¹ß»ýÇÏ¿´½À´Ï´Ù", MsgBoxStyle.Critical, "È®ÀÎ") End Select f.Close() f.Dispose() Application.DoEvents() AddLog(Admin, "save_patter2 ¿¡¼­ µ¥ÀÌÅÍÅ×ÀÌºí °»½ÅÀ» ¤¾È£ÃâÇÑ´Ù¤Ó¤Ó ", "\Alllog.txt") Me.µ¥ÀÌÅÍÅ×ÀÌºí°»½Å() End Sub Private Sub cmb_controls_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles cmb_controls.SelectedIndexChanged '//°³Ã¼°¡ ¼±ÅõǸé ÇØ´ç °³Ã¼ÀÇ ³»¿ªÀ» º¸¿©ÁØ´Ù. 'Me.Timer1.Enabled = False AddLog(Admin, "°³Ã¼¸ñ·Ï ÄÞº¸¹Ú½º¿¡¼­ ƯÁ¤ °³Ã¼°¡ ¼±ÅõǾú´Ù view property È£Ãâ", "\Alllog.txt") ViewProperty(AllLabels(Me.cmb_controls.SelectedIndex).ctl) End Sub Private Sub cb_visible_CheckedChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles cb_visible.CheckedChanged AddLog(Admin, "Ç¥½Ã üũ¹Ú½º ¼±Åà ", "\Alllog.txt") For Each a As Control In SelCon a.Visible = Me.cb_visible.Checked Next AddLog(Admin, "[Ç¥½Ã] üũ¹Ú½º ¼±Åÿ¡¼­ pewview¸¦ È£Ãâ ", "\Alllog.txt") Me.preview_window() End Sub Private Sub tb_foncol_DoubleClick(ByVal sender As Object, ByVal e As System.EventArgs) Handles tb_foncol.DoubleClick AddLog(Admin, " ±Û¾¾»ö±ò º¯°æ Ŭ¸¯µÊ", "\Alllog.txt") Dim A As New ColorDialog If A.ShowDialog() = System.Windows.Forms.DialogResult.OK Then For Each Onlyone As MyControlOLEDBv2.MyLabel In SelCon Onlyone.MyForeColor = A.Color Next Me.tb_foncol.BackColor = A.Color End If Me.preview_window() End Sub Private Sub cb_bold_CheckedChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles cb_bold.CheckedChanged AddLog(Admin, "±Û¾¾…B°Ô ¼±ÅÃµÊ setfont È£Ãâ ", "\Alllog.txt") SetFont() End Sub Private Sub UpdateFontSize(ByVal newsize As Integer, Optional ByVal Src As MyControlOLEDBv2.MyLabel = Nothing) ' AddLog(Admin, "updatefont : ", "\Alllog.txt") Dim A As Font For Each Tobj As MyControlOLEDBv2.MyLabel In SelCon A = New Font(Tobj.MyFont.FontFamily, newsize, FontStyle.Regular, GraphicsUnit.Point) Tobj.MyFont = A Next Me.SetFont() End Sub Public Sub CtrSize(ByVal vertical As Boolean, ByVal offset As Short) If SelCon Is Nothing OrElse SelCon.Count < 1 Then Exit Sub For Each sender As MyControlOLEDBv2.MyLabel In SelCon If vertical Then '//»óÇÏ If My.Computer.Keyboard.CtrlKeyDown Then If offset < 0 Then sender.Àå³ôÀÌ -= 10 Else sender.Àå³ôÀÌ += 10 End If Else sender.Àå³ôÀÌ += offset End If Else '//Á¿ì If My.Computer.Keyboard.CtrlKeyDown Then If offset < 0 Then sender.ÀåÆò -= 10 Else sender.ÀåÆò += 10 End If Else sender.ÀåÆò += offset End If End If Next Me.preview_window() End Sub Public Sub LOAD_STYLEC(ByVal StyleName As String, ByVal Div As String) '//±âŸ½ºÅ¸ÀÏÀº ºóµµ°¡ ÀûÀ¸´Ï ÆÄÀÏ¿¡¼­ ºÒ·¯¿À±â·ÎÇÑ´Ù.;;¸Þ¸ð¸®´Â ½ÈŸ. Dim Arinini As New MyINI2(FileC) If Not IO.File.Exists(FileC) Then MsgBox("±âŸ½ºÅ¸Àϼ³Á¤ ÆÄÀÏÀÌ Á¸ÀçÇÏÁö ¾Ê½À´Ï´Ù\n\n°ü¸®ÀÚ¿¡ ¹®ÀÇÇϼ¼¿ä", MsgBoxStyle.Critical, "¿À·ù") Return End If Dim pos(), font(), visible As String '//±¸Àü»ê¹øÈ£¸¦ ±¸ÇöÇØº»´Ù. Dim Tobj As MyControlOLEDBv2.MyLabel For i As Integer = 0 To Me.AllLabels.GetUpperBound(0) Tobj = Me.AllLabels(i).ctl Try If Div.ToUpper = "Z" Then '//¸ðµç¾ÆÀÌÅÛÀ» °¡Á®¿À°í pos = Arinini.Read(StyleName, Tobj.Name & "pos").Split(",") font = Arinini.Read(StyleName, Tobj.Name & "font").Trim(Chr(0)).Split(",") visible = Arinini.Read(StyleName, Tobj.Name & "visible") '//»óŸ¦ Àо ¹Ù·Î Àû¿ëÇÑ´Ù. Tobj.Location = New Point(pos(0), pos(1)) Tobj.Size = New Size(pos(2), pos(3)) Tobj.MyFont = New Font(font(0), font(1), IIf(font(3).ToUpper = "TRUE", FontStyle.Bold, FontStyle.Regular), GraphicsUnit.Point) Tobj.ÀåÆò = font(5) Tobj.Àå³ôÀÌ = font(6) Tobj.°ø¹é = Arinini.Read(StyleName, Tobj.Name & "space", 0) Tobj.Visible = CType(visible, Boolean) Else 'À̰÷¿¡ O°¡¿Ã°ÍÀÌ´Ù. If Tobj.Name.ToUpper.StartsWith(Div.ToUpper()) Then pos = Arinini.Read(StyleName, Tobj.Name & "pos").Split(",") font = Arinini.Read(StyleName, Tobj.Name & "font").Trim(Chr(0)).Split(",") visible = Arinini.Read(StyleName, Tobj.Name & "visible") '//»óŸ¦ Àо ¹Ù·Î Àû¿ëÇÑ´Ù. Tobj.Location = New Point(pos(0), pos(1)) Tobj.Size = New Size(pos(2), pos(3)) Tobj.MyFont = New Font(font(0), font(1), IIf(font(3).ToUpper = "TRUE", FontStyle.Bold, FontStyle.Regular), GraphicsUnit.Point) Tobj.ÀåÆò = font(5) Tobj.Àå³ôÀÌ = font(6) Tobj.°ø¹é = Arinini.Read(StyleName, Tobj.Name & "space", 0) Tobj.Visible = CType(visible, Boolean) End If End If Catch ex As Exception AddLog(Admin, "LOAD_STYLE_CUSTOM ¿À·ù:" & ex.Message.ToString, "LOAD_STYLEC") End Try Next NOTICE(StyleName & "±âŸ½ºÅ¸ÀÏÀ» ºÒ·¯¿Ô½À´Ï´Ù.", Me.lb_msg) Me.preview_window() End Sub Public Sub SAVE_STYLEC(ByVal stylename As String, ByVal div As String) '//±âŸ½ºÅ¸ÀÏ ÀúÀåÇÑ´Ù. Dim Arinini As New MyINI2(FileC) '//ÇöÀç ¼±ÅÃµÈ ½ºÅ¸ÀÏÀ» ÀúÀåÇÕ´Ï´Ù. Arinini.Write(stylename, "DESC", stylename) Dim Tobj As MyControlOLEDBv2.MyLabel For i As Integer = 0 To Me.AllLabels.GetUpperBound(0) Tobj = Me.AllLabels(i).ctl If Not Tobj.Name.ToUpper.StartsWith(div.ToUpper) Then Continue For Arinini.Write(stylename, Tobj.Name & "pos", Tobj.Left & "," & Tobj.Top & "," & Tobj.Width & "," & Tobj.Height) Arinini.Write(stylename, Tobj.Name & "font", Tobj.MyFont.Name & "," & Tobj.MyFont.Size & "," & Tobj.MyFont.Underline & "," & Tobj.MyFont.Bold & "," & Tobj.MyFont.Italic & "," & Tobj.ÀåÆò & "," & Tobj.Àå³ôÀÌ) Arinini.Write(stylename, Tobj.Name & "visible", Tobj.Visible) Arinini.Write(stylename, Tobj.Name & "space", Tobj.°ø¹é) Next NOTICE("±âŸ½ºÅ¸ÀÏÀ» ÀúÀåÇß½À´Ï´Ù", Me.lb_msg) End Sub Private Sub Button30_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button30.Click Me.CtrSize(False, -5) End Sub Private Sub Button29_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button29.Click Me.CtrSize(False, 5) End Sub Private Sub Button32_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button32.Click Me.CtrSize(True, -5) End Sub Private Sub Button31_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button31.Click Me.CtrSize(True, 5) End Sub Private Sub Button7_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button7.Click Me.CtrPos(False, -5) End Sub Private Sub Button6_Click_1(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button6.Click Me.CtrPos(False, 5) End Sub Private Sub Button27_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button27.Click Me.CtrPos(True, -5) End Sub Private Sub Button26_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button26.Click Me.CtrPos(True, 5) End Sub Private Sub BindingNavigatorPositionItem_KeyUp(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles BindingNavigatorPositionItem.KeyUp '//ÇöÀçÀ§Ä¡¿¡¼­ ¿£ÅÍÄÖÀ»°æ¿ì µ¥ÀÌÅͺ£À̽º À§Ä¡°ªÀ» º¯°æÇÑ´Ù.(position) If e.KeyCode = Keys.Enter Then If IsNumeric(Me.BindingNavigatorPositionItem.Text) Then Me.GeTviewData(Me.BindingNavigatorPositionItem.Text - 1, True) End If End Sub Private Sub showcnt(ByVal cnt1 As Integer, ByVal cnt2 As Integer, Optional ByVal tag As String = "") Me.lb_msg.Text = cnt1 & "/" & cnt2 & Space(1) & tag My.Application.DoEvents() End Sub Private Sub NPartternCheck() Dim ¹øÈ£ÆÐÅϰ˻ç As Integer = 0 '//ÆÐÅϰ˻ç½ÃÀÛ ' Me.PictureBox1.Image = Image.FromFile(My.Application.Info.DirectoryPath & "\image\start.png") For i As Integer = Me.TB_Pattern_Start.Text To Me.TB_Pattern_End.Text ' If chkFlag Then Exit For showcnt(i, Me.TB_Pattern_End.Text) Me.TB_Pattern_Start.Text = i ¹øÈ£ÆÐÅϰ˻ç = ChkNumPattern(i) ' MsgBox(¹øÈ£ÆÐÅϰ˻ç) If ¹øÈ£ÆÐÅϰ˻ç = 0 Then '0Àº µÑ´Ù ¾ø´Ù´Â ¶æÀÌ´Ù // 3Àº.. ¹®ÀÚ¿Í ±æÀ̰¡ µ¿½Ã¿¡ Á¸ÀçÇÑ´Ù´Â ¶æÀÌ´Ù. NOTICE("ÁÙ¹øÈ£=" & i + 1 & "¹ø ¹®ÀÚ,±æÀÌ ÆÐÅÏÀÌ Á¸ÀçÇÏÁö ¾Ê½À´Ï´Ù(" & ¹øÈ£ÆÐÅϰ˻ç & ")", Me.lb_msg) My.Computer.Audio.Play(My.Application.Info.DirectoryPath & "\sound\ding.wav", AudioPlayMode.Background) 'If MsgBox("Sdf", MsgBoxStyle.OkCancel) = MsgBoxResult.Ok Then Me.BindingSource1.Position = i Exit For End If Next If Me.TB_Pattern_Start.Text = Me.TB_Pattern_End.Text Then '//¿Ï·áµÇ¾ú´Ù¸é My.Computer.Audio.Play(My.Application.Info.DirectoryPath & "\sound\notify.wav", AudioPlayMode.Background) NOTICE("ÆÐÅϰ˻簡 ¿Ï·áµÇ¾ú½À´Ï´Ù", Me.lb_msg) End If Me.bt_chkpattern.Text = "½ÃÀÛ(&S)" End Sub Private Sub tb_printrange_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles tb_printrange.TextChanged If Me.rad_print_repeat.Checked = False Then Me.rad_print_area.Checked = True End Sub '--------------------------------- Public Function PARSE_¹øÈ£(ByVal srcsTR As String, ByVal jisun As Boolean) As Boolean 'Me.CLEAR_ITEM("X") Dim Log As String = "\Parse_¹øÈ£.txt" If srcsTR = "" OrElse Not Me.cb_jjnum.Checked Then Me.CLEAR_ITEM(SÀüÁÖ¹øÈ£) Me.CLEAR_ITEM(SÀüÁÖ¹øÈ£ÇÑÁÙ) AddLog(Admin, "¹øÈ£¿¡´ëÇÑ ³»¿ëÀÌ ¾ø°Å³ª ¹øÈ£¸¦ Ç¥½ÃÇÏÁö ¾Êµµ·Ï üũµÇ¾îÀÖ½À´Ï´Ù", Log) Return False End If '//Áö¼±ÁÖÀÇ °æ¿ì¸¦ ÆÇ´ÜÇÑ´Ù. Áö¼±ÁÖ´Â Áö¼±ÁÖ(µðºñÀÇÀμâÄ÷³)°¡ üũµÇ¾îÀÖ°í cb.jisun ÀÌ Ã¼Å©µÇ¾îÀÖÀ¸¸é ¹øÈ£´Â º¸ÀÌÁö ¾Ê°ÔÇÑ´Ù. If jisun AndAlso Me.cmb_jisun.SelectedIndex > 0 Then Me.CLEAR_ITEM(SÀüÁÖ¹øÈ£) AddLog(Admin, "Áö¼±ÁÖ°¡ Àû¿ëµÇ¸ç ÇöÀçµ¥ÀÌÅÍ´Â Áö¼±ÁÖÀ̹ǷΠ¹øÈ£¸¦ Ç¥½ÃÇÏÁö ¾Ê½À´Ï´Ù", Log) If Me.cmb_jisun.SelectedIndex = 1 Then '//ÇÑÁÙÀ» Ç¥½ÃÇØ¾ßÇÑ´Ù. Me.SÀüÁÖ¹øÈ£ÇÑÁÙ(0).MyText = srcsTR Me.SÀüÁÖ¹øÈ£ÇÑÁÙ(0).Visible = True ' --------------------------------------------------- Else ' ---------------------------------------------- Me.SÀüÁÖ¹øÈ£ÇÑÁÙ(0).Visible = False End If Return False Else ''//ÇÑÁÙÀÌ ¹Ì¹ÌÇ¥½ÃµÈ »óÅ¿³´Âµ¥ ¾Æ·§ÁÙÀ̾øÀ¸¸é °Ô¼Ó Ç¥½ÃµÇ¾î¹ö¸°Çö»ó¹ß»ý 20080220 Me.SÀüÁÖ¹øÈ£ÇÑÁÙ(0).Visible = False End If Dim Wlen As Short = srcsTR.Length Dim SepPos As Short = srcsTR.IndexOf(";") Dim SRC() As Char = srcsTR.ToCharArray AddLog(Admin, "Length=" & Wlen & " Sep=" & SepPos, Log) Return True End Function Public Function PARSE_¹øÈ£ÆÐÅÏ(ByVal SRCSTR As String) As Integer Dim Wlen As Short = SRCSTR.Length : If Wlen <= 0 Then Return 3 '//¾ø´Â ±Û±Í°¡ ¿ÓÀ»¶§ ÅÏÇØ¹ö¸°´Ù. Dim SRC() As Char = SRCSTR.ToCharArray Dim Log As String = "\Parse_¹øÈ£ÆÐÅÏ.txt" Dim SepPos As Short = SRCSTR.IndexOf(";") Dim retval As Integer = 0 ''0Àº Á¤»ó 1Àº ±æÀÌÆÐÅϾøÀ½ 2´Â 3Àº ±æÀÌ+¹®ÀÚ¾øÀ½ '//¹øÈ£´Â ±æÀÌÆÐÅÏÀ» ÇÏÁö¾Ê°í ¹®ÀÚÆÐÅϸ¸ ÇÑ´Ù. Dim pname As String Dim Arinini As New MyINI2(DrStyle.FILE) Dim CTLPOS() As String '//À§Ä¡Á¤º¸ Dim CTLFONT() As String Dim CTLVISIBLE As Boolean Dim PATTERN As String = PATTERN_ENC(SRCSTR) Dim PATTERN2 As String = PATTERN_ENC(SRCSTR, True) Dim TOBJ As MyControlOLEDBv2.MyLabel Dim ºÐ¸®À妽º As Short = 0 Dim ¹øÈ£Çü½Ä As String = "999" Dim Dr() As DataRow '//HÆÐÅÏÀ» °Ë»çÇÑ´Ù. pname = "JJNUMPATTERNII" & PATTERN2 Dr = DtPattern.Select("NAME = '" & pname & "X1POS'") Dim FindHpattern As Boolean = False If Dr.GetUpperBound(0) = 0 Then '//µ¥ÀÌÅͰ¡ Á¸ÀçÇϹǷΠ¸ðµÎ Àû¿ëÀ» ÇÑ´Ù. FindHpattern = True AddLog(Admin, "¹øÈ£ÆÐÅÏH°¨Áö(¹®ÀÚ) : ±æÀÌ=" & Wlen & " ¹®ÀÚ¿­=" & SRCSTR & " ÆÐÅÏ=" & PATTERN2, Log) '//µ¥ÀÌÅÍ´Â ÃÖÁ¾ÀûÀ¸·Î ¹øÈ£Çü½Ä¿¡¼­ º¸³½´Ù. ºÐ¸®À妽º = Arinini.Read(pname, "nseparate", 0) ¹øÈ£Çü½Ä = Arinini.Read(pname, "LineType", "999") For i As Integer = 0 To Me.SÀüÁÖ¹øÈ£.GetUpperBound(0) TOBJ = Me.SÀüÁÖ¹øÈ£(i) TOBJ.Tag = "" '//±âÁ¸Å±׸¦ »èÁ¦ÇÑ´Ù. Try '//»óŸ¦ Àо ¹Ù·Î Àû¿ëÇÑ´Ù. Dr = DtPattern.Select("NAME = '" & pname & TOBJ.Name & "POS'") If Dr.GetUpperBound(0) = 0 Then CTLPOS = Dr(0)(1).ToString.Split(",") TOBJ.Location = New Point(CTLPOS(0), CTLPOS(1)) TOBJ.Size = New Size(CTLPOS(2), CTLPOS(3)) End If Dr = DtPattern.Select("NAME = '" & pname & TOBJ.Name & "FONT'") If Dr.GetUpperBound(0) = 0 Then CTLFONT = Dr(0)(1).ToString.Split(",") TOBJ.MyFont = New Font(CTLFONT(0), CTLFONT(1), IIf(CTLFONT(3).ToUpper = "TRUE", FontStyle.Bold, FontStyle.Regular), GraphicsUnit.Point) TOBJ.ÀåÆò = CTLFONT(5) TOBJ.Àå³ôÀÌ = CTLFONT(6) End If Dr = DtPattern.Select("NAME = '" & pname & TOBJ.Name & "VISIBLE'") If Dr.GetUpperBound(0) = 0 Then CTLVISIBLE = Dr(0)(1).ToString TOBJ.Visible = CType(CTLVISIBLE, Boolean) End If Dr = DtPattern.Select("NAME = '" & pname & TOBJ.Name & "SPACE'") If Dr.GetUpperBound(0) = 0 Then TOBJ.°ø¹é = Dr(0)(1).ToString End If TOBJ.Tag = "C" Catch ex As Exception AddLog(Admin, "¹®ÀÚÆÐÅÏ(H)¿À·ù=" & ex.Message.ToString, Log) End Try Next Else '//H¹®ÀÚ°¡ ¾øÀ¸¹Ç·Î ÀÏ¹Ý ¹®ÀÚÆÐÅÏÀ» ÃßÃâÇÑ´Ù. pname = "JJNUMPATTERNII" & PATTERN Dr = DtPattern.Select("NAME = '" & pname & "X1POS'") If Dr.GetUpperBound(0) = 0 Then '//µ¥ÀÌÅͰ¡ Á¸ÀçÇϹǷΠ¸ðµÎ Àû¿ëÀ» ÇÑ´Ù. AddLog(Admin, "¹øÈ£ÆÐÅϰ¨Áö(¹®ÀÚ) : ±æÀÌ=" & Wlen & " ¹®ÀÚ¿­=" & SRCSTR & " ÆÐÅÏ=" & PATTERN, Log) '//µ¥ÀÌÅÍ´Â ÃÖÁ¾ÀûÀ¸·Î ¹øÈ£Çü½Ä¿¡¼­ º¸³½´Ù. ºÐ¸®À妽º = Arinini.Read(pname, "nseparate", 0) ¹øÈ£Çü½Ä = Arinini.Read(pname, "LineType", "999") For i As Integer = 0 To Me.SÀüÁÖ¹øÈ£.GetUpperBound(0) TOBJ = Me.SÀüÁÖ¹øÈ£(i) TOBJ.Tag = "" '//±âÁ¸Å±׸¦ »èÁ¦ÇÑ´Ù. Try '//»óŸ¦ Àо ¹Ù·Î Àû¿ëÇÑ´Ù. Dr = DtPattern.Select("NAME = '" & pname & TOBJ.Name & "POS'") If Dr.GetUpperBound(0) = 0 Then CTLPOS = Dr(0)(1).ToString.Split(",") TOBJ.Location = New Point(CTLPOS(0), CTLPOS(1)) TOBJ.Size = New Size(CTLPOS(2), CTLPOS(3)) End If Dr = DtPattern.Select("NAME = '" & pname & TOBJ.Name & "FONT'") If Dr.GetUpperBound(0) = 0 Then CTLFONT = Dr(0)(1).ToString.Split(",") TOBJ.MyFont = New Font(CTLFONT(0), CTLFONT(1), IIf(CTLFONT(3).ToUpper = "TRUE", FontStyle.Bold, FontStyle.Regular), GraphicsUnit.Point) TOBJ.ÀåÆò = CTLFONT(5) TOBJ.Àå³ôÀÌ = CTLFONT(6) End If Dr = DtPattern.Select("NAME = '" & pname & TOBJ.Name & "VISIBLE'") If Dr.GetUpperBound(0) = 0 Then CTLVISIBLE = Dr(0)(1).ToString TOBJ.Visible = CType(CTLVISIBLE, Boolean) End If Dr = DtPattern.Select("NAME = '" & pname & TOBJ.Name & "SPACE'") If Dr.GetUpperBound(0) = 0 Then TOBJ.°ø¹é = Dr(0)(1).ToString End If TOBJ.Tag = "C" Catch ex As Exception AddLog(Admin, "¹®ÀÚÆÐÅÏ¿À·ù=" & ex.Message.ToString, Log) End Try Next Else AddLog(Admin, "¹®ÀÚÆÐÅϺÒÀÏÄ¡ ±æÀÌ=" & Wlen & " ¹®ÀÚ¿­=" & SRCSTR & " ÆÐÅÏ=" & PATTERN, Log) retval += 2 '//ÆÐÅÏÀÌ ¾øÀ¸¹Ç·Î ¹Ù·Î ³Ñ±ä´Ù. End If End If If retval = 2 Then '//¹®ÀÚÆÐÅÏÀÌ ¾øÀ»°æ¿ì¿¡¸¸ ±æÀÌÆÐÅÏÀ» È®ÀÎÇÑ´Ù. '//±æÀÌÆÐÅÏ È®ÀÎ pname = "JJNUMPATTERN" & Wlen Dr = DtPattern.Select("NAME = '" & pname & "X1POS'") If Dr.GetUpperBound(0) = 0 Then '//µ¥ÀÌÅͰ¡ Á¸ÀçÇϹǷΠ¸ðµÎ Àû¿ëÀ» ÇÑ´Ù. AddLog(Admin, "¹øÈ£ÆÐÅϰ¨Áö(±æÀÌ) : ±æÀÌ=" & Wlen & " ¹®ÀÚ¿­=" & SRCSTR, Log) '//µ¥ÀÌÅÍ´Â ÃÖÁ¾ÀûÀ¸·Î ¹øÈ£Çü½Ä¿¡¼­ º¸³½´Ù. ºÐ¸®À妽º = Arinini.Read(pname, "nseparate", 0) ¹øÈ£Çü½Ä = Arinini.Read(pname, "LineType", "999") For i As Integer = 0 To Me.SÀüÁÖ¹øÈ£.GetUpperBound(0) TOBJ = Me.SÀüÁÖ¹øÈ£(i) TOBJ.Tag = "" '//±âÁ¸Å±׸¦ »èÁ¦ÇÑ´Ù. Try '//»óŸ¦ Àо ¹Ù·Î Àû¿ëÇÑ´Ù. Dr = DtPattern.Select("NAME = '" & pname & TOBJ.Name & "POS'") If Dr.GetUpperBound(0) = 0 Then CTLPOS = Dr(0)(1).ToString.Split(",") TOBJ.Location = New Point(CTLPOS(0), CTLPOS(1)) TOBJ.Size = New Size(CTLPOS(2), CTLPOS(3)) End If Dr = DtPattern.Select("NAME = '" & pname & TOBJ.Name & "FONT'") If Dr.GetUpperBound(0) = 0 Then CTLFONT = Dr(0)(1).ToString.Split(",") TOBJ.MyFont = New Font(CTLFONT(0), CTLFONT(1), IIf(CTLFONT(3).ToUpper = "TRUE", FontStyle.Bold, FontStyle.Regular), GraphicsUnit.Point) TOBJ.ÀåÆò = CTLFONT(5) TOBJ.Àå³ôÀÌ = CTLFONT(6) End If Dr = DtPattern.Select("NAME = '" & pname & TOBJ.Name & "VISIBLE'") If Dr.GetUpperBound(0) = 0 Then CTLVISIBLE = Dr(0)(1).ToString TOBJ.Visible = CType(CTLVISIBLE, Boolean) End If Dr = DtPattern.Select("NAME = '" & pname & TOBJ.Name & "SPACE'") If Dr.GetUpperBound(0) = 0 Then TOBJ.°ø¹é = Dr(0)(1).ToString End If TOBJ.Tag &= "L" Catch ex As Exception AddLog(Admin, "±æÀÌ ÆÐÅÏ¿À·ù=" & ex.Message.ToString, Log) End Try Next Else AddLog(Admin, "±æÀÌÆÐÅϺÒÀÏÄ¡ ±âº»½ºÅ¸ÀÏ º¹¿ø ±æÀÌ=" & Wlen & " ¹®ÀÚ¿­=" & SRCSTR, Log) retval += 1 '//¾ø´Ù End If End If Me.cmb_sep.SelectedIndex = ºÐ¸®À妽º If ¹øÈ£Çü½Ä = "999" Then '//ÆÐÅÏÀ̾ø¾ú´Ù´Â ¸»ÀÌ´Ù ¹øÈ£Çü½ÄÀ» ¾î´ÀÁ¤µµ ¸ÂÃçÁØ´Ù. 'MsgBox("¹øÈ£Çü½ÄÀÌ ¾ø¾î¼­ ¼ÂÆÃÇÕ´Ï´Ù(" & ¹øÈ£ & "/" & ¹øÈ£.Length) If ¹øÈ£.Length <= 12 Then If ¹øÈ£.Length <= 4 Then ¹øÈ£Çü½Ä = ¹øÈ£.Length & "00" ElseIf ¹øÈ£.Length <= 8 Then ¹øÈ£Çü½Ä = "4" & CStr(¹øÈ£.Length - 4) & "0" Else ¹øÈ£Çü½Ä = "44" & CStr(¹øÈ£.Length - 8) End If Else '//12ÀÚ¸®ÀÌ»óÀ̹ǷΠ¾î‰F°Ô Âɰ³¾ßÇÒÁö 3À¸·Î³ª´²¼­ ..int ´ëÀÔÀ» ÇÏÀÚ ¹øÈ£Çü½Ä = CStr(Int(¹øÈ£.Length / 3)) & CStr(Int(¹øÈ£.Length / 3)) & CStr(¹øÈ£.Length - Int(¹øÈ£.Length / 3) * 2) End If 'MsgBox("ÃÖÁ¾¹øÈ£=" & ¹øÈ£Çü½Ä) End If Me.tb_ntype.Text = ¹øÈ£Çü½Ä ¹øÈ£Çü½ÄÁöÁ¤(Me.tb_ntype.Text) '//¹øÈ£Çü½ÄÀ» °»½ÅÇØÁØ´Ù. Return retval '// 0ÀÌ ¸®ÅϵɰÍÀÌ´Ù. ÆÐÅÏÀÌ ¸ðµÎ Á¤»óÀ̶õ ¶æÀÌ´Ù End Function Private Function SetXdata(ByVal idx As Short, ByRef Src() As Char) As MyControlOLEDBv2.MyLabel If idx > Src.GetUpperBound(0) Then Return Nothing Dim A As MyControlOLEDBv2.MyLabel = Me.SÀüÁÖ¹øÈ£(0) For i As Integer = 0 To Me.SÀüÁÖ¹øÈ£.GetUpperBound(0) If Me.SÀüÁÖ¹øÈ£(i).MyText = "" Then Me.SÀüÁÖ¹øÈ£(i).MyText = Src(idx) If i = 11 Then A = Nothing Else A = Me.SÀüÁÖ¹øÈ£(i + 1) End If Exit For End If Next Return A End Function Private Function GetnextCtl(ByVal currCtl As MyControlOLEDBv2.MyLabel) As MyControlOLEDBv2.MyLabel Dim a As MyControlOLEDBv2.MyLabel = Nothing Select Case currCtl.Name.ToUpper Case "X1" a = Me.SÀüÁÖ¹øÈ£(1) ' X2 Case "X2" a = Me.SÀüÁÖ¹øÈ£(2) 'X3 Case "X3" a = Me.SÀüÁÖ¹øÈ£(3) 'x4 Case "X4" a = Me.SÀüÁÖ¹øÈ£(4) 'x5 Case "X5" a = Me.SÀüÁÖ¹øÈ£(5) ' x6 Case "X6" a = Me.SÀüÁÖ¹øÈ£(6) 'x7 Case "X7" a = Me.SÀüÁÖ¹øÈ£(7) ' x8 Case "X8" a = Me.SÀüÁÖ¹øÈ£(8) 'x9 Case "X9" a = Me.SÀüÁÖ¹øÈ£(9) 'x10 Case "X10" a = Me.SÀüÁÖ¹øÈ£(10) ' x11 Case "X11" a = Me.SÀüÁÖ¹øÈ£(11) 'x12 Case "X12" a = Me.SÀüÁÖ¹øÈ£(12) 'X13 Case "X13" a = Me.SÀüÁÖ¹øÈ£(13) 'x14 Case "X14" a = Me.SÀüÁÖ¹øÈ£(14) 'x15 Case "X15" a = Me.SÀüÁÖ¹øÈ£(15) ' x16 Case "X16" a = Me.SÀüÁÖ¹øÈ£(16) 'x17 Case "X17" a = Me.SÀüÁÖ¹øÈ£(17) ' x18 Case "X18" a = Me.SÀüÁÖ¹øÈ£(18) 'x19 Case "X19" a = Me.SÀüÁÖ¹øÈ£(19) 'x20 Case "X20" a = Me.SÀüÁÖ¹øÈ£(20) ' x21 Case Else a = Nothing End Select Return a End Function Private Sub ¹øÈ£Çü½ÄÁöÁ¤°¨µ¶ÀÚ(Optional ByVal msg As String = "999") 'MsgBox("¹øÈ£Çü½ÄÁöÁ¤ : " & ¹øÈ£, MsgBoxStyle.Information, msg) '//ÁöÁ¤µÈ ¹øÈ£Çü½ÄÀ¸·Î ÀüºÎ¹øÈ£¸¦ Ç¥½ÃÇÑ´Ù. '//20070826 ¹øÈ£´Â ºÐ¸®/ÅëÇÕÀ¸·Î ±¸ºÐÇØ¼­ Ãâ·ÂÇÑ´Ù. Dim A() As Char = °¨µ¶ÀÚ.ToCharArray Dim P() As Char = msg.ToCharArray Me.CLEAR_ITEM(S°¨µ¶ÀÚ) '//12ÀÚÀÌ»óÀº °³º°À̶ó°í ÇÑ´Ù¸é ÇØ´ç¹øÈ£¸¦ ÅëÇÕÀ¸·Î º¯°æ If Me.cmb_sep.SelectedIndex = -1 OrElse (Me.cmb_sep.SelectedIndex = 1 AndAlso °¨µ¶ÀÚ.Length > 12) Then Me.cmb_sep.SelectedIndex = 2 Dim NextCtl As MyControlOLEDBv2.MyLabel = Me.S°¨µ¶ÀÚ(0) Dim CurPos As Short = 0 '//¸î¹øÂ° ÄÁÆ®·Ñ±îÁö ›§´Ù´Â Ç¥½Ã Dim CPos As Short = 0 '//Àüü¹®ÀÚÁß ¸î¹øÂ°±îÁö Çߴٴ ǥ½Ã Select Case Me.cmb_sep.SelectedIndex Case 0 '//È¥ÇÕ '//Çü½Ä¼ö°¡ 4¸¦ ³ÑÁö¾ÊÀ¸¸é °³º° ³ÑÀ»°æ¿ì ÅëÇÕÃâ·ÂÀ¸·ÎÇÑ´Ù. '//¿¬½Àµ¥ÀÌÅÍ 342 : 345 R23L1 R9 ' MsgBox("¹øÈ£Çü½Ä=" & msg & "/" & ¹øÈ£ & "/p0=" & P(0)) Me.tb_ntype.Enabled = True '//ºÐ¸®¿³À»¶§ À̰ÍÀÌ false ·Î µÈ´Ù. If CInt(P(0).ToString) <> 0 AndAlso CInt(P(0).ToString) < 5 Then '//ùÁÙ¿¡ÇØ´çÇÒ ¹®ÀÚ¸¦ ÀüºÎ °³º°·Î ³Ö´Â´Ù. ' MsgBox("1ÁÙ=" & msg & "/" & ¹øÈ£ & "/p0=" & P(0)) For i As Int16 = 0 To (CInt(P(0).ToString) - 1) '// If i <= A.GetUpperBound(0) Then '//Á¤»óÀûÀÎ ¹üÀ§ÀÇ µ¥ÀÌÅÍÀϰæ¿ì Me.S°¨µ¶ÀÚ(i).MyText = IIf(A(i) <> ";", A(i), "") '//0¹øÂ° (0,0) 'Me.SÀüÁÖ¹øÈ£(i).Visible = True 'NextCtl = SetXdata(i, A) CPos = i ' + 1 CurPos = i End If Next ElseIf CInt(P(0).ToString) > 4 Then '//ùÁÙÀÇ ¹®ÀÚ¸¦ ÅëÇÕÀ¸·ÎÇÑ´Ù. For i As Int16 = 0 To (CInt(P(0).ToString) - 1) If i <= A.GetUpperBound(0) Then '//Á¤»óÀûÀÎ ¹üÀ§ÀÇ µ¥ÀÌÅÍ Me.S°¨µ¶ÀÚ(CPos).MyText &= IIf(A(i) <> ";", A(i), "") '//0¹øÂ° (0,0) 'Me.SÀüÁÖ¹øÈ£(i).Visible = True CurPos = i 'CurPos += 1 'NextCtl.MyText &= A(i) End If Next 'NextCtl = GetnextCtl(NextCtl) 'CurPos += 1 '//¿©±â¼­ 1À̵ȴÙ. End If 'curpos ´Â ¸î¹øÂ° ¹øÈ£±îÁö Çߴٴ°ÍÀÌ´Ù(±× ´ÙÀ½¹øÈ£¸¦ °¡¸£Å²´Ù) 'cpos ´Â ¸î¹øÂ° ÄÁÆ®·Ñ±îÁö ›§´Ù´Â ¶æÀÌ´Ù. ' MsgBox("1¹øÂ°ÃâÃâ·ÂÈÄ ¸¶Áö¸·À§Ä¡°ª=" & CurPos) '//2¹øÂ°ÁÙÀ» Å×½ºÆ®ÇÑ´Ù. If CPos = 0 AndAlso Me.S°¨µ¶ÀÚ(0).MyText = "" Then '//ÄÁÆ®·Ñ¹øÈ£°¡ 0Àϰæ¿ì´Ù. ¸¸¾à °ªÀ̾øÀ¸¸é 1¹øÂ°ÁÙ¿¡¼­ ¾Æ¹«°Íµµ¾ø¾ùµû´Â¶æÀÌ´Ù. CPos = -1 End If If CInt(P(1).ToString) > 0 AndAlso CInt(P(1).ToString) < 5 Then ' MsgBox("2ÁÙ=" & msg & "/" & ¹øÈ£ & "/p0=" & P(0)) For i As Int16 = CurPos + 1 To CInt(P(0).ToString) + CInt(P(1).ToString) - 1 If i <= A.GetUpperBound(0) Then Me.S°¨µ¶ÀÚ(CPos + 1).MyText = IIf(A(i) <> ";", A(i), "") '//0¹øÂ° (0,0) CPos += 1 'Me.SÀüÁÖ¹øÈ£(i).Visible = True 'NextCtl = SetXdata(i, A) CurPos = i End If Next ElseIf CInt(P(1).ToString) > 0 Then '//ÅëÇÕÃâ·Â CPos += 1 For i As Int16 = CurPos + 1 To CInt(P(0).ToString) + CInt(P(1).ToString) - 1 If i <= A.GetUpperBound(0) Then Me.S°¨µ¶ÀÚ(CPos).MyText &= IIf(A(i) <> ";", A(i), "") '//0¹øÂ° (0,0) 'Me.SÀüÁÖ¹øÈ£(CPos).Visible = True 'NextCtl.MyText &= A(i) CurPos = i End If Next 'NextCtl = GetnextCtl(NextCtl) End If ' MsgBox("2¹øÂ°ÃâÃâ·ÂÈÄ ¸¶Áö¸·À§Ä¡°ª=" & CurPos) If CInt(P(2).ToString) > 0 AndAlso CInt(P(2).ToString) < 5 Then ' MsgBox("3ÁÙ°³º°=" & msg & "/" & ¹øÈ£ & "/p0=" & P(0)) For i As Int16 = CurPos + 1 To CInt(P(0).ToString) + CInt(P(1).ToString) + CInt(P(2).ToString) - 1 If i <= A.GetUpperBound(0) Then ' MsgBox(i & "/" & A(i)) Me.S°¨µ¶ÀÚ(CPos + 1).MyText = IIf(A(i) <> ";", A(i), "") '//0¹øÂ° (0,0) CPos += 1 'Me.SÀüÁÖ¹øÈ£(i).Visible = True 'NextCtl = SetXdata(i, A) CurPos = i End If Next ElseIf CInt(P(2).ToString) > 0 Then '//ÅëÇÕÃâ·Â 'MsgBox("3ÁÙÅëÇÕ=" & msg & "/" & ¹øÈ£ & "/p0=" & P(0)) CPos += 1 For i As Int16 = CurPos + 1 To CInt(P(0).ToString) + CInt(P(1).ToString) + CInt(P(2).ToString) - 1 If i <= A.GetUpperBound(0) Then Me.S°¨µ¶ÀÚ(CPos).MyText &= IIf(A(i) <> ";", A(i), "") '//0¹øÂ° (0,0) 'Me.SÀüÁÖ¹øÈ£(CPos).Visible = True 'NextCtl.MyText &= A(i) CurPos = i End If Next 'NextCtl = GetnextCtl(NextCtl) End If ' MsgBox("3¹øÂ°ÃâÃâ·ÂÈÄ ¸¶Áö¸·À§Ä¡°ª=" & CurPos) Case 1 '//ºÐ¸® Me.tb_ntype.Enabled = False For i As Int16 = 0 To A.GetUpperBound(0) '//°³º° 12°³ÀÇ ¿­¿¡ µ¥ÀÌÅ͸¦ Ãâ·ÂÇÑ´Ù. Me.S°¨µ¶ÀÚ(i).MyText = IIf(A(i) <> ";", A(i), "") Next Case 2 '//ÅëÇÕ Me.tb_ntype.Enabled = True For i As Integer = 0 To A.GetUpperBound(0) '//¸ðµç ¹®ÀÚ¿­À» Áý¾î³Ö´Â´Ù ±æÀ̰¡ ¸ðÀÚ¶ó¸é Áß°£¿¡ ¾ø¾îÁø´Ù. If i <= CInt(P(0).ToString) - 1 Then Me.S°¨µ¶ÀÚ(0).MyText &= IIf(A(i) <> ";", A(i), "") ElseIf i <= (CInt(P(0).ToString) + CInt(P(1).ToString) - 1) Then Me.S°¨µ¶ÀÚ(1).MyText &= IIf(A(i) <> ";", A(i), "") Else Me.S°¨µ¶ÀÚ(2).MyText &= IIf(A(i) <> ";", A(i), "") End If Next End Select For i As Integer = 0 To Me.S°¨µ¶ÀÚ.GetUpperBound(0) Me.S°¨µ¶ÀÚ(i).Visible = IIf(Me.S°¨µ¶ÀÚ(i).MyText = "", False, True) Next End Sub Private Sub ¹øÈ£Çü½ÄÁöÁ¤(Optional ByVal msg As String = "999") 'MsgBox("¹øÈ£Çü½ÄÁöÁ¤ : " & ¹øÈ£, MsgBoxStyle.Information, msg) '//ÁöÁ¤µÈ ¹øÈ£Çü½ÄÀ¸·Î ÀüºÎ¹øÈ£¸¦ Ç¥½ÃÇÑ´Ù. '//20070826 ¹øÈ£´Â ºÐ¸®/ÅëÇÕÀ¸·Î ±¸ºÐÇØ¼­ Ãâ·ÂÇÑ´Ù. Dim A() As Char = ¹øÈ£.ToCharArray Dim P() As String If msg.IndexOf(",") = -1 Then '//±¸¹öÁ¯ 140702 Dim pp As New List(Of String) For Each cc As Char In msg.ToCharArray pp.Add(cc) Next P = pp.ToArray() Else P = msg.Split(",") End If Me.CLEAR_ITEM(SÀüÁÖ¹øÈ£) '//12ÀÚÀÌ»óÀº °³º°À̶ó°í ÇÑ´Ù¸é ÇØ´ç¹øÈ£¸¦ È¥ÇÕÀ¸·Î ¹Ù²Û´Ù. If Me.cmb_sep.SelectedIndex = -1 OrElse (Me.cmb_sep.SelectedIndex = 1 AndAlso ¹øÈ£.Length > 30) Then Me.cmb_sep.SelectedIndex = 0 Dim NextCtl As MyControlOLEDBv2.MyLabel = Me.SÀüÁÖ¹øÈ£(0) Dim CurPos As Short = 0 '//¸î¹øÂ° ÄÁÆ®·Ñ±îÁö ›§´Ù´Â Ç¥½Ã Dim CPos As Short = 0 '//Àüü¹®ÀÚÁß ¸î¹øÂ°±îÁö Çߴٴ ǥ½Ã Dim Limit(P.GetUpperBound(0)) As Short '//°¢¹è¿­º° ÇѰè¼ýÀÚ For i As Short = 0 To P.GetUpperBound(0) If i = 0 Then Limit(i) = CInt(P(i).ToString) Else Limit(i) = Limit(i - 1) + CInt(P(i).ToString) End If 'MsgBox("ÇѰ԰ª : " & i & " °ª=" & Limit(i)) Next Select Case Me.cmb_sep.SelectedIndex Case 0 '//È¥ÇÕ '//Çü½Ä¼ö°¡ 4¸¦ ³ÑÁö¾ÊÀ¸¸é °³º° ³ÑÀ»°æ¿ì ÅëÇÕÃâ·ÂÀ¸·ÎÇÑ´Ù. '//¿¬½Àµ¥ÀÌÅÍ 3442 : 345 R23L1 R932 'MsgBox("¹øÈ£Çü½Ä=" & msg & "/" & ¹øÈ£ & "/p0=" & P(0)) Me.tb_ntype.Enabled = True '//ºÐ¸®¿³À»¶§ À̰ÍÀÌ false ·Î µÈ´Ù. Dim OK As Short = -1 '//¿Ï·á ¹øÈ£Çü½Ä ¹è¿­°ª Dim »ç¿ëÇÑÄÁÆ®·ÑÀ§Ä¡ As Short = -1 Dim RES As Boolean = False For i As Integer = 0 To A.GetUpperBound(0) If CInt(P(OK + 1).ToString) <= 4 Then '//°³º°·Î³Ö´Â´Ù If i + 1 < Limit(OK + 1) Then »ç¿ëÇÑÄÁÆ®·ÑÀ§Ä¡ += 1 Me.SÀüÁÖ¹øÈ£(»ç¿ëÇÑÄÁÆ®·ÑÀ§Ä¡).MyText &= IIf(A(i) <> ";", A(i), "") ElseIf i + 1 = Limit(OK + 1) Then OK += 1 : If OK > Limit.GetUpperBound(0) Then Exit For »ç¿ëÇÑÄÁÆ®·ÑÀ§Ä¡ += 1 Me.SÀüÁÖ¹øÈ£(»ç¿ëÇÑÄÁÆ®·ÑÀ§Ä¡).MyText &= IIf(A(i) <> ";", A(i), "") End If Else '//4º¸´ÙÅ©´Ù¸é ÇØ´ç ok°¡ ²ö³¯¶§±îÁö ÇѰ³ÀÇ ÄÁÆ®·Ñ¿¡ ³Ö´Â´Ù. If RES = False Then »ç¿ëÇÑÄÁÆ®·ÑÀ§Ä¡ += 1 RES = True End If If i + 1 < Limit(OK + 1) Then Me.SÀüÁÖ¹øÈ£(»ç¿ëÇÑÄÁÆ®·ÑÀ§Ä¡).MyText &= IIf(A(i) <> ";", A(i), "") ElseIf i + 1 = Limit(OK + 1) Then Me.SÀüÁÖ¹øÈ£(»ç¿ëÇÑÄÁÆ®·ÑÀ§Ä¡).MyText &= IIf(A(i) <> ";", A(i), "") OK += 1 : If OK + 1 > Limit.GetUpperBound(0) Then Exit For RES = False End If End If Next Case 1 '//ºÐ¸® Me.tb_ntype.Enabled = False For i As Int16 = 0 To A.GetUpperBound(0) '//°³º° 12°³ÀÇ ¿­¿¡ µ¥ÀÌÅ͸¦ Ãâ·ÂÇÑ´Ù.(30°³·Î ´Ã·ÇÀ¸´Ï ÃæºÐÇÒ°ÍÀÌ´Ù) Me.SÀüÁÖ¹øÈ£(i).MyText = IIf(A(i) <> ";", A(i), "") Next Case 2 '//ÅëÇÕ Me.tb_ntype.Enabled = True Dim OK As Short = -1 '//¿Ï·á ¹øÈ£Çü½Ä ¹è¿­°ª For i As Integer = 0 To A.GetUpperBound(0) If i < Limit(OK + 1) Then Me.SÀüÁÖ¹øÈ£(OK + 1).MyText &= IIf(A(i) <> ";", A(i), "") ElseIf i = Limit(OK + 1) Then OK += 1 : If OK + 1 > Limit.GetUpperBound(0) Then Exit For Me.SÀüÁÖ¹øÈ£(OK + 1).MyText &= IIf(A(i) <> ";", A(i), "") End If Next End Select For i As Integer = 0 To Me.SÀüÁÖ¹øÈ£.GetUpperBound(0) Me.SÀüÁÖ¹øÈ£(i).Visible = IIf(Me.SÀüÁÖ¹øÈ£(i).MyText = "", False, True) Next End Sub Public Function PARSE_º»ÁÖ(ByVal SRCNUM As Integer, ByVal srcstr As String) As Boolean '/¼±·Î¸íÀÇ ±æÀÌ´Â ¿¹ÃøµÇÁö ¾Ê´Â´Ù µ¿Àû ÄÁÆ®·Ñ »ý¼ºÀ» »ç¿ëÇÑ´Ù. ' MsgBox("PARSET_°ü¸®±¸") Me.CLEAR_ITEM(Me.Sº»ÁÖ¹øÈ£) Me.CLEAR_ITEM(Me.Sº»ÁÖÀüÁÖ¹øÈ£) Dim Log As String = "\Parse_º»ÁÖ.txt" If Me.cb_mainrow.Checked Then Me.Sº»ÁÖ¹øÈ£(0).MyText = SRCNUM Me.Sº»ÁÖ¹øÈ£(0).Visible = True End If If Me.cb_mainnum.Checked Then Me.Sº»ÁÖÀüÁÖ¹øÈ£(0).MyText = srcstr Me.Sº»ÁÖÀüÁÖ¹øÈ£(0).Visible = True End If AddLog(Admin, "MAIN ROW NUM=" & SRCNUM & " STRING=" & srcstr, Log) Return True End Function Public Function PARSE_°ü¸®±¸(ByVal srcstr As String) As Boolean '/¼±·Î¸íÀÇ ±æÀÌ´Â ¿¹ÃøµÇÁö ¾Ê´Â´Ù µ¿Àû ÄÁÆ®·Ñ »ý¼ºÀ» »ç¿ëÇÑ´Ù. ' MsgBox("PARSET_°ü¸®±¸") Console.WriteLine("PARSE_°ü¸®±¸ : " + srcstr) Me.CLEAR_ITEM(Me.S°ü¸®±¸) Dim Log As String = "\Parse_°ü¸®±¸.txt" If srcstr = "" OrElse Not Me.cb_kwang.Checked Then AddLog(Admin, "Zero Length - Return", Log) Return False End If Dim Wlen As Short = srcstr.Length Dim SepPos As Short = srcstr.IndexOf(";") Dim SRC() As Char = srcstr.ToCharArray AddLog(Admin, "Length=" & Wlen & " Sep=" & SepPos, Log) For i As Integer = 0 To Wlen - 1 '//¸ðµç¹®ÀÚ¸¦ ÇÒ´çÇÑ´Ù. Try S°ü¸®±¸(i).MyText = SRC(i).ToString S°ü¸®±¸(i).Visible = True Catch ex As Exception Exit For End Try 'S°ü¸®±¸(i) = New MyControlOLEDBv2.MyLabel ' MsgBox(S°ü¸®±¸(i).MyText) Next Return True End Function Public Function PARSE_°¨µ¶ÀÚ(ByVal srcstr As String) As Boolean '/¼±·Î¸íÀÇ ±æÀÌ´Â ¿¹ÃøµÇÁö ¾Ê´Â´Ù µ¿Àû ÄÁÆ®·Ñ »ý¼ºÀ» »ç¿ëÇÑ´Ù. ' MsgBox("PARSET_°ü¸®±¸") Me.CLEAR_ITEM(Me.S°¨µ¶ÀÚ) Dim Log As String = "\Parse_°¨µ¶ÀÚ.txt" If srcstr = "" OrElse Not Me.cb_man.Checked Then AddLog(Admin, "Zero Length - Return", Log) Return False End If Dim Wlen As Short = srcstr.Length Dim SepPos As Short = srcstr.IndexOf(";") Dim SRC() As Char = srcstr.ToCharArray AddLog(Admin, "Length=" & Wlen & " Sep=" & SepPos, Log) 'For i As Integer = 0 To Wlen - 1 '//¸ðµç¹®ÀÚ¸¦ ÇÒ´çÇÑ´Ù. ' Try ' S°¨µ¶ÀÚ(i).MyText = SRC(i).ToString ' S°¨µ¶ÀÚ(i).Visible = True ' Catch ex As Exception ' Exit For ' End Try 'Next Return True End Function Public Sub PARSE_°ü¸®±¸ÆÐÅÏ(ByVal srcstr As String) Dim Log As String = "\Parse_°ü¸®±¸ÆÐÅÏ.txt" Dim Wlen As Short = srcstr.Length Dim SepPos As Short = srcstr.IndexOf(";") Dim SrC() As Char = srcstr.ToCharArray '±æÀÌÆÐÅÏ¿©ºÎ¸¦ È®ÀÎÇßÀ¸¹Ç·Î ÆÐÅÏÀ»Àû¿ëÇÑ´Ù.[STYLE1LINEPATTERN9] 'Dim lpattern As Boolean = False Dim Pname As String = "CNUMPATTERN" & Wlen 'Dim Sname As String Dim CTLPOS() As String Dim CTLFONT() As String Dim CTLVISIBLE As Boolean Dim Arinini As New MyINI2(DrStyle.FILE) 'Dim tobj As MyControlOLEDBv2.MyLabel Dim Dr() As DataRow 'Dim idx As Short = 0 ' Me.±æÀÌÆÐÅÏ¿¬½À(srcstr, Pname, Log, "H", S°ü¸®±¸) Pname = "CNUMPATTERNII" & PATTERN_ENC(srcstr) Me.¹®ÀÚÆÐÅÏ¿¬½À(srcstr, Pname, Log, S°ü¸®±¸) '//°ü¸®±¸5¹ø ¾ËÆÄºª ÁöÁ¤À̵ǾîÀÖ´ÂÁö È®ÀÎÇÑ´Ù. Pname = "CNUMPATTERNI" & S°ü¸®±¸(4).MyText ' Me.h5.MyText '//5¹øÀÌ W À϶§´Â cnumpatternIw ¸¦ ã°ÔµÈ´Ù. Dr = DtPattern.Select("NAME = '" & Pname & "DESC'") If Dr.GetUpperBound(0) = 0 Then '//ÀÖ´Ù. AddLog(Admin, "°ü¸®±¸5¹ø ¹®ÀÚ¸¦ ã¾Ò½À´Ï´Ù (" & Pname & "DESC" & ")", Log) Dr = DtPattern.Select("NAME = '" & Pname & S°ü¸®±¸(4).Name & "POS'") If Dr.GetUpperBound(0) = 0 Then CTLPOS = Dr(0)(1).ToString.Split(",") Me.S°ü¸®±¸(4).Location = New Point(CTLPOS(0), CTLPOS(1)) Me.S°ü¸®±¸(4).Size = New Size(CTLPOS(2), CTLPOS(3)) End If Dr = DtPattern.Select("NAME = '" & Pname & S°ü¸®±¸(4).Name & "FONT'") If Dr.GetUpperBound(0) = 0 Then CTLFONT = Dr(0)(1).ToString.Split(",") S°ü¸®±¸(4).MyFont = New Font(CTLFONT(0), CTLFONT(1), IIf(CTLFONT(3).ToUpper = "TRUE", FontStyle.Bold, FontStyle.Regular), GraphicsUnit.Point) S°ü¸®±¸(4).ÀåÆò = CTLFONT(5) S°ü¸®±¸(4).Àå³ôÀÌ = CTLFONT(6) End If Dr = DtPattern.Select("NAME = '" & Pname & S°ü¸®±¸(4).Name & "VISIBLE'") If Dr.GetUpperBound(0) = 0 Then CTLVISIBLE = Dr(0)(1).ToString S°ü¸®±¸(4).Visible = CType(CTLVISIBLE, Boolean) End If Dr = DtPattern.Select("NAME = '" & Pname & S°ü¸®±¸(4).Name & "SPACE'") If Dr.GetUpperBound(0) = 0 Then S°ü¸®±¸(4).°ø¹é = Dr(0)(1) End If Else AddLog(Admin, "°ü¸®±¸5¹ø ¹®ÀÚ°¡ ÁöÁ¤µÇ¾îÀÖÁö¾Ê½À´Ï´Ù. (" & S°ü¸®±¸(4).MyText & ")", Log) End If End Sub Public Function PARSE_°¨µ¶ÀÚÆÐÅÏ(ByVal srcstr As String) As Integer Dim Wlen As Short = srcstr.Length : If Wlen <= 0 Then Return 3 '//¾ø´Â ±Û±Í°¡ ¿ÓÀ»¶§ ÅÏÇØ¹ö¸°´Ù. Dim SRC() As Char = srcstr.ToCharArray Dim Log As String = "\Parse_°¨µ¶ÀÚÆÐÅÏ.txt" Dim SepPos As Short = srcstr.IndexOf(";") Dim retval As Integer = 0 ''0Àº Á¤»ó 1Àº ±æÀÌÆÐÅϾøÀ½ 2´Â 3Àº ±æÀÌ+¹®ÀÚ¾øÀ½ '//¹øÈ£´Â ±æÀÌÆÐÅÏÀ» ÇÏÁö¾Ê°í ¹®ÀÚÆÐÅϸ¸ ÇÑ´Ù. Dim pname As String Dim Arinini As New MyINI2(DrStyle.FILE) Dim CTLPOS() As String '//À§Ä¡Á¤º¸ Dim CTLFONT() As String Dim CTLVISIBLE As Boolean Dim PATTERN As String = PATTERN_ENC(srcstr) Dim TOBJ As MyControlOLEDBv2.MyLabel Dim ºÐ¸®À妽º As Short = 0 Dim ¹øÈ£Çü½Ä As String = "999" Dim Dr() As DataRow '//¸ÕÀú¹®ÀÚ°¡ÀÖ´ÂÁö È®ÀÎÇÑ´Ù. pname = "MANGPATTERNII" & PATTERN Dr = DtPattern.Select("NAME = '" & pname & "M1POS'") If Dr.GetUpperBound(0) = 0 Then '//µ¥ÀÌÅͰ¡ Á¸ÀçÇϹǷΠ¸ðµÎ Àû¿ëÀ» ÇÑ´Ù. AddLog(Admin, "°¨µ¶ÀÚÆÐÅϰ¨Áö(¹®ÀÚ) : ±æÀÌ=" & Wlen & " ¹®ÀÚ¿­=" & srcstr & " ÆÐÅÏ=" & PATTERN, Log) '//µ¥ÀÌÅÍ´Â ÃÖÁ¾ÀûÀ¸·Î ¹øÈ£Çü½Ä¿¡¼­ º¸³½´Ù. ºÐ¸®À妽º = Arinini.Read(pname, "nseparate1", 2) ¹øÈ£Çü½Ä = Arinini.Read(pname, "LineType1", "999") For i As Integer = 0 To Me.S°¨µ¶ÀÚ.GetUpperBound(0) TOBJ = Me.S°¨µ¶ÀÚ(i) TOBJ.Tag = "" '//±âÁ¸Å±׸¦ »èÁ¦ÇÑ´Ù. Try '//»óŸ¦ Àо ¹Ù·Î Àû¿ëÇÑ´Ù. Dr = DtPattern.Select("NAME = '" & pname & TOBJ.Name & "POS'") If Dr.GetUpperBound(0) = 0 Then CTLPOS = Dr(0)(1).ToString.Split(",") TOBJ.Location = New Point(CTLPOS(0), CTLPOS(1)) TOBJ.Size = New Size(CTLPOS(2), CTLPOS(3)) End If Dr = DtPattern.Select("NAME = '" & pname & TOBJ.Name & "FONT'") If Dr.GetUpperBound(0) = 0 Then CTLFONT = Dr(0)(1).ToString.Split(",") TOBJ.MyFont = New Font(CTLFONT(0), CTLFONT(1), IIf(CTLFONT(3).ToUpper = "TRUE", FontStyle.Bold, FontStyle.Regular), GraphicsUnit.Point) TOBJ.ÀåÆò = CTLFONT(5) TOBJ.Àå³ôÀÌ = CTLFONT(6) End If Dr = DtPattern.Select("NAME = '" & pname & TOBJ.Name & "VISIBLE'") If Dr.GetUpperBound(0) = 0 Then CTLVISIBLE = Dr(0)(1).ToString TOBJ.Visible = CType(CTLVISIBLE, Boolean) End If Dr = DtPattern.Select("NAME = '" & pname & TOBJ.Name & "SPACE'") If Dr.GetUpperBound(0) = 0 Then TOBJ.°ø¹é = Dr(0)(1).ToString End If TOBJ.Tag = "C" Catch ex As Exception AddLog(Admin, "¹®ÀÚÆÐÅÏ¿À·ù=" & ex.Message.ToString, Log) End Try Next Else AddLog(Admin, "¹®ÀÚÆÐÅϺÒÀÏÄ¡ ±æÀÌ=" & Wlen & " ¹®ÀÚ¿­=" & srcstr & " ÆÐÅÏ=" & PATTERN, Log) retval += 2 '//ÆÐÅÏÀÌ ¾øÀ¸¹Ç·Î ¹Ù·Î ³Ñ±ä´Ù. End If If retval = 2 Then '//¹®ÀÚÆÐÅÏÀÌ ¾øÀ»°æ¿ì¿¡¸¸ ±æÀÌÆÐÅÏÀ» È®ÀÎÇÑ´Ù. '//±æÀÌÆÐÅÏ È®ÀÎ pname = "MANGPATTERN" & Wlen Dr = DtPattern.Select("NAME = '" & pname & "X1POS'") If Dr.GetUpperBound(0) = 0 Then '//µ¥ÀÌÅͰ¡ Á¸ÀçÇϹǷΠ¸ðµÎ Àû¿ëÀ» ÇÑ´Ù. AddLog(Admin, "°¨µ¶ÀÚÆÐÅϰ¨Áö(±æÀÌ) : ±æÀÌ=" & Wlen & " ¹®ÀÚ¿­=" & srcstr, Log) '//µ¥ÀÌÅÍ´Â ÃÖÁ¾ÀûÀ¸·Î ¹øÈ£Çü½Ä¿¡¼­ º¸³½´Ù. ºÐ¸®À妽º = Arinini.Read(pname, "nseparate1", 2) ¹øÈ£Çü½Ä = Arinini.Read(pname, "LineType1", "999") For i As Integer = 0 To Me.S°¨µ¶ÀÚ.GetUpperBound(0) TOBJ = Me.S°¨µ¶ÀÚ(i) TOBJ.Tag = "" '//±âÁ¸Å±׸¦ »èÁ¦ÇÑ´Ù. Try '//»óŸ¦ Àо ¹Ù·Î Àû¿ëÇÑ´Ù. Dr = DtPattern.Select("NAME = '" & pname & TOBJ.Name & "POS'") If Dr.GetUpperBound(0) = 0 Then CTLPOS = Dr(0)(1).ToString.Split(",") TOBJ.Location = New Point(CTLPOS(0), CTLPOS(1)) TOBJ.Size = New Size(CTLPOS(2), CTLPOS(3)) End If Dr = DtPattern.Select("NAME = '" & pname & TOBJ.Name & "FONT'") If Dr.GetUpperBound(0) = 0 Then CTLFONT = Dr(0)(1).ToString.Split(",") TOBJ.MyFont = New Font(CTLFONT(0), CTLFONT(1), IIf(CTLFONT(3).ToUpper = "TRUE", FontStyle.Bold, FontStyle.Regular), GraphicsUnit.Point) TOBJ.ÀåÆò = CTLFONT(5) TOBJ.Àå³ôÀÌ = CTLFONT(6) End If Dr = DtPattern.Select("NAME = '" & pname & TOBJ.Name & "VISIBLE'") If Dr.GetUpperBound(0) = 0 Then CTLVISIBLE = Dr(0)(1).ToString TOBJ.Visible = CType(CTLVISIBLE, Boolean) End If Dr = DtPattern.Select("NAME = '" & pname & TOBJ.Name & "SPACE'") If Dr.GetUpperBound(0) = 0 Then TOBJ.°ø¹é = Dr(0)(1).ToString End If TOBJ.Tag &= "L" Catch ex As Exception AddLog(Admin, "±æÀÌ ÆÐÅÏ¿À·ù=" & ex.Message.ToString, Log) End Try Next Else AddLog(Admin, "±æÀÌÆÐÅϺÒÀÏÄ¡ ±âº»½ºÅ¸ÀÏ º¹¿ø ±æÀÌ=" & Wlen & " ¹®ÀÚ¿­=" & srcstr, Log) retval += 1 '//¾ø´Ù End If End If Me.cmb_sep.SelectedIndex = ºÐ¸®À妽º If ¹øÈ£Çü½Ä = "999" Then '//ÆÐÅÏÀ̾ø¾ú´Ù´Â ¸»ÀÌ´Ù ¹øÈ£Çü½ÄÀ» ¾î´ÀÁ¤µµ ¸ÂÃçÁØ´Ù. 'MsgBox("¹øÈ£Çü½ÄÀÌ ¾ø¾î¼­ ¼ÂÆÃÇÕ´Ï´Ù(" & ¹øÈ£ & "/" & ¹øÈ£.Length) If ¹øÈ£.Length <= 12 Then If ¹øÈ£.Length <= 4 Then ¹øÈ£Çü½Ä = ¹øÈ£.Length & "00" ElseIf ¹øÈ£.Length <= 8 Then ¹øÈ£Çü½Ä = "4" & CStr(¹øÈ£.Length - 4) & "0" Else ¹øÈ£Çü½Ä = "44" & CStr(¹øÈ£.Length - 8) End If Else '//12ÀÚ¸®ÀÌ»óÀ̹ǷΠ¾î‰F°Ô Âɰ³¾ßÇÒÁö 3À¸·Î³ª´²¼­ ..int ´ëÀÔÀ» ÇÏÀÚ ¹øÈ£Çü½Ä = CStr(Int(¹øÈ£.Length / 3)) & CStr(Int(¹øÈ£.Length / 3)) & CStr(¹øÈ£.Length - Int(¹øÈ£.Length / 3) * 2) End If 'MsgBox("ÃÖÁ¾¹øÈ£=" & ¹øÈ£Çü½Ä) End If Me.tb_ntype.Text = ¹øÈ£Çü½Ä ¹øÈ£Çü½ÄÁöÁ¤°¨µ¶ÀÚ() '//¹øÈ£Çü½ÄÀ» °»½ÅÇØÁØ´Ù. Return retval '// 0ÀÌ ¸®ÅϵɰÍÀÌ´Ù. ÆÐÅÏÀÌ ¸ðµÎ Á¤»óÀ̶õ ¶æÀÌ´Ù End Function Public Function PARSE(ByVal srcstr As String, ByVal Mylabels() As MyControlOLEDBv2.MyLabel) As Boolean '/¼±·Î¸íÀÇ ±æÀÌ´Â ¿¹ÃøµÇÁö ¾Ê´Â´Ù µ¿Àû ÄÁÆ®·Ñ »ý¼ºÀ» »ç¿ëÇÑ´Ù. ' MsgBox("PARSET_°ü¸®±¸") Me.CLEAR_ITEM(Mylabels) Dim Log As String = "\Parse_" & Mylabels(0).Name & ".txt" If srcstr = "" OrElse Not Mylabels(0).CheckBox.Checked Then WLog2(Auto_Log, "Zero Length - Return", Log) Return False End If WLog2(Auto_Log, "pase ½ÃÀÛ", Log) Dim Wlen As Short = srcstr.Length Dim SepPos As Short = srcstr.IndexOf(";") Dim SRC() As Char = srcstr.ToCharArray WLog2(Auto_Log, "Length=" & Wlen & " Sep=" & SepPos, Log) Console.WriteLine("Parse : " + srcstr + ",¼³¸í=" + Mylabels(0).¼³¸í) If Mylabels(0).¼³¸í.IndexOf("ÇÑÁÙ") <> -1 Then Console.WriteLine("ÇÑÁÙ") End If If Mylabels.GetUpperBound(0) = 0 Then Mylabels(0).MyText = srcstr Mylabels(0).Visible = True Else For i As Integer = 0 To Wlen - 1 '//¸ðµç¹®ÀÚ¸¦ ÇÒ´çÇÑ´Ù. Try Select Case SRC(i) Case ";" Mylabels(i).MyText = "---" Mylabels(i).Visible = True Case ":" Mylabels(i).MyText = "" Mylabels(i).Visible = True Case Else Mylabels(i).MyText = SRC(i) Mylabels(i).Visible = True End Select Catch ex As Exception Exit For End Try Next End If Return True End Function Public Sub PARSE_PATTERN(ByVal Srcstr As String, ByVal labels() As MyControlOLEDBv2.MyLabel, Optional ByVal BlineNum As String = "") Dim Wlen As Short = Srcstr.Length : If Wlen <= 0 Then Return '//¾ø´Â ±Û±Í°¡ ¿ÓÀ»¶§ ÅÏÇØ¹ö¸°´Ù. Dim Log As String = "\PATTERN_" & labels(0).Name & ".txt" '//¸ÕÀúÆÐÅÏÀÌ Á¸ÀçÇÏ´ÂÁö È®ÀÎÇØº»´Ù. '±æÀÌÆÐÅÏ¿©ºÎ¸¦ È®ÀÎÇßÀ¸¹Ç·Î ÆÐÅÏÀ»Àû¿ëÇÑ´Ù.[STYLE1LINEPATTERN9] Dim Pname As String = labels(0).Pattern & Wlen If BlineNum <> "" Then '//ÁÙ±×·ì ' Me.±æÀÌÆÐÅÏ¿¬½À(Srcstr, "LNUM" & BlineNum & Pname, Log, labels(0).Tag, labels) Pname = labels(0).Pattern & "II" & PATTERN_ENC(Srcstr) Me.¹®ÀÚÆÐÅÏ¿¬½À(Srcstr, "LNUM" & BlineNum & Pname, Log, labels) Else ' Me.±æÀÌÆÐÅÏ¿¬½À(Srcstr, Pname, Log, labels(0).Tag, labels) Pname = labels(0).Pattern & "II" & PATTERN_ENC(Srcstr) Me.¹®ÀÚÆÐÅÏ¿¬½À(Srcstr, Pname, Log, labels) End If '//ÆÐÅÏ1ÀÌ ³¡³µ´Ù ÆÐÅÏ2¸¦ ã´Â´Ù. '//ÆÐÅÏ2´Â style1LInepatternII¹®ÀÚ¼ýÀÚÇü½Ä End Sub Public Sub PARSE_ÀåôÆÐÅÏ(ByVal SrcStr As String) Dim Wlen As Short = SrcStr.Length : If Wlen <= 0 Then Return '//¾ø´Â ±Û±Í°¡ ¿ÓÀ»¶§ ÅÏÇØ¹ö¸°´Ù. Dim Log As String = "\PATTERN_Àåô.txt" Dim SepPos As Short = SrcStr.IndexOf(";") Dim Pname As String = "CHOKPATTERN" & Wlen ' Me.±æÀÌÆÐÅÏ¿¬½À(SrcStr, Pname, Log, "J", SÀåô) Pname = "CHOKPATTERNII" & PATTERN_ENC(SrcStr) Me.¹®ÀÚÆÐÅÏ¿¬½À(SrcStr, Pname, Log, SÀåô) End Sub Public Function PARSE_Àåô(ByVal srcStr As String) As Boolean '/¼±·Î¸íÀÇ ±æÀÌ´Â ¿¹ÃøµÇÁö ¾Ê´Â´Ù µ¿Àû ÄÁÆ®·Ñ »ý¼ºÀ» »ç¿ëÇÑ´Ù. ' MsgBox("Àåô") Me.CLEAR_ITEM(SÀåô) Dim Log As String = "\Parse_Àåô.txt" If srcStr = "" OrElse Not Me.cb_jangck.Checked Then AddLog(Admin, "Zero Length - Return", Log) Return False End If Dim Wlen As Short = srcStr.Length Dim SepPos As Short = srcStr.IndexOf(";") Dim SRC() As Char = srcStr.ToCharArray AddLog(Admin, "Length=" & Wlen & " Sep=" & SepPos, Log) Select Case srcStr.Length Case 1 Me.SÀåô(0).MyText = "0" Me.SÀåô(1).MyText = srcStr Me.SÀåô(0).Visible = True Me.SÀåô(1).Visible = True Me.SÀåô(2).Visible = False Case 2 Me.SÀåô(0).MyText = srcStr.Substring(0, 1) Me.SÀåô(1).MyText = srcStr.Substring(1) Me.SÀåô(0).Visible = True Me.SÀåô(1).Visible = True Me.SÀåô(2).Visible = False 'Case 3 ' Me.SÀåô(0).MyText = srcStr.Substring(0, 1) ' Me.SÀåô(1).MyText = srcStr.Substring(1, 1) ' Me.SÀåô(2).MyText = srcStr.Substring(2) ' Me.SÀåô(0).Visible = True ' Me.SÀåô(1).Visible = True ' Me.SÀåô(2).Visible = True Case Else Me.SÀåô(0).MyText = srcStr.ToString Me.SÀåô(0).Visible = True Me.SÀåô(1).Visible = False Me.SÀåô(2).Visible = False 'If Me.cb_jc1.Checked Then '//Àåô3ÀÚ¸® »ç¿ëÀ϶§ ' Me.SÀåô(2).Visible = True ' Me.SÀåô(2).MyText = srcStr.ToString ' Me.SÀåô(2).Visible = True ' LOAD_STYLEC(Me.cmb_style.SelectedIndex & "STYLEJANGCHOK", "J") '//Àåô3ÀÚ¸®À϶§ÀÇ Ä¿½ºÅÒ½ºÅ¸ÀÏÀ» ºÒ·¯¿É´Ï´Ù ' Return False '//µÚ¿¡ ÆÐÅϰ˻縦 ÇÏÁö¾Ê±âÀ§Çؼ­ÀÌ´Ù.. ¾îÂ÷ÇÇ ÇÊ¿ä¾øÁö ¾ÊÀº°¡... 'Else '//ÀåôÀüü¸¦ º¸¿©ÁØ´Ù. ' Me.SÀåô(0).MyText = srcStr.Substring(1, 1) ' Me.SÀåô(1).MyText = srcStr.Substring(2, 1) ' Me.SÀåô(0).Visible = True 'End If End Select Return True End Function Private Sub PARSE_Á¢Áö1(ByVal srcstr As String) Me.CLEAR_ITEM(SÁ¢Áö) If srcstr <> "" AndAlso Me.cb_jji.Checked Then Me.SÁ¢Áö(0).MyText = srcstr & "§Ù" Me.SÁ¢Áö(0).Visible = True End If End Sub Private Sub PARSE_Á¢Áö2(ByVal srcstr As String) If srcstr <> "" AndAlso Me.cb_jji.Checked Then Me.SÁ¢Áö(1).MyText = srcstr & "§Ù" Me.SÁ¢Áö(1).Visible = True End If End Sub Private Sub cmb_landscape_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles cmb_landscape.SelectedIndexChanged SaveReadLayOut(True) End Sub Private Sub GetPrintersName() AddLog(Admin, "GetPrinterName()", "\Alllog.txt") Dim value As PrinterSettings.StringCollection = System.Drawing.Printing.PrinterSettings.InstalledPrinters Me.combobox5.Items.Clear() For i As Integer = 0 To value.Count - 1 Me.combobox5.Items.Add(value(i)) Next End Sub Private Sub printform_MouseWheel(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles Me.MouseWheel If e.Delta < 0 Then 'If Me.BindingNavigatorPositionItem.Text < Me.BindingNavigatorCountItem.Text Then 'If Me.cb_dummy.Checked AndAlso Me.cmb_dummy.SelectedIndex = 1 And Me.BindingSource1.Position >= 0 AndAlso Me.BindingSource1.Position + 1 < Me.BindingSource1.Count Then '//ÇöÀçÀ妽º°¡ ÃÖ°í°ªº¸´Ù ÀÛÀ¸¸é 'Me.BindingSource1.Position += 2 'Else Me.BindingSource1.Position += 1 'End If 'Me.BindingNavigatorMoveNextItem.PerformClick() 'Me.BindingNavigatorPositionItem.Focus() 'End If Else If Me.BindingNavigatorPositionItem.Text > 0 Then 'If Me.cb_dummy.Checked AndAlso Me.cmb_dummy.SelectedIndex = 1 And Me.BindingSource1.Position >= 0 AndAlso Me.BindingSource1.Position + 1 < Me.BindingSource1.Count Then '//ÇöÀçÀ妽º°¡ ÃÖ°í°ªº¸´Ù ÀÛÀ¸¸é ' Me.BindingSource1.Position -= 2 'Else Me.BindingSource1.Position -= 1 'End If 'Me.BindingNavigatorMovePreviousItem.PerformClick() 'Me.BindingNavigatorPositionItem.Focus() End If End If End Sub Private Sub Panel1_MouseMove(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Me.Text = e.X & "/" & e.Y End Sub Private Sub ToolStripButton4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles bt_chkpattern.Click If Me.bt_chkpattern.Text = "ÁßÁö(&S)" Then ' If BackWork.IsAlive Then BackWork.Abort() Me.bt_chkpattern.Text = "½ÃÀÛ(&S)" Else Me.bt_chkpattern.Text = "ÁßÁö(&S)" 'BackWork = New Threading.Thread(AddressOf NPartternCheck) 'BackWork.Start() NPartternCheck() End If End Sub 'Private Sub ToolStripMenuItem5_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) ' Dim A As New System.Text.StringBuilder ' A.AppendLine("[±âŸ½ºÅ¸ÀÏ] Àåô3ÀÚ¸® »ç¿ëÀÌ ¼±ÅõǾîÀÖ½À´Ï´Ù") ' A.AppendLine() ' A.AppendLine("±âŸ½ºÅ¸ÀÏ ÀúÀåÀ» Ŭ¸¯Çϼ¼¿ä") ' If Me.cb_jc1.Checked Then ' MsgBox(A.ToString, MsgBoxStyle.Critical, "È®ÀÎ") ' Return ' End If ' SAVE_PATTERNII(Me.Àåô.ToCharArray, "CHOKPATTERNII", "J", "\ÀåôÆÐÅÏ2.TXT") '//¼±·Î¸íÀÇ ÆÐÅÏÀ» ÀúÀåÇÕ´Ï´Ù. 'End Sub 'Private Sub ToolStripMenuItem4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) ' SAVE_PATTERNII(Me.½Ã°ø³â¿ù.ToCharArray, "YYMMPATTERNII", "Y", "\½Ã°ø³â¿ùÆÐÅÏ2.TXT") '//¼±·Î¸íÀÇ ÆÐÅÏÀ» ÀúÀåÇÕ´Ï´Ù. ' SAVE_PATTERNII(Me.Á¡°ËÀÏÀÚ.ToCharArray, "YYMMPATTERNII", "O", "\Á¤°ËÀÏÀÚÆÐÅÏ2.TXT") '//¼±·Î¸íÀÇ ÆÐÅÏÀ» ÀúÀåÇÕ´Ï´Ù. ' SAVE_PATTERNII(Me.Á¡°Ë.ToCharArray, "YYMMPATTERNII", "HI", "\Á¤°ËÀÏÀÚÆÐÅÏ2.TXT") '//¼±·Î¸íÀÇ ÆÐÅÏÀ» ÀúÀåÇÕ´Ï´Ù. 'End Sub 'Private Sub ToolStripMenuItem3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) ' SAVE_PATTERNII(Me.Àü»ê¹øÈ£.ToCharArray, "JNUMPATTERNII", "S", "\¼±·Î¹øÈ£ÆÐÅÏ2.TXT") '//¼±·Î¸íÀÇ ÆÐÅÏÀ» ÀúÀåÇÕ´Ï´Ù. 'End Sub 'Private Sub ToolStripMenuItem2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) ' SAVE_PATTERNII(Me.°ü¸®±¸.ToCharArray, "CNUMPATTERNII", "H", "\Àü»ê¹øÈ£ÆÐÅÏ2.TXT") '//¼±·Î¸íÀÇ ÆÐÅÏÀ» ÀúÀåÇÕ´Ï´Ù. 'End Sub 'Private Sub ToolStripMenuItem1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) ' SAVE_PATTERNII(Me.¼±·Î¸í.ToCharArray, "LINEPATTERNII", "L", "\¼±·Î¸íÆÐÅÏ2.TXT") '//¼±·Î¸íÀÇ ÆÐÅÏÀ» ÀúÀåÇÕ´Ï´Ù. 'End Sub Private Sub Button8_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button8.Click '//°í°ü¸®±¸ 5¹ø ÀúÀå Dim msg As New System.Text.StringBuilder msg.AppendLine("°ü¸®±¸5¹ø ¿µ¹®ÀÚ(" & Me.S°ü¸®±¸(4).MyText & " )¹®ÀÚ¿¡´ëÇÑ ½ºÅ¸ÀÏÀ» ÀúÀåÇÕ´Ï´Ù") msg.AppendLine() msg.AppendLine("ÀúÀåÈÄ °ü¸®±¸5¹ø¿¡ µ¿ÀÏÇÑ ¿µ¹®ÀÚ°¡ ¿Ã°æ¿ì¿¡ ÀúÀåµÈ ³»¿ëÀÌ ¹Ý¿µµË´Ï´Ù") msg.AppendLine("------------------") msg.AppendLine("±Û²Ã = " & Me.S°ü¸®±¸(4).MyFont.ToString) msg.AppendLine("³Êºñ = " & Me.S°ü¸®±¸(4).ÀåÆò) msg.AppendLine("³ôÀÌ = " & Me.S°ü¸®±¸(4).Àå³ôÀÌ) msg.AppendLine("ÁÂÇ¥ = " & Me.S°ü¸®±¸(4).Location.ToString) msg.AppendLine("------------------") msg.AppendLine(" ÀúÀåÇϽðڽÀ´Ï±î?") If MsgBox(msg.ToString, MsgBoxStyle.Information + MsgBoxStyle.OkCancel, "ÀúÀåÈ®ÀÎ") <> MsgBoxResult.Ok Then NOTICE("Ãë¼ÒµÇ¾ú½À´Ï´Ù", Me.lb_msg) Return End If 'ÀÌ°Ç ±æÀÌÆÐÅÏ ÀúÀåÇÏ´Â ÇÔ¼ö´Ù. 'MsgBox(StyleList(Me.cmb_style.SelectedIndex).File) Dim Arinini As New MyINI2(DrStyle.FILE) Dim TOBJ As MyControlOLEDBv2.MyLabel = Me.S°ü¸®±¸(4) Dim Pname As String = "CNUMPATTERNI" & TOBJ.MyText '//5¹øÀÌ W À϶§´Â cnumpatternIw ¸¦ ã°ÔµÈ´Ù. Arinini.Write(Pname, "DESC", "¿µ¹®ÀÚ Æ¯¼öÀúÀå(" & TOBJ.MyText & ")") Arinini.Write(Pname, TOBJ.Name & "pos", TOBJ.Left & "," & TOBJ.Top & "," & TOBJ.Width & "," & TOBJ.Height) Arinini.Write(Pname, TOBJ.Name & "font", TOBJ.MyFont.Name & "," & TOBJ.MyFont.Size & "," & TOBJ.MyFont.Underline & "," & TOBJ.MyFont.Bold & "," & TOBJ.MyFont.Italic & "," & TOBJ.ÀåÆò & "," & TOBJ.Àå³ôÀÌ) Arinini.Write(Pname, TOBJ.Name & "visible", TOBJ.Visible) Arinini.Write(Pname, TOBJ.Name & "space", TOBJ.°ø¹é) NOTICE("°ü¸®±¸5¹ø ÀÇ ¿µ¹®ÀÚ (" & TOBJ.MyText & ") »óŸ¦ ÀúÀåÇÏ¿´½À´Ï´Ù", Me.lb_msg) µ¥ÀÌÅÍÅ×ÀÌºí°»½Å() End Sub Private Sub ToolStripButton6_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) If Not Me.cb_jc1.Checked Then MsgBox("±âŸ½ºÅ¸ÀÏ[Àåô3ÀÚ¸®]¸¦ »ç¿ëÇÏÁö ¾Ê±â‹š¹®¿¡ ÀúÀåÀÌ µÇÁö ¾Ê½À´Ï´Ù", MsgBoxStyle.Critical, "È®ÀÎ") Return End If If MsgBox("ÇöÀç ½ºÅ¸ÀÏ(±âŸ-Àåô3ÀÚ¸®)À» ÀúÀåÇϽðڽÀ´Ï±î?", MsgBoxStyle.Information + MsgBoxStyle.YesNo, "±âŸ½ºÅ¸ÀÏÀúÀå") = MsgBoxResult.Yes Then If Me.cb_jc1.Checked Then Me.SAVE_STYLEC(Me.cmb_style.SelectedIndex & "STYLEJANGCHOK", "J") NOTICE("½ºÅ¸ÀÏ(±âŸ-Àåô3ÀÚ¸®)À» ÀúÀåÇß½À´Ï´Ù", Me.lb_msg) Else NOTICE("½ºÅ¸ÀÏ(±âŸ-Àåô3ÀÚ¸®)ÀúÀåÀÌ Ãë¼ÒµÇ¾ú½À´Ï´Ù", Me.lb_msg) End If End Sub Private Sub ±âŸÀåô3ÀÚ¸®ToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) If Not Me.cb_jc1.Checked Then MsgBox("±âŸ½ºÅ¸ÀÏ[Àåô3ÀÚ¸®]¸¦ »ç¿ëÇÏÁö ¾Ê±â‹š¹®¿¡ ÀúÀåÀÌ µÇÁö ¾Ê½À´Ï´Ù", MsgBoxStyle.Critical, "È®ÀÎ") Return End If If MsgBox("ÇöÀç ½ºÅ¸ÀÏ(±âŸ-Àåô3ÀÚ¸®)À» ÀúÀåÇϽðڽÀ´Ï±î?", MsgBoxStyle.Information + MsgBoxStyle.YesNo, "±âŸ½ºÅ¸ÀÏÀúÀå") = MsgBoxResult.Yes Then Me.SAVE_STYLEC(Me.cmb_style.SelectedIndex & "STYLEJANGCHOK", "J") NOTICE("½ºÅ¸ÀÏ(±âŸ-Àåô3ÀÚ¸®)À» ÀúÀåÇß½À´Ï´Ù", Me.lb_msg) Else NOTICE("½ºÅ¸ÀÏ(±âŸ-Àåô3ÀÚ¸®)ÀúÀåÀÌ Ãë¼ÒµÇ¾ú½À´Ï´Ù", Me.lb_msg) End If End Sub #Region "Not Edit" Private Sub Button3_Click_1(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click 'Me.SetFont() If Not IsNumeric(Me.tb_space.Text) Then MsgBox("¼ýÀÚ¸¸ ÀÔ·ÂÇϼ¼¿ä", MsgBoxStyle.Critical, "È®ÀÎ") Return End If For Each A As Control In SelCon CType(A, MyControlOLEDBv2.MyLabel).°ø¹é = CInt(Me.tb_space.Text) 'Me.UpdateFontSize(Me.tb_space.Text, A) Next Me.preview_window() End Sub Private Sub tb_picfile_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles tb_picfile.TextChanged If Not IO.File.Exists(Me.tb_picfile.Text) Then Me.erp.SetError(Me.tb_picfile, "±×¸²ÆÄÀÏÀÌ Á¸ÀçÇÏÁö ¾Ê½À´Ï´Ù") Else Me.erp.SetError(Me.tb_picfile, "") End If End Sub Private Sub bt_canvasL_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles bt_canvasL.Click Me.PictureBox1.Width -= 2 End Sub Private Sub bt_canvasR_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles bt_canvasR.Click Me.PictureBox1.Width += 2 End Sub Private Sub bt_canvasU_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles bt_canvasU.Click Me.PictureBox1.Height -= 2 End Sub Private Sub bt_canvasD_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles bt_canvasD.Click Me.PictureBox1.Height += 2 End Sub Public Sub preview_window() '//¹Ì¸®º¸±âÈ­¸éÀ» »ý¼ºÇÕ´Ï´Ù. ((Ãâ·Ââ)) 'Dim fmt As New StringFormat(StringFormatFlags.LineLimit) Dim MyFont As Font Dim NewFontSize As Int16 = 10 Dim dummy As Boolean = False '//À̰ªÀÌ true À̸é Ãâ·Â½Ã º¯À§¸¦ ÁöÁ¤Çؼ­ Ãâ·ÂÇÑ´Ù. Dim BackScr As New Bitmap(Me.PictureBox1.Width, Me.PictureBox1.Height, Me.PictureBox1.CreateGraphics) Dim Ga As Graphics = Graphics.FromImage(BackScr) Dim Brush As SolidBrush Dim obj As MyControlOLEDBv2.MyLabel '//½¦ÀÌÇÁ¸¦ ¸ÕÀú ±×¸°´Ù. If Me.chk_draw.Checked Then '//¶óÀÎÀ» ±×¸°´Ù. For Each Rect As S_Line In Draw_Line If Rect.Field <> "" Then Select Case Rect.Field Case "COSÈÞÁî¿ë·®" If Me.ÈÞÁî¿ë·® = "" OrElse Not cb_ÈÞÁî¿ë·®.Checked Then Continue For End If Case "»óÇ¥½ÃÂû1´Ü" If Me.»óÇ¥½ÃÂû1´Ü = "" OrElse Not cb_»ó1´Ü.Checked Then Continue For End If Case "»óÇ¥½ÃÂû2´Ü" If Me.»óÇ¥½ÃÂû2´Ü = "" OrElse Not cb_»ó2´Ü.Checked Then Continue For End If Case "Á¡°ËÀÏÀÚ" If Me.Á¡°ËÀÏÀÚ = "" OrElse Not cb_date.Checked Then Continue For End If Case "¼±·ÎÀü¹æ" If Me.¼±·ÎÀü¹æ = "" Then Continue For End If Case "¼±·ÎÁÂÃø" If Me.¼±·ÎÁÂÃø = "" Then Continue For End If Case "¼±·Î¿ìÃø" If Me.¼±·Î¿ìÃø = "" Then Continue For End If End Select End If Dim Pen As New Drawing.Pen(Rect.PenColor, Rect.PenWidth) Ga.DrawLine(Pen, Rect.X, Rect.Y, Rect.X2, Rect.Y2) Next '//¹Ú½º¸¦ ±×¸°´Ù. For Each Rect As S_Box In Draw_Box If Rect.Field <> "" Then Select Case Rect.Field Case "COSÈÞÁî¿ë·®" If Me.ÈÞÁî¿ë·® = "" OrElse Not cb_ÈÞÁî¿ë·®.Checked Then Continue For End If Case "»óÇ¥½ÃÂû1´Ü" If Me.»óÇ¥½ÃÂû1´Ü = "" OrElse Not cb_»ó1´Ü.Checked Then Continue For End If Case "»óÇ¥½ÃÂû2´Ü" If Me.»óÇ¥½ÃÂû2´Ü = "" OrElse Not cb_»ó2´Ü.Checked Then Continue For End If Case "Á¡°ËÀÏÀÚ" If Me.Á¡°ËÀÏÀÚ = "" OrElse Not cb_date.Checked Then Continue For End If Case "¼±·ÎÀü¹æ" If Me.¼±·ÎÀü¹æ = "" Then Continue For End If Case "¼±·ÎÁÂÃø" If Me.¼±·ÎÁÂÃø = "" Then Continue For End If Case "¼±·Î¿ìÃø" If Me.¼±·Î¿ìÃø = "" Then Continue For End If End Select End If Dim Pen As New Drawing.Pen(Rect.PenColor, Rect.PenWidth) Ga.DrawRectangle(Pen, Rect.X, Rect.Y, Rect.Width, Rect.Height) Next For Each Rect As S_Circle In Draw_Circle If Rect.Field <> "" Then Select Case Rect.Field Case "COSÈÞÁî¿ë·®" If Me.ÈÞÁî¿ë·® = "" OrElse Not cb_ÈÞÁî¿ë·®.Checked Then Continue For End If Case "»óÇ¥½ÃÂû1´Ü" If Me.»óÇ¥½ÃÂû1´Ü = "" OrElse Not cb_»ó1´Ü.Checked Then Continue For End If Case "»óÇ¥½ÃÂû2´Ü" If Me.»óÇ¥½ÃÂû2´Ü = "" OrElse Not cb_»ó2´Ü.Checked Then Continue For End If Case "Á¡°ËÀÏÀÚ" If Me.Á¡°ËÀÏÀÚ = "" OrElse Not cb_date.Checked Then Continue For End If Case "¼±·ÎÀü¹æ" If Me.¼±·ÎÀü¹æ = "" Then Continue For End If Case "¼±·ÎÁÂÃø" If Me.¼±·ÎÁÂÃø = "" Then Continue For End If Case "¼±·Î¿ìÃø" If Me.¼±·Î¿ìÃø = "" Then Continue For End If End Select End If Dim Pen As New Drawing.Pen(Rect.PenColor, Rect.PenWidth) Ga.DrawEllipse(Pen, Rect.X, Rect.Y, Rect.Width, Rect.Height) Next '//±×¸²À» ±×¸°´Ù. For Each Rect As S_Image In Draw_Image If Rect.Field <> "" Then Select Case Rect.Field Case "COSÈÞÁî¿ë·®" If Me.ÈÞÁî¿ë·® = "" OrElse Not cb_ÈÞÁî¿ë·®.Checked Then Continue For End If Case "»óÇ¥½ÃÂû1´Ü" If Me.»óÇ¥½ÃÂû1´Ü = "" OrElse Not cb_»ó1´Ü.Checked Then Continue For End If Case "»óÇ¥½ÃÂû2´Ü" If Me.»óÇ¥½ÃÂû2´Ü = "" OrElse Not cb_»ó2´Ü.Checked Then Continue For End If Case "Á¡°ËÀÏÀÚ" If Me.Á¡°ËÀÏÀÚ = "" OrElse Not cb_date.Checked Then Continue For End If Case "¼±·ÎÀü¹æ" If Me.¼±·ÎÀü¹æ = "" Then Continue For End If Case "¼±·ÎÁÂÃø" If Me.¼±·ÎÁÂÃø = "" Then Continue For End If Case "¼±·Î¿ìÃø" If Me.¼±·Î¿ìÃø = "" Then Continue For End If End Select End If Dim F As String = Rect.FileName If F.Trim <> "" Then F = F.Replace(".\", My.Application.Info.DirectoryPath & "\") If System.IO.File.Exists(F) Then Dim Image As Image = Image.FromFile(F) If Rect.Width = 0 OrElse Rect.Height = 0 Then ' Ga.DrawImage(Image, Rect.X + MyProperty_Paper.Ãâ·Â¿©¹éX, Rect.Y + MyProperty_Paper.Ãâ·Â¿©¹éY) Ga.DrawImage(Image, Rect.X, Rect.Y) Else ' Ga.DrawImage(Image, Rect.X + MyProperty_Paper.Ãâ·Â¿©¹éX, Rect.Y + MyProperty_Paper.Ãâ·Â¿©¹éY, Rect.Width, Rect.Height) Ga.DrawImage(Image, Rect.X, Rect.Y, Rect.Width, Rect.Height) End If End If End If Next '//È­»ìÇ¥¸¦ ±×¸°´Ù. 170711 For Each Rect As S_Arrow In Draw_Arrow Select Case Rect.Direction Case 0 If Me.¼±·ÎÀü¹æ = "" Then Continue For End If Case 1 If Me.¼±·ÎÁÂÃø = "" Then Continue For End If Case 2 If Me.¼±·Î¿ìÃø = "" Then Continue For End If End Select '//°¢Æ÷ÀÎÆ®¸¦ »ý¼ºÇÑ´Ù. Dim pts As New List(Of Point) If Rect.Direction = 1 Then '//ÁÂÃø pts.Add(New Point(Rect.RectX - Rect.TriWidth, Rect.RectY + Rect.RectH / 2)) pts.Add(New Point(Rect.RectX, Rect.RectY - Rect.TriHeight)) pts.Add(New Point(Rect.RectX, Rect.RectY)) pts.Add(New Point(Rect.RectX + Rect.RectW, Rect.RectY)) pts.Add(New Point(Rect.RectX + Rect.RectW, Rect.RectY + Rect.RectH)) pts.Add(New Point(Rect.RectX, Rect.RectY + Rect.RectH)) pts.Add(New Point(Rect.RectX, Rect.RectY + Rect.RectH + Rect.TriHeight)) pts.Add(New Point(Rect.RectX - Rect.TriWidth, Rect.RectY + Rect.RectH / 2)) ElseIf Rect.Direction = 2 Then '//¿ìÃø pts.Add(New Point(Rect.RectX, Rect.RectY)) pts.Add(New Point(Rect.RectX + Rect.RectW, Rect.RectY)) pts.Add(New Point(Rect.RectX + Rect.RectW, Rect.RectY - Rect.TriHeight)) pts.Add(New Point(Rect.RectX + Rect.RectW + Rect.TriWidth, Rect.RectY + Rect.RectH / 2)) pts.Add(New Point(Rect.RectX + Rect.RectW, Rect.RectY + Rect.RectH + Rect.TriHeight)) pts.Add(New Point(Rect.RectX + Rect.RectW, Rect.RectY + Rect.RectH)) pts.Add(New Point(Rect.RectX, Rect.RectY + Rect.RectH)) pts.Add(New Point(Rect.RectX, Rect.RectY)) ElseIf Rect.Direction = 0 Then '//Àü¹æ pts.Add(New Point(Rect.RectX, Rect.RectY + Rect.RectH)) pts.Add(New Point(Rect.RectX, Rect.RectY)) pts.Add(New Point(Rect.RectX - Rect.TriWidth, Rect.RectY)) pts.Add(New Point(Rect.RectX + Rect.RectW / 2, Rect.RectY - Rect.TriHeight)) pts.Add(New Point(Rect.RectX + Rect.RectW + Rect.TriWidth, Rect.RectY)) pts.Add(New Point(Rect.RectX + Rect.RectW, Rect.RectY)) pts.Add(New Point(Rect.RectX + Rect.RectW, Rect.RectY + Rect.RectH)) pts.Add(New Point(Rect.RectX, Rect.RectY + Rect.RectH)) End If Dim Pen As New Drawing.SolidBrush(Rect.PenColor) Ga.FillPolygon(Pen, pts.ToArray()) Next If °ü¸®±¸ <> "" Then '// qrÄڵ带 ±×¸°´Ù For Each Rect As S_QRCode In Draw_QRcode 'Dim scale As Int16 Dim version As Int16 Dim image As Image Dim data As String Dim errorCorrect As String Dim qrCodeEncoder1 As New QRCodeEncoder() Dim encoding As String encoding = cboEncoding.Text If encoding = "3" Then qrCodeEncoder1.QRCodeEncodeMode = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ENCODE_MODE.BYTE ElseIf encoding = "1" Then qrCodeEncoder1.QRCodeEncodeMode = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ENCODE_MODE.ALPHA_NUMERIC ElseIf encoding = "2" Then qrCodeEncoder1.QRCodeEncodeMode = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ENCODE_MODE.NUMERIC ' Try 'scale = Convert.ToInt16(txtSize.Text) 'qrCodeEncoder.QRCodeScale = scale 'Catch ex As Exception ' MessageBox.Show("Invalid size!") ' End Try Try version = Convert.ToInt16(cboVersion.Text) qrCodeEncoder1.QRCodeVersion = version Catch ex As Exception MessageBox.Show("Invaild Version!") End Try End If errorCorrect = cboCorrectionLevel.Text If errorCorrect = "1" Then qrCodeEncoder1.QRCodeErrorCorrect = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ERROR_CORRECTION.L ElseIf errorCorrect = "2" Then qrCodeEncoder1.QRCodeErrorCorrect = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ERROR_CORRECTION.M ElseIf errorCorrect = "3" Then qrCodeEncoder1.QRCodeErrorCorrect = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ERROR_CORRECTION.Q ElseIf errorCorrect = "4" Then qrCodeEncoder1.QRCodeErrorCorrect = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ERROR_CORRECTION.H End If qrȨÆäÀÌÁö1 = home1.Text qrȨÆäÀÌÁö2 = home2.Text qrȨÆäÀÌÁö3 = home3.Text qrȨÆäÀÌÁö4 = home4.Text Try 'data = qrȨÆäÀÌÁö1 & "/" & qrȨÆäÀÌÁö2 & "/" & qrȨÆäÀÌÁö3 & "/" & qrȨÆäÀÌÁö4 & "=" & °ü¸®±¸ & Àü»ê¹øÈ£ & "&name=" & ½Å¼±·ÎÀüÁÖ¹øÈ£ & ":" & ½Ã°ø³â¿ù & ":" & Àåô ' & " ½Ã°øÀÚ: " & ½Ã°øÀÚ & " °¨µ¶ÀÚ : " & °¨µ¶ÀÚ data = qrȨÆäÀÌÁö1 & "/" & qrȨÆäÀÌÁö2 & "/" & qrȨÆäÀÌÁö3 & "/" & qrȨÆäÀÌÁö4 & "=" & °ü¸®±¸ & "-" & Àü»ê¹øÈ£ & "&name=" & ½Å¼±·ÎÀüÁÖ¹øÈ£ & ":" & Àåô & "M" ' ½Ã°øÀÚ: " & ½Ã°øÀÚ & " °¨µ¶ÀÚ : " & °¨µ¶ÀÚ If lbQrBg.BackColor <> Drawing.Color.White Then qrCodeEncoder1.QRCodeBackgroundColor = lbQrBg.BackColor If lbQrFG.BackColor <> Drawing.Color.Black Then qrCodeEncoder1.QRCodeForegroundColor = lbQrFG.BackColor image = qrCodeEncoder1.Encode(data, Ga.DpiX, Ga.DpiY) 'data¼³Á¤ Àӽà If Rect.Width = 0 OrElse Rect.Height = 0 Then 'Ga.DrawImage(image, Rect.X + MyProperty_Paper.Ãâ·Â¿©¹éX, Rect.Y + MyProperty_Paper.Ãâ·Â¿©¹éY) Ga.DrawImage(image, Rect.X, Rect.Y) Else 'Ga.DrawImage(image, Rect.X + MyProperty_Paper.Ãâ·Â¿©¹éX, Rect.Y + MyProperty_Paper.Ãâ·Â¿©¹éY, Rect.Width, Rect.Height) Ga.DrawImage(image, Rect.X, Rect.Y, Rect.Width, Rect.Height) End If Catch ex As Exception 'MessageBox.Show("QRÄڵ带 ±×¸®´Âµ¥ DATA°¡ ¼ýÀÚÀÎÁö ¿µ¼ýÀÚÀÎÁö ¸ðµÎÀÎÁö È®ÀÎ ÈÄ ¼±ÅÃÇÏ¿© ÁÖ¼¼¿ä") MessageBox.Show(ex.ToString()) End Try Next '// qrÄڵ带 ±×¸°´Ù For Each Rect As S_QRCode1 In Draw_QRcode1 'Dim scale As Int16 Dim version As Int16 Dim image As Image Dim data As String Dim errorCorrect As String Dim qrCodeEncoder1 As New QRCodeEncoder() Dim encoding As String encoding = cboEncoding.Text If encoding = "3" Then qrCodeEncoder1.QRCodeEncodeMode = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ENCODE_MODE.BYTE ElseIf encoding = "1" Then qrCodeEncoder1.QRCodeEncodeMode = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ENCODE_MODE.ALPHA_NUMERIC ElseIf encoding = "2" Then qrCodeEncoder1.QRCodeEncodeMode = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ENCODE_MODE.NUMERIC ' Try 'scale = Convert.ToInt16(txtSize.Text) 'qrCodeEncoder.QRCodeScale = scale 'Catch ex As Exception ' MessageBox.Show("Invalid size!") ' End Try Try version = Convert.ToInt16(cboVersion.Text) qrCodeEncoder1.QRCodeVersion = version Catch ex As Exception MessageBox.Show("Invaild Version!") End Try End If errorCorrect = cboCorrectionLevel.Text If errorCorrect = "1" Then qrCodeEncoder1.QRCodeErrorCorrect = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ERROR_CORRECTION.L ElseIf errorCorrect = "2" Then qrCodeEncoder1.QRCodeErrorCorrect = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ERROR_CORRECTION.M ElseIf errorCorrect = "3" Then qrCodeEncoder1.QRCodeErrorCorrect = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ERROR_CORRECTION.Q ElseIf errorCorrect = "4" Then qrCodeEncoder1.QRCodeErrorCorrect = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ERROR_CORRECTION.H End If rqr±âŸ1 = gita1.Text rqr±âŸ2 = gita2.Text rqr±âŸ3 = gita3.Text rqr±âŸ4 = gita4.Text Try 'data = q½Ã°øÀÚ & qȨÆäÀÌÁö & q°ü¸® & q°ü¸®1 & q°ü¸®2 If rqr±âŸ1 <> "" And rqr±âŸ2 <> "" And rqr±âŸ3 <> "" And rqr±âŸ4 <> "" Then data = rqr±âŸ1 & "/" & rqr±âŸ2 & "/" & rqr±âŸ3 & "/" & rqr±âŸ4 ElseIf rqr±âŸ1 <> "" And rqr±âŸ2 <> "" And rqr±âŸ3 <> "" Then data = rqr±âŸ1 & "/" & rqr±âŸ2 & "/" & rqr±âŸ3 ElseIf rqr±âŸ1 <> "" And rqr±âŸ2 <> "" Then data = rqr±âŸ1 & "/" & rqr±âŸ2 ElseIf rqr±âŸ1 <> "" Then data = rqr±âŸ1 Else data = rqr±âŸ1 & "/" & rqr±âŸ2 & "/" & rqr±âŸ3 & "/" & rqr±âŸ4 End If If lbQrBg.BackColor <> Drawing.Color.White Then qrCodeEncoder1.QRCodeBackgroundColor = lbQrBg.BackColor If lbQrFG.BackColor <> Drawing.Color.Black Then qrCodeEncoder1.QRCodeForegroundColor = lbQrFG.BackColor image = qrCodeEncoder1.Encode(data, Ga.DpiX, Ga.DpiY) If Rect.Width = 0 OrElse Rect.Height = 0 Then 'Ga.DrawImage(image, Rect.X + MyProperty_Paper.Ãâ·Â¿©¹éX, Rect.Y + MyProperty_Paper.Ãâ·Â¿©¹éY) Ga.DrawImage(image, Rect.X, Rect.Y) Else 'Ga.DrawImage(image, Rect.X + MyProperty_Paper.Ãâ·Â¿©¹éX, Rect.Y + MyProperty_Paper.Ãâ·Â¿©¹éY, Rect.Width, Rect.Height) Ga.DrawImage(image, Rect.X, Rect.Y, Rect.Width, Rect.Height) End If Catch ex As Exception 'MessageBox.Show("QRÄڵ带 ±×¸®´Âµ¥ DATA°¡ ¼ýÀÚÀÎÁö ¿µ¼ýÀÚÀÎÁö ¸ðµÎÀÎÁö È®ÀÎ ÈÄ ¼±ÅÃÇÏ¿© ÁÖ¼¼¿ä") MessageBox.Show(ex.ToString()) End Try Next End If End If If Me.tb_pagerepeat.Text = "" Or Me.tb_pagerepeat.Text < 1 Then Me.tb_pagerepeat.Text = "0" For pi As Short = 0 To Me.tb_pagerepeat.Text - 1 '//ÆäÀÌÁö´ç ¿¬¼ÓÃâ·ÂÇÒ È½¼ö For i As Integer = 0 To Me.AllLabels.GetUpperBound(0) '//¸ðµç °³Ã¼µé¿¡ ´ëÇØ¼­ Àμ⸦ ¼³Á¤ÇÑ´Ù. obj = Me.AllLabels(i).ctl If obj.¼³¸í.IndexOf("ÇÑÁÙ") <> -1 Then Console.WriteLine("ÇÑÁÙÀüÁÖ¹øÈ£ Ç¥½Ã visible=" + obj.Visible.ToString()) End If If obj.Visible AndAlso obj.MyText <> "" Then '//È­¸é¿¡ º¸À̴°͸¸ ÇÑ´Ù. For rcnt As Short = 0 To obj.Repeat '//¹Ýº¹±â´ÉÃß°¡ÇÑ´Ù NewFontSize = obj.MyFont.Size + Me.tb_myfontsize.Text If NewFontSize < 0 Then NewFontSize = 0 If pi > 0 Then '//¿¬¼ÓÃâ·Â¿¡ÀÇÇÑ ˜¹±òº¯°æ Brush = New SolidBrush(Drawing.Color.DarkKhaki) '//Àü°æ»öÀ¸·Î ºê·¯½¬¸¦ ¸¸µç´Ù. Else If rcnt > 0 Then '//´õ¹ÌÃâ·Â¿¡ÀÇÇÑ »ö±òº¯°æ Brush = New SolidBrush(Drawing.Color.LightGray) '//Àü°æ»öÀ¸·Î ºê·¯½¬¸¦ ¸¸µç´Ù. Else Brush = New SolidBrush(obj.MyForeColor) '//Àü°æ»öÀ¸·Î ºê·¯½¬¸¦ ¸¸µç´Ù. End If End If MyFont = New Font(obj.MyFont.FontFamily, NewFontSize, obj.MyFont.Style) If obj.ÀåÆò = 100 AndAlso obj.Àå³ôÀÌ = 100 Then '//ÀåÆò¹Ì»ç¿ë ¹®ÀÚ¿­ ó¸® Ga.DrawString(obj.ÃÖÁ¾¹®ÀÚ, MyFont, Brush, (obj.Left + Me.tb_secX.Text * pi + obj.RepeatX * rcnt), (obj.Top + Me.tb_secY.Text * pi + obj.RepeatY * rcnt)) Else '//ÀåÆò»ç¿ë À̹ÌÁö ó¸® Dim NewX, Newy As Integer Dim SrcDpix, SrcDPiY As Single 'MsgBox(Tobj.Àå³ôÀÌ) SrcDpix = obj.CreateGraphics.DpiX SrcDPiY = obj.CreateGraphics.DpiY NewX = obj.GetSize(MyFont).Width * (obj.ÀåÆò / 100) * (Ga.DpiX / SrcDpix) Newy = obj.GetSize(MyFont).Height * (obj.Àå³ôÀÌ / 100) * (Ga.DpiY / SrcDPiY) Dim BMP As New Bitmap(NewX, Newy, Ga) Dim G As Graphics = Graphics.FromImage(BMP) G.ResetTransform() G.ScaleTransform((obj.ÀåÆò / 100), (obj.Àå³ôÀÌ / 100)) If rcnt > 0 Then G.DrawString(obj.ÃÖÁ¾¹®ÀÚ, MyFont, Brushes.LightGray, 0, 0) G.Dispose() Ga.DrawImage(BMP, New Point(obj.Left + Me.tb_secX.Text * pi + obj.RepeatX * rcnt, obj.Top + Me.tb_secY.Text * pi + obj.RepeatY * rcnt)) ', CInt(GetSize.Width * (vÀåÆò / 100)), GetSize.Height) Else G.DrawString(obj.ÃÖÁ¾¹®ÀÚ, MyFont, Brush, 0, 0) G.Dispose() Ga.DrawImage(BMP, New Point(obj.Left + Me.tb_secX.Text * pi, obj.Top + Me.tb_secY.Text * pi)) ', CInt(GetSize.Width * (vÀåÆò / 100)), GetSize.Height) End If End If Next End If Next Next Ga.Dispose() Me.PictureBox1.Image = BackScr End Sub Private Sub BindingSource1_PositionChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles BindingSource1.PositionChanged 'MsgBox("BindingSource1_PositionChanged=" & Now.ToString & "current=" & Me.BindingNavigatorPositionItem.Text & "mnoview=" & NoView) Debug.Print("BindingSource1_PositionChanged : " & Me.BindingSource1.Position) Debug.Print("½ºÅ©·Ñ¹Ù°ª ¹üÀ§°ª " & Me.VScrollBar1.Minimum & "/" & Me.VScrollBar1.Maximum) If Me.BindingSource1.Position >= 0 Then Me.VScrollBar1.Value = Me.BindingSource1.Position If Me.NoView Then Me.NoView = False Else Me.GeTviewData(BindingSource1.Position, True) End If End Sub Private Sub CheckBox1_CheckedChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles cb_jc1.CheckedChanged Me.GeTviewData(Me.BindingSource1.Position, True) End Sub Private Sub cb_bold_CheckedChanged_1(ByVal sender As System.Object, ByVal e As System.EventArgs) SetFont() End Sub Private Sub Button1_Click_2(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click If SelCon Is Nothing Then Return Dim B As New FontDialog B.Font = CType(SelCon(0), MyControlOLEDBv2.MyLabel).MyFont If B.ShowDialog() <> System.Windows.Forms.DialogResult.OK Then Return For Each a As MyControlOLEDBv2.MyLabel In SelCon a.MyFont = B.Font Next Me.ViewProperty(CType(SelCon(0), MyControlOLEDBv2.MyLabel)) Me.preview_window() End Sub Private Sub TextBox3_KeyUp(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles tb_left.KeyUp If e.KeyCode = Keys.Enter Then Me.Button5.PerformClick() End Sub Private Sub TextBox4_KeyUp(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles tb_top.KeyUp If e.KeyCode = Keys.Enter Then Me.Button9.PerformClick() End Sub Private Sub Button9_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button9.Click For Each A As Control In SelCon A.Top = IIf(IsNumeric(Me.tb_top.Text), Val(Me.tb_top.Text), A.Top) Next Me.preview_window() End Sub Private Sub Button10_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button10.Click If Not IsNumeric(Me.tb_wordwidth.Text) Then Return If SelCon Is Nothing Then MsgBox("¼±ÅÃµÈ °³Ã¼°¡ ¾ø½À´Ï´Ù", MsgBoxStyle.Critical, "È®ÀÎ") Return End If For Each A As Control In SelCon CType(A, MyControlOLEDBv2.MyLabel).ÀåÆò = CInt(Me.tb_wordwidth.Text) Next ViewProperty(SelCon(0)) Me.preview_window() End Sub Private Sub Button11_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button11.Click If Not IsNumeric(Me.tb_wordheight.Text) Then Return If SelCon Is Nothing Then MsgBox("¼±ÅÃµÈ °³Ã¼°¡ ¾ø½À´Ï´Ù", MsgBoxStyle.Critical, "È®ÀÎ") Return End If For Each A As Control In SelCon 'Me.UpdateFontWidth(CType(A, MyControlOLEDBv2.MyLabel).ÀåÆò - Val(Me.tb_pixelsize.Text)) CType(A, MyControlOLEDBv2.MyLabel).Àå³ôÀÌ = CInt(Me.tb_wordheight.Text) Next ViewProperty(SelCon(0)) Me.preview_window() End Sub Private Sub Button12_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button12.Click If Not IsNumeric(Me.tb_fsize.Text) Then MsgBox("¼ýÀÚ¸¸ ÀÔ·ÂÇϼ¼¿ä", MsgBoxStyle.Critical, "È®ÀÎ") Return End If For Each A As Control In SelCon Me.UpdateFontSize(Me.tb_fsize.Text, A) Next Me.preview_window() End Sub Private Sub Button5_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button5.Click For Each A As Control In SelCon A.Left = IIf(IsNumeric(Me.tb_left.Text), Val(Me.tb_left.Text), A.Left) Next Me.preview_window() End Sub Private Sub TextBox5_KeyUp(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles tb_wordwidth.KeyUp If e.KeyCode = Keys.Enter Then Me.Button10.PerformClick() End Sub Private Sub TextBox6_KeyUp(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles tb_wordheight.KeyUp If e.KeyCode = Keys.Enter Then Me.Button11.PerformClick() End Sub Private Sub TextBox7_KeyUp(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles tb_fsize.KeyUp If e.KeyCode = Keys.Enter Then Me.Button12.PerformClick() End Sub Private Sub TextBox8_KeyUp(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles tb_space.KeyUp If e.KeyCode = Keys.Enter Then Me.Button3.PerformClick() End Sub Private Sub Button4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button4.Click If SelCon Is Nothing Then Return For Each a As MyControlOLEDBv2.MyLabel In SelCon a.MyFont = CType(SelCon(0), MyControlOLEDBv2.MyLabel).MyFont a.ÀåÆò = CType(SelCon(0), MyControlOLEDBv2.MyLabel).ÀåÆò a.Àå³ôÀÌ = CType(SelCon(0), MyControlOLEDBv2.MyLabel).Àå³ôÀÌ a.°ø¹é = CType(SelCon(0), MyControlOLEDBv2.MyLabel).°ø¹é Next Me.ViewProperty(CType(SelCon(0), MyControlOLEDBv2.MyLabel)) Me.preview_window() End Sub Private Sub VScrollBar1_ValueChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles VScrollBar1.ValueChanged Debug.Print("ValueChange Current : " & Me.VScrollBar1.Value) End Sub Private Sub VScrollBar1_Scroll(ByVal sender As System.Object, ByVal e As System.Windows.Forms.ScrollEventArgs) Handles VScrollBar1.Scroll Debug.Print("Scroll Old:" & e.OldValue & "/ New :" & e.NewValue & "/ Current : " & Me.VScrollBar1.Value) Debug.Print("½ºÅ©·Ñ¹Ù°ª ¹üÀ§°ª " & Me.VScrollBar1.Minimum & "/" & Me.VScrollBar1.Maximum) If e.NewValue > 0 Then Me.BindingSource1.Position = e.NewValue Else Debug.Print("½ºÅ©·Ñ¹Ùvalue°ªÀÌ 0º¸´Ù ÀÛ½À´Ï´Ù. ¼Ò½ºÀÇ À§Ä¡¸¦ 0À¸·Î ¼³Á¤ÇÕ´Ï´Ù") Me.BindingSource1.Position = 0 End If ' End If End Sub Private Sub PictureBox1_MouseClick(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles PictureBox1.MouseClick Dim SelItem As New ArrayList Dim Tobj As MyControlOLEDBv2.MyLabel Tobj = Nothing For i As Integer = 0 To Me.AllLabels.GetUpperBound(0) If Me.AllLabels(i).ctl.Visible AndAlso Me.AllLabels(i).ctl.MyText <> "" AndAlso _ ((e.X >= Me.AllLabels(i).ctl.Left) And e.X <= (Me.AllLabels(i).ctl.Left + Me.AllLabels(i).ctl.GetSize.Width)) _ AndAlso ((e.Y >= Me.AllLabels(i).ctl.Top) AndAlso (e.Y <= (Me.AllLabels(i).ctl.Top + Me.AllLabels(i).ctl.GetSize.Height))) Then Tobj = Me.AllLabels(i).ctl SelItem.Add(Me.AllLabels(i).ctl) 'Exit For End If Next If Tobj Is Nothing Then Return '//¼±ÅÃµÈ°Ô ¾øÀ¸¸é ³¯¸°´Ù 'If Me.chk_multisel.Checked Then '//´ÙÁ߸ñ·Ï¿¡¼­ ¼±Åýð¡ üũµÇ¾îÀÖÀ¸¸é ¸ñ·ÏÀ» Ç¥½ÃÇØÁØ´Ù. If SelItem.Count > 1 Then Dim A As New selitem For si As Short = 1 To SelItem.Count A.ListBox1.Items.Add(CType(SelItem.Item(si - 1), MyControlOLEDBv2.MyLabel).¼³¸í) Next If A.ShowDialog() = System.Windows.Forms.DialogResult.OK Then Tobj = SelItem.Item(A.ListBox1.SelectedIndex) Else '//ĵ½½½Ã¿¡´Â ù¹øÂ° ¾ÆÅÛÀ¸·Î ÇÑ´Ù. Tobj = SelItem.Item(0) End If End If 'End If Dim Exist As Boolean = False '//¼±Åð³Ã¼¿¡ Á¸Àç¿©ºÎ If SelCon Is Nothing Then SelCon.Add(Tobj) Else If e.Button = System.Windows.Forms.MouseButtons.Right Then '//¿À¸¥ÂʹöưÀº Ãß°¡´Ù For Each obj As MyControlOLEDBv2.MyLabel In SelCon If obj.Name = Tobj.Name Then '//»èÁ¦µÈ´Ù. obj.MyForeColor = Drawing.Color.Black SelCon.Remove(obj) Exist = True Exit For End If Next If Exist = False Then SelCon.Add(Tobj) Tobj.MyForeColor = Drawing.Color.Tomato End If ElseIf e.Button = System.Windows.Forms.MouseButtons.Left Then '¿ÞÂÊŬ¸®À̸é Áö¿ì°í ´Ù½Ã ¼ÂÆÃ '//¿©±â¼­ ÄÁÆ®·ÑÀÌ ´­·ÈÀ¸¸é ÇØ´ç ±×·ìÀÇ ¾ÆÀÌÅÛ Àüü¸¦ °¡Á®¿Â´Ù. For Each SC As MyControlOLEDBv2.MyLabel In SelCon SC.MyForeColor = Drawing.Color.Black Next SelCon.Clear() SelCon.Add(Tobj) Tobj.MyForeColor = Drawing.Color.DodgerBlue If My.Computer.Keyboard.CtrlKeyDown Then '//ÄÁÆ®·ÑÀÌ ´­·¯ ºÀ¸¸é ÇØ´ç ±×·ìÀ» ÀüºÎ ã´Â´Ù. 'MsgBox(Tobj.Name) SelCon.Clear() For z As Short = 0 To Me.AllLabels.GetUpperBound(0) If Me.AllLabels(z).ctl.Name.Substring(0, 1) = Tobj.Name.Substring(0, 1) Then Me.AllLabels(z).ctl.MyForeColor = Drawing.Color.Blue SelCon.Add(Me.AllLabels(z).ctl) End If Next End If Else '//°¡¿îµ¥ Me.Button1.PerformClick() End If End If 'onlyOne = sender 'CType(sender, MyControlOLEDBv2.MyLabel). Me.cmb_controls.Text = Tobj.¼³¸í ViewProperty(Tobj) 'For Each A As MyControlOLEDBv2.MyLabel In SelCon ' A.MyForeColor = Color.DodgerBlue ' Next Me.tb_left.Focus() Me.preview_window() End Sub Private Sub PictureBox1_MouseDoubleClick(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles PictureBox1.MouseDoubleClick 'Dim Tobj As MyControlOLEDBv2.MyLabel 'Tobj = Nothing 'For i As Integer = 0 To Me.AllLabels.GetUpperBound(0) ' If Me.AllLabels(i).ctl.Visible AndAlso Me.AllLabels(i).ctl.MyText <> "" AndAlso _ ' ((e.X >= Me.AllLabels(i).ctl.Left) And e.X <= (Me.AllLabels(i).ctl.Left + Me.AllLabels(i).ctl.GetSize.Width)) _ ' AndAlso ((e.Y >= Me.AllLabels(i).ctl.Top) AndAlso (e.Y <= (Me.AllLabels(i).ctl.Top + Me.AllLabels(i).ctl.GetSize.Height))) Then ' Tobj = Me.AllLabels(i).ctl ' Exit For ' End If 'Next 'If Tobj Is Nothing Then Return '//¼±ÅÃµÈ°Ô ¾øÀ¸¸é ³¯¸°´Ù 'Dim Msg As New System.Text.StringBuilder("º¯°æÇÒ °ªÀ» ÀÔ·ÂÇϼ¼¿ä") 'Msg.AppendLine("ÁٹٲÞÀ»ÇÏ·Á¸é \n À» ÀÔ·ÂÇϼ¼¿ä") 'Msg.AppendLine("¿¹) ¼¼·Î·Î 12¸¦ Ãâ·ÂÇÏ·Á¸é 1\n2 À» ÀÔ·ÂÇϼ¼¿ä") 'Msg.AppendLine() 'Msg.AppendLine("º¯°æÇÑ °ªÀº ÇöÀçÆäÀÌÁö¿¡¸¸ Àû¿ëµË´Ï´Ù") 'Dim Val As String = InputBox(Msg.ToString, "º¯°æ", Tobj.MyText) 'If Val = "" Then Return 'Val = Val.Replace("\n", vbCrLf) 'Tobj.MyText = Val 'Me.preview_window() End Sub Private Sub cmb_controls_SelectionChangeCommitted(ByVal sender As Object, ByVal e As System.EventArgs) Handles cmb_controls.SelectionChangeCommitted For Each A As MyControlOLEDBv2.MyLabel In Me.SelCon A.MyForeColor = Drawing.Color.Black Next SelCon.Clear() SelCon.Add(AllLabels(Me.cmb_controls.SelectedIndex).ctl) AllLabels(Me.cmb_controls.SelectedIndex).ctl.MyForeColor = Drawing.Color.DodgerBlue ViewProperty(AllLabels(Me.cmb_controls.SelectedIndex).ctl) Me.preview_window() End Sub Private Sub ToolStripButton5_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) If MsgBox("ÇöÀç ½ºÅ¸ÀÏ(±âº»)À» ÀúÀåÇϽðڽÀ´Ï±î?", MsgBoxStyle.Information + MsgBoxStyle.YesNo, "½ºÅ¸ÀÏÀúÀå") = MsgBoxResult.Yes Then SAVE_STYLE() Else NOTICE("½ºÅ¸ÀÏ(±âÁ¸)ÀúÀåÀÌ Ãë¼ÒµÇ¾ú½À´Ï´Ù", Me.lb_msg) End If End Sub Private Sub ToolStripButton1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ToolStripButton1.Click Me.Close() End Sub Private Sub ¹®ÀÚÆÐÅÏ¿¬½À(ByVal srcstr As String, ByVal pname As String, ByVal log As String, ByVal S¶óº§() As MyControlOLEDBv2.MyLabel) Dim Wlen As Short = srcstr.Length : If Wlen <= 0 Then Return '//¾ø´Â ±Û±Í°¡ ¿ÓÀ»¶§ ÅÏÇØ¹ö¸°´Ù. Dim SepPos As Short = srcstr.IndexOf(";") Dim DR() As DataRow Dim CTLPOS() As String Dim CTLFONT() As String Dim CTLVISIBLE As Boolean DR = DtPattern.Select("[NAME] = '" & pname & "DESC'") If DR.GetUpperBound(0) = 0 Then '//±æÀÌÆÐÅÏÀÌ ÀÖÀ¸¸é AddLog(Admin, "¹®ÀÚÆÐÅÏ °Ë»ö ±æÀÌ=" & Wlen & " ±¸ºÐÀÚÀ§Ä¡=" & SepPos & " ¹Ìµé³×ÀÓ=" & pname, log) For Each C As MyControlOLEDBv2.MyLabel In S¶óº§ Try DR = DtPattern.Select("NAME = '" & pname & C.Name & "POS'") If DR.GetUpperBound(0) = 0 Then CTLPOS = DR(0)(1).ToString.Split(",") C.Location = New Point(CTLPOS(0), CTLPOS(1)) C.Size = New Size(CTLPOS(2), CTLPOS(3)) End If DR = DtPattern.Select("NAME = '" & pname & C.Name & "FONT'") If DR.GetUpperBound(0) = 0 Then CTLFONT = DR(0)(1).ToString.Split(",") C.MyFont = New Font(CTLFONT(0), CTLFONT(1), IIf(CTLFONT(3).ToUpper = "TRUE", FontStyle.Bold, FontStyle.Regular), GraphicsUnit.Point) C.ÀåÆò = CTLFONT(5) C.Àå³ôÀÌ = CTLFONT(6) End If DR = DtPattern.Select("NAME = '" & pname & C.Name & "VISIBLE'") If DR.GetUpperBound(0) = 0 Then CTLVISIBLE = DR(0)(1).ToString C.Visible = CType(CTLVISIBLE, Boolean) End If DR = DtPattern.Select("NAME = '" & pname & C.Name & "SPACE'") If DR.GetUpperBound(0) = 0 Then C.°ø¹é = DR(0)(1).ToString End If '//¹Ýº¹Á¤º¸È®ÀÎ Arinini.Write(Pname, TOBJ.Name & "repeat", TOBJ.Repeat & "," & TOBJ.RepeatX & "," & TOBJ.RepeatY) '//¹Ýº¹Ãâ·ÂÁ¤º¸ÀúÀå 'AddLog(Auto_Log, "¹Ýº¹¹®ÀÚ¼ÂÆ® : " & pname & C.Name & "REPEAT" & " ¸¦ °Ë»öÇÕ´Ï´Ù") 'DR = DtPattern.Select("NAME = '" & pname & C.Name & "REPEAT'") 'If DR.GetUpperBound(0) = 0 Then ' AddLog(Auto_Log, "ÇØ´ç¹Ýº¹¹®ÀÚ¸¦ ã¾Ò½À´Ï´Ù") ' CTLFONT = DR(0)(1).ToString.Split(",") ' AddLog(Auto_Log, "ÇØ´ç¹Ýº¹¹®ÀÚ¸¦ ÄÞ¸¶·Î Âɰ³¾î¼­ CTLFONT ¹è¿­¿¡ ÀúÀåÇÏ¿´½À´Ï´Ù.") ' C.Repeat = CTLFONT(0) ' AddLog(Auto_Log, "ÇØ´ç¹Ýº¹¹®ÀÚÁß 0¹øÂ°À§Ä¡°ªÀ» Àû¿ë") ' C.RepeatX = CTLFONT(1) ' AddLog(Auto_Log, "ÇØ´ç¹Ýº¹¹®ÀÚÁß 1¹øÂ°À§Ä¡°ªÀ» Àû¿ë") ' C.RepeatY = CTLFONT(2) ' AddLog(Auto_Log, "ÇØ´ç¹Ýº¹¹®ÀÚÁß 2¹øÂ°À§Ä¡°ªÀ» Àû¿ë") ' 'C.MyFont = New Font(CTLFONT(0), CTLFONT(1), IIf(CTLFONT(3).ToUpper = "TRUE", FontStyle.Bold, FontStyle.Regular), GraphicsUnit.Point) ' ' C.ÀåÆò = CTLFONT(5) ' ' C.Àå³ôÀÌ = CTLFONT(6) 'Else ' AddLog(Auto_Log, "ÇØ´ç¹Ýº¹¹®ÀÚ¸¦ ãÁö¸øÇß½À´Ï´Ù.") 'End If C.Tag &= "C" Catch ex As Exception AddLog(Admin, "¹®ÀÚÆÐÅÏ¿À·ù ±æÀÌ=" & Wlen & " Message=" & ex.Message.ToString, log) End Try Next Else AddLog(Admin, "¹®ÀÚÆÐÅϺÒÀÏÄ¡ ±æÀÌ=" & Wlen & " ¹®ÀÚ¿­=" & srcstr, log) Me.LOAD_STYLE(S¶óº§(0).DIV) End If End Sub Private Sub ±âº»ToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) If MsgBox("ÇöÀç ½ºÅ¸ÀÏ(±âº»)À» ÀúÀåÇϽðڽÀ´Ï±î?", MsgBoxStyle.Information + MsgBoxStyle.YesNo, "½ºÅ¸ÀÏÀúÀå") = MsgBoxResult.Yes Then SAVE_STYLE() Else NOTICE("½ºÅ¸ÀÏ(±âÁ¸)ÀúÀåÀÌ Ãë¼ÒµÇ¾ú½À´Ï´Ù", Me.lb_msg) End If End Sub Private Sub SaveReadLayOut(ByVal read As Boolean) '//ÇöÀç È­¸é±¸¼ºÀ» °¡·Î/¼¼·Î °áÁ¤ÇÕ´Ï´Ù. '//iniÆÄÀÏ¿¡ÀúÀåÇÑ´Ù. ¼½¼Ç¸íÀº pagetype0 ,pagetyp1 0Àº ¼¼·Î 1Àº °¡·Î´Ù Dim ini As New MyINI2(DrStyle.FILE) Dim Secname As String = "pagetype" & Me.cmb_landscape.SelectedIndex If read = False Then ini.Write(Secname, "tablelayoutpanel1loc", Me.TableLayoutPanel1.Left & "," & Me.TableLayoutPanel1.Top) ini.Write(Secname, "tablelayoutpanel1size", Me.TableLayoutPanel1.Width & "," & Me.TableLayoutPanel1.Height) ini.Write(Secname, "PictureBox1loc", Me.PictureBox1.Left & "," & Me.PictureBox1.Top) ini.Write(Secname, "PictureBox1size", Me.PictureBox1.Width & "," & Me.PictureBox1.Height) ini.Write(Secname, "TabControl1loc", Me.TabControl1.Left & "," & Me.TabControl1.Top) ini.Write(Secname, "TabControl1size", Me.TabControl1.Width & "," & Me.TabControl1.Height) ini.Write(Secname, "GroupBox3loc", Me.GroupBox3.Left & "," & Me.GroupBox3.Top) ini.Write(Secname, "GroupBox3size", Me.GroupBox3.Width & "," & Me.GroupBox3.Height) ini.Write(Secname, "GroupBox2loc", Me.GroupBox2.Left & "," & Me.GroupBox2.Top) ini.Write(Secname, "GroupBox2size", Me.GroupBox2.Width & "," & Me.GroupBox2.Height) ini.Write(Secname, "cmb_styleloc", Me.cmb_style.Left & "," & Me.cmb_style.Top) ini.Write(Secname, "cmb_stylesize", Me.cmb_style.Width & "," & Me.cmb_style.Height) ini.Write(Secname, "ToolStrip2loc", Me.ToolStrip2.Left & "," & Me.ToolStrip2.Top) ini.Write(Secname, "mesize", Me.Width & "," & Me.Height) Else '//¿©±â´Â Àд ºÎºÐ If Me.cmb_landscape.SelectedIndex = 0 Then '//¼¼·Î Me.pDoc.DefaultPageSettings.Landscape = False TableLayoutPanel1.Location = New Point(ini.Read(Secname, "tablelayoutpanel1loc", "0,31").Split(",")(0), ini.Read(Secname, "tablelayoutpanel1loc", "0,31").Split(",")(1)) TableLayoutPanel1.Size = New Size(ini.Read(Secname, "tablelayoutpanel1size", "297,522").Split(",")(0), ini.Read(Secname, "tablelayoutpanel1size", "297,522").Split(",")(1)) PictureBox1.Location = New Point(ini.Read(Secname, "PictureBox1loc", "3,3").Split(",")(0), ini.Read(Secname, "PictureBox1loc", "3,3").Split(",")(1)) PictureBox1.Size = New Size(ini.Read(Secname, "PictureBox1size", "270,479").Split(",")(0), ini.Read(Secname, "PictureBox1size", "270,479").Split(",")(1)) TabControl1.Location = New Point(ini.Read(Secname, "TabControl1loc", "303,34").Split(",")(0), ini.Read(Secname, "TabControl1loc", "303,34").Split(",")(1)) TabControl1.Size = New Size(ini.Read(Secname, "TabControl1size", "279,519").Split(",")(0), ini.Read(Secname, "TabControl1size", "279,519").Split(",")(1)) TabControl2.Location = New Point(ini.Read(Secname, "TabControl2loc", "16,246").Split(",")(0), ini.Read(Secname, "TabControl2loc", "16,246").Split(",")(1)) GroupBox3.Location = New Point(ini.Read(Secname, "GroupBox3loc", "11,368").Split(",")(0), ini.Read(Secname, "GroupBox3loc", "11,368").Split(",")(1)) GroupBox3.Size = New Size(ini.Read(Secname, "GroupBox3size", "246,78").Split(",")(0), ini.Read(Secname, "GroupBox3size", "246,78").Split(",")(1)) GroupBox2.Location = New Point(ini.Read(Secname, "GroupBox2loc", "11,170").Split(",")(0), ini.Read(Secname, "GroupBox2loc", "11,170").Split(",")(1)) GroupBox2.Size = New Size(ini.Read(Secname, "GroupBox2size", "245,192").Split(",")(0), ini.Read(Secname, "GroupBox2size", "245,192").Split(",")(1)) cmb_style.Location = New Point(ini.Read(Secname, "cmb_styleloc", "11,18").Split(",")(0), ini.Read(Secname, "cmb_styleloc", "11,18").Split(",")(1)) cmb_style.Size = New Size(ini.Read(Secname, "cmb_stylesize", "245,146").Split(",")(0), ini.Read(Secname, "cmb_stylesize", "245,146").Split(",")(1)) ToolStrip2.Location = New Point(ini.Read(Secname, "ToolStrip2loc", "3,451").Split(",")(0), ini.Read(Secname, "ToolStrip2loc", "3,451").Split(",")(1)) Me.Size = New Size(ini.Read(Secname, "mesize", "588,632").Split(",")(0), ini.Read(Secname, "mesize", "588,632").Split(",")(1)) Else Me.pDoc.DefaultPageSettings.Landscape = 1 TableLayoutPanel1.Location = New Point(ini.Read(Secname, "tablelayoutpanel1loc", "0,31").Split(",")(0), ini.Read(Secname, "tablelayoutpanel1loc", "0,31").Split(",")(1)) TableLayoutPanel1.Size = New Size(ini.Read(Secname, "tablelayoutpanel1size", "710,292").Split(",")(0), ini.Read(Secname, "tablelayoutpanel1size", "710,292").Split(",")(1)) PictureBox1.Location = New Point(ini.Read(Secname, "PictureBox1loc", "325,3").Split(",")(0), ini.Read(Secname, "PictureBox1loc", "325,3").Split(",")(1)) PictureBox1.Size = New Size(ini.Read(Secname, "PictureBox1size", "355,200").Split(",")(0), ini.Read(Secname, "PictureBox1size", "355,200").Split(",")(1)) TabControl1.Location = New Point(ini.Read(Secname, "TabControl1loc", "3,326").Split(",")(0), ini.Read(Secname, "TabControl1loc", "3,326").Split(",")(1)) TabControl1.Size = New Size(ini.Read(Secname, "TabControl1size", "711,228").Split(",")(0), ini.Read(Secname, "TabControl1size", "711,228").Split(",")(1)) TabControl2.Location = New Point(ini.Read(Secname, "TabControl2loc", "265,1").Split(",")(0), ini.Read(Secname, "TabControl2loc", "265,1").Split(",")(1)) GroupBox3.Location = New Point(ini.Read(Secname, "GroupBox3loc", "513,6").Split(",")(0), ini.Read(Secname, "GroupBox3loc", "513,6").Split(",")(1)) GroupBox3.Size = New Size(ini.Read(Secname, "GroupBox3size", "184,78").Split(",")(0), ini.Read(Secname, "GroupBox3size", "184,78").Split(",")(1)) GroupBox2.Location = New Point(ini.Read(Secname, "GroupBox2loc", "262,6").Split(",")(0), ini.Read(Secname, "GroupBox2loc", "262,6").Split(",")(1)) GroupBox2.Size = New Size(ini.Read(Secname, "GroupBox2size", "245,192").Split(",")(0), ini.Read(Secname, "GroupBox2size", "245,192").Split(",")(1)) cmb_style.Location = New Point(ini.Read(Secname, "cmb_styleloc", "11,18").Split(",")(0), ini.Read(Secname, "cmb_styleloc", "11,18").Split(",")(1)) cmb_style.Size = New Size(ini.Read(Secname, "cmb_stylesize", "245,139").Split(",")(0), ini.Read(Secname, "cmb_stylesize", "245,139").Split(",")(1)) ToolStrip2.Location = New Point(ini.Read(Secname, "ToolStrip2loc", "3,159").Split(",")(0), ini.Read(Secname, "ToolStrip2loc", "3,159").Split(",")(1)) Me.Size = New Size(ini.Read(Secname, "mesize", "730,643").Split(",")(0), ini.Read(Secname, "mesize", "730,643").Split(",")(1)) End If End If 'MsgBox(Me.PictureBox1.Size.ToString) End Sub Private Sub bt_print_ButtonClick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles bt_print.ButtonClick Me.Print() End Sub Private Sub bt_prnpreview_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles bt_prnpreview.Click Me.Print_Preview() End Sub Private Sub ToolStripButton2_Click_1(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ToolStripButton2.Click Process.Start(My.Application.Info.DirectoryPath & "\help\printform1.htm") End Sub Private Sub cm_styleeditoolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles cm_styleedit.Click StyleEdit.ListIndex = Me.cmb_style.SelectedIndex StyleEdit.Path = Me.StyleDir StyleEdit.Show() End Sub Private Sub bt_canvasD_MouseDown(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles bt_canvasD.MouseDown, bt_canvasL.MouseDown, bt_canvasR.MouseDown, bt_canvasU.MouseDown '//¾Æ·¡·ç If e.Button = System.Windows.Forms.MouseButtons.Right Then Select Case sender.name.ToString.ToUpper Case "BT_CANVASD" Me.PictureBox1.Top += 5 Case "BT_CANVASU" Me.PictureBox1.Top -= 5 Case "BT_CANVASR" Me.PictureBox1.Left += 5 Case "BT_CANVASL" Me.PictureBox1.Left -= 5 End Select End If End Sub Private Sub cmb_jisun_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles cmb_jisun.SelectedIndexChanged If Me.cmb_jisun.SelectedIndex > 0 Then Me.StatusStrip1.BackColor = Drawing.Color.Thistle Else Me.StatusStrip1.BackColor = Drawing.Color.White End If End Sub Private Sub ToolStripLabel2_ButtonClick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ToolStripLabel2.ButtonClick If MsgBox("ÇöÀç ½ºÅ¸ÀÏ(±âº»)À» ÀúÀåÇϽðڽÀ´Ï±î?", MsgBoxStyle.Information + MsgBoxStyle.YesNo, "½ºÅ¸ÀÏÀúÀå") = MsgBoxResult.Yes Then SAVE_STYLE() Else NOTICE("½ºÅ¸ÀÏ(±âÁ¸)ÀúÀåÀÌ Ãë¼ÒµÇ¾ú½À´Ï´Ù", Me.lb_msg) End If End Sub Private Sub tb_ntype_MouseEnter(ByVal sender As Object, ByVal e As System.EventArgs) Handles tb_ntype.MouseEnter Me.tb_ntype.Focus() Me.tb_ntype.SelectAll() End Sub Private Sub BindingNavigatorPositionItem_MouseEnter(ByVal sender As Object, ByVal e As System.EventArgs) Handles BindingNavigatorPositionItem.MouseEnter Me.BindingNavigatorPositionItem.Focus() Me.BindingNavigatorPositionItem.SelectAll() End Sub Private Sub cmb_style_SelectionChangeCommitted(ByVal sender As Object, ByVal e As System.EventArgs) Handles cmb_style.SelectionChangeCommitted '//½ºÅ¸ÀÏÀ» Á÷Á¢ ¼±ÅÃÇÞÀ»¶§ ±âº»idx°ªÀ» 0 À¸·ÎÇÑ´Ù. 'MsgBox("½ºÅ¸ÀÏÁ÷Á¢¼±ÅÃ") FirstIdx = 0 End Sub Private Sub ToolStripTextBox1_KeyUp(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles tb_ntype.KeyUp If e.KeyCode = Keys.Enter Then If Me.cmb_sep.SelectedIndex = 1 Then NOTICE("ºÐ¸®»óÅ¿¡¼­´Â ¹øÈ£ÁöÁ¤ÀÌ ºÒ°¡´ÉÇÕ´Ï´Ù", Drawing.Color.Red, Me.lb_msg) Else If Me.cmb_controls.Text.IndexOf("°¨µ¶ÀÚ") > -1 Then ¹øÈ£Çü½ÄÁöÁ¤°¨µ¶ÀÚ(Me.tb_ntype.Text) Else ¹øÈ£Çü½ÄÁöÁ¤(Me.tb_ntype.Text) End If End If Me.preview_window() End If End Sub #End Region Private Sub PictureBox1_MouseMove(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles PictureBox1.MouseMove 'Me.Text = e.X & "/" & e.Y If My.Computer.Keyboard.CtrlKeyDown = True AndAlso My.Computer.Keyboard.AltKeyDown = True Then '//¼±ÅÃµÈ ÄÁÆ®·ÑÀ» ¸¶¿ì½ºÀ§Ä¡·Î À̵¿ÇÑ´Ù. If SelCon Is Nothing OrElse SelCon.Count < 1 Then Exit Sub For Each sender1 As MyControlOLEDBv2.MyLabel In SelCon sender1.Left = e.X - (sender1.Width / 2) sender1.Top = e.Y + (sender1.Height / 2) Next Me.preview_window() End If End Sub Public Sub Refresh_Drawlist() '//;¶óÀÎÇÏ°í ¹Ú½º¸¦ Àо ¸®½ºÆ®¹Ú½º¿¡ Me.ListBox1.Items.Clear() Dim I As Short = 0 For Each Rect As S_Line In Draw_Line Me.ListBox1.Items.Add("¼±(" & Rect.X & "," & Rect.Y & "," & Rect.X2 & "," & Rect.Y2 & "," & Rect.Field & "):" & I) I += 1 Next I = 0 For Each Rect As S_Box In Draw_Box Me.ListBox1.Items.Add("¹Ú½º(" & Rect.X & "," & Rect.Y & "," & Rect.Width & "," & Rect.Height & "," & Rect.Field & "):" & I) I += 1 Next I = 0 For Each Rect As S_Circle In Draw_Circle Me.ListBox1.Items.Add("¿ø(" & Rect.X & "," & Rect.Y & "," & Rect.Width & "," & Rect.Height & "," & Rect.Field & "):" & I) I += 1 Next I = 0 For Each Rect As S_Image In Draw_Image Me.ListBox1.Items.Add("±×¸²(" & Rect.X & "," & Rect.Y & "," & Rect.Width & "," & Rect.Height & "," & Rect.Field & "):" & I) Me.ListBox1.Items.Add("±×¸²À§Ä¡(" & Rect.FileName & "):" & I) I += 1 Next I = 0 For Each Rect As S_QRCode In Draw_QRcode Me.ListBox1.Items.Add("QR(" & Rect.X & "," & Rect.Y & "," & Rect.Width & "," & Rect.Height & "," & Rect.Field & "):" & I) I += 1 Next I = 0 For Each Rect As S_QRCode1 In Draw_QRcode1 Me.ListBox1.Items.Add("RQR1(" & Rect.X & "," & Rect.Y & "," & Rect.Width & "," & Rect.Height & "," & Rect.Field & "):" & I) I += 1 Next I = 0 For Each Rect As S_Arrow In Draw_Arrow Dim sName As String = "ARR({0})({1},{2},{3},{4},{5},{6}):" & I sName = String.Format(sName, Rect.Direction, Rect.RectX, Rect.RectY, Rect.RectW, Rect.RectH, Rect.TriWidth, Rect.TriHeight) Me.ListBox1.Items.Add(sName) I += 1 Next preview_window() End Sub Private Sub Button13_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button13.Click '//¼±Ãß°¡ Dim NewLine As S_Line NewLine.PenColor = Drawing.Color.Black NewLine.PenWidth = 3 NewLine.X = Draw_Line.Count * 10 NewLine.Y = 10 NewLine.X2 = 100 + Draw_Line.Count * 10 NewLine.Y2 = NewLine.X2 NewLine.Field = "" Draw_Line.Add(NewLine) Refresh_Drawlist() End Sub Private Sub Button15_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button15.Click '//¼±Ãß°¡ Dim NewLine As S_Box NewLine.PenColor = Drawing.Color.Black NewLine.PenWidth = 3 NewLine.X = Draw_Box.Count * 10 NewLine.Y = Draw_Box.Count * 10 NewLine.Width = 100 + Draw_Box.Count * 10 NewLine.Height = NewLine.Width NewLine.Field = "" Draw_Box.Add(NewLine) Refresh_Drawlist() End Sub Private Sub ListBox1_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ListBox1.SelectedIndexChanged If Me.ListBox1.SelectedIndex < 0 Then Return cmb_connfield.Enabled = True Select Case Me.ListBox1.Text.Substring(0, 1) Case "¼±" Dim Line As S_Line = Draw_Line(Me.ListBox1.Text.Split(":")(1)) Me.bt_pencolor.BackColor = Line.PenColor Me.tb_pensize.Text = Line.PenWidth Me.tb_dx.Text = Line.X Me.tb_dy.Text = Line.Y Me.tb_dw.Text = Line.X2 Me.tb_dh.Text = Line.Y2 Me.cmb_connfield.Text = Line.Field Case "¹Ú" Dim Line As S_Box = Draw_Box(Me.ListBox1.Text.Split(":")(1)) Me.bt_pencolor.BackColor = Line.PenColor Me.tb_pensize.Text = Line.PenWidth Me.tb_dx.Text = Line.X Me.tb_dy.Text = Line.Y Me.tb_dw.Text = Line.Width Me.tb_dh.Text = Line.Height Me.cmb_connfield.Text = Line.Field Case "¿ø" Dim Line As S_Circle = Draw_Circle(Me.ListBox1.Text.Split(":")(1)) Me.bt_pencolor.BackColor = Line.PenColor Me.tb_pensize.Text = Line.PenWidth Me.tb_dx.Text = Line.X Me.tb_dy.Text = Line.Y Me.tb_dw.Text = Line.Width Me.tb_dh.Text = Line.Height Me.cmb_connfield.Text = Line.Field Case "±×" Dim Line As S_Image = Draw_Image(Me.ListBox1.Text.Split(":")(1)) 'Me.bt_pencolor.BackColor = Line.PenColor 'Me.tb_pensize.Text = Line.PenWidth Me.tb_dx.Text = Line.X Me.tb_dy.Text = Line.Y Me.tb_dw.Text = Line.Width Me.tb_dh.Text = Line.Height Me.tb_image.Text = Line.FileName Me.cmb_connfield.Text = Line.Field Case "Q" Dim Line As S_QRCode = Draw_QRcode(Me.ListBox1.Text.Split(":")(1)) 'Me.bt_pencolor.BackColor = Line.PenColor 'Me.tb_pensize.Text = Line.PenWidth Me.tb_dx.Text = Line.X Me.tb_dy.Text = Line.Y Me.tb_dw.Text = Line.Width Me.tb_dh.Text = Line.Height Me.cmb_connfield.Text = Line.Field Case "R" Dim Line As S_QRCode1 = Draw_QRcode1(Me.ListBox1.Text.Split(":")(1)) 'Me.bt_pencolor.BackColor = Line.PenColor 'Me.tb_pensize.Text = Line.PenWidth Me.tb_dx.Text = Line.X Me.tb_dy.Text = Line.Y Me.tb_dw.Text = Line.Width Me.tb_dh.Text = Line.Height Me.cmb_connfield.Text = Line.Field Case "A" '//170711 Dim Line As S_Arrow = Draw_Arrow(Me.ListBox1.Text.Split(":")(1)) Me.bt_pencolor.BackColor = Line.PenColor Me.tb_pensize.Text = Line.PenWidth Me.tb_dx.Text = Line.RectX Me.tb_dy.Text = Line.RectY Me.tb_dw.Text = Line.RectW Me.tb_dh.Text = Line.RectH Me.tb_tx.Text = Line.TriWidth Me.tb_ty.Text = Line.TriHeight Me.tb_tx.Enabled = True Me.tb_ty.Enabled = True 'Me.cmb_connfield.Text = Line.Field cmb_connfield.SelectedIndex = 5 + Line.Direction End Select End Sub Private Sub tb_pensize_KeyDown(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles tb_pensize.KeyDown, tb_dx.KeyDown, tb_dy.KeyDown, tb_dw.KeyDown, tb_dh.KeyDown, tb_image.KeyDown If Me.ListBox1.SelectedIndex < 0 Then Return Dim SI As Short = Me.ListBox1.SelectedIndex If e.KeyCode = Keys.Enter Then '//»õ·Î¸¸µé¾î¼­ ÀúÀåÇÑ´Ù. Set_NewDraw() Me.Refresh_Drawlist() Me.ListBox1.SelectedIndex = SI End If End Sub Private Sub Set_NewDraw() Select Case Me.ListBox1.Text.Substring(0, 1) Case "A" Dim Line As S_Arrow = Draw_Arrow(Me.ListBox1.Text.Split(":")(1)) Line.PenColor = Me.bt_pencolor.BackColor Line.PenWidth = Me.tb_pensize.Text Line.RectX = Me.tb_dx.Text Line.RectY = Me.tb_dy.Text Line.RectW = Me.tb_dw.Text Line.RectH = Me.tb_dh.Text Line.Direction = Me.cmb_connfield.SelectedIndex - 5 Line.TriHeight = Me.tb_ty.Text Line.TriWidth = Me.tb_tx.Text Draw_Arrow(Me.ListBox1.Text.Split(":")(1)) = Line Case "¼±" Dim Line As New S_Line Line.PenColor = Me.bt_pencolor.BackColor Line.PenWidth = Me.tb_pensize.Text Line.X = Me.tb_dx.Text Line.Y = Me.tb_dy.Text Line.X2 = Me.tb_dw.Text Line.Y2 = Me.tb_dh.Text Line.Field = Me.cmb_connfield.Text Draw_Line(Me.ListBox1.Text.Split(":")(1)) = Line Case "¹Ú" Dim Line As New S_Box Line.PenColor = Me.bt_pencolor.BackColor Line.PenWidth = Me.tb_pensize.Text Line.X = Me.tb_dx.Text Line.Y = Me.tb_dy.Text Line.Width = Me.tb_dw.Text Line.Height = Me.tb_dh.Text Line.Field = Me.cmb_connfield.Text Draw_Box(Me.ListBox1.Text.Split(":")(1)) = Line Case "¿ø" Dim Line As New S_Circle Line.PenColor = Me.bt_pencolor.BackColor Line.PenWidth = Me.tb_pensize.Text Line.X = Me.tb_dx.Text Line.Y = Me.tb_dy.Text Line.Width = Me.tb_dw.Text Line.Height = Me.tb_dh.Text Line.Field = Me.cmb_connfield.Text Draw_Circle(Me.ListBox1.Text.Split(":")(1)) = Line Case "±×" Dim Line As New S_Image 'Line.PenColor = Me.bt_pencolor.BackColor 'Line.PenWidth = Me.tb_pensize.Text Line.X = Me.tb_dx.Text Line.Y = Me.tb_dy.Text Line.Width = Me.tb_dw.Text Line.Height = Me.tb_dh.Text Line.FileName = Me.tb_image.Text Line.Field = Me.cmb_connfield.Text Draw_Image(Me.ListBox1.Text.Split(":")(1)) = Line Case "Q" Dim Line As New S_QRCode 'Line.PenColor = Me.bt_pencolor.BackColor 'Line.PenWidth = Me.tb_pensize.Text Line.X = Me.tb_dx.Text Line.Y = Me.tb_dy.Text Line.Width = Me.tb_dw.Text Line.Height = Me.tb_dh.Text Line.Field = Me.cmb_connfield.Text Draw_QRcode(Me.ListBox1.Text.Split(":")(1)) = Line Case "R" Dim Line As New S_QRCode1 'Line.PenColor = Me.bt_pencolor.BackColor 'Line.PenWidth = Me.tb_pensize.Text Line.X = Me.tb_dx.Text Line.Y = Me.tb_dy.Text Line.Width = Me.tb_dw.Text Line.Height = Me.tb_dh.Text Line.Field = Me.cmb_connfield.Text Draw_QRcode1(Me.ListBox1.Text.Split(":")(1)) = Line End Select End Sub Private Sub bt_pencolor_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles bt_pencolor.Click Dim CD As New ColorDialog CD.Color = Me.bt_pencolor.BackColor If CD.ShowDialog <> System.Windows.Forms.DialogResult.OK Then Return Me.bt_pencolor.BackColor = CD.Color Set_NewDraw() End Sub Private Sub SaveDrawData(ByVal read As Boolean) '//ÇöÀç È­¸é±¸¼ºÀ» °¡·Î/¼¼·Î °áÁ¤ÇÕ´Ï´Ù. '//iniÆÄÀÏ¿¡ÀúÀåÇÑ´Ù. ¼½¼Ç¸íÀº pagetype0 ,pagetyp1 0Àº ¼¼·Î 1Àº °¡·Î´Ù Dim ini As New MyINI2(DrStyle.FILE) Dim bname As String = "DrawBox" Dim lname As String = "DrawLine" Dim sname As String = "DrawCircle" Dim pname As String = "DrawImage" Dim qname As String = "DrawQRcode" Dim rname As String = "DrawQRcode1" Dim aname As String = "DrawArrow" Dim bcnt, lcnt, scnt, pcnt, qcnt, rcnt, acnt As Short If read = False Then ini.Write(bname, "Count", Draw_Box.Count) For i As Short = 1 To Draw_Box.Count '//¸ðµÎµ¹¾Æ¼­ ÀúÀåÇÑ´Ù. Dim L As S_Box = Draw_Box(i - 1) ini.Write(bname, "box" & i & "pencolor", L.PenColor.ToArgb) ini.Write(bname, "box" & i & "pensize", L.PenWidth) ini.Write(bname, "box" & i & "x", L.X) ini.Write(bname, "box" & i & "y", L.Y) ini.Write(bname, "box" & i & "x2", L.Width) ini.Write(bname, "box" & i & "y2", L.Height) ini.Write(bname, "box" & i & "field", L.Field) Next ini.Write(sname, "Count", Draw_Circle.Count) For i As Short = 1 To Draw_Circle.Count '//¸ðµÎµ¹¾Æ¼­ ÀúÀåÇÑ´Ù. Dim L As S_Circle = Draw_Circle(i - 1) ini.Write(sname, "Circle" & i & "pencolor", L.PenColor.ToArgb) ini.Write(sname, "Circle" & i & "pensize", L.PenWidth) ini.Write(sname, "Circle" & i & "x", L.X) ini.Write(sname, "Circle" & i & "y", L.Y) ini.Write(sname, "Circle" & i & "x2", L.Width) ini.Write(sname, "Circle" & i & "y2", L.Height) ini.Write(sname, "Circle" & i & "field", L.Field) Next ini.Write(lname, "Count", Draw_Line.Count) For i As Short = 1 To Draw_Line.Count '//¸ðµÎµ¹¾Æ¼­ ÀúÀåÇÑ´Ù. Dim L As S_Line = Draw_Line(i - 1) ini.Write(lname, "line" & i & "pencolor", L.PenColor.ToArgb) ini.Write(lname, "line" & i & "pensize", L.PenWidth) ini.Write(lname, "line" & i & "x", L.X) ini.Write(lname, "line" & i & "y", L.Y) ini.Write(lname, "line" & i & "x2", L.X2) ini.Write(lname, "line" & i & "y2", L.Y2) ini.Write(lname, "line" & i & "field", L.Field) Next ini.Write(pname, "Count", Draw_Image.Count) For i As Short = 1 To Draw_Image.Count '//¸ðµÎµ¹¾Æ¼­ ÀúÀåÇÑ´Ù. Dim L As S_Image = Draw_Image(i - 1) 'ini.Write(pname, "Image" & i & "pencolor", L.PenColor.ToArgb) 'ini.Write(pname, "Image" & i & "pensize", L.PenWidth) ini.Write(pname, "Image" & i & "x", L.X) ini.Write(pname, "Image" & i & "y", L.Y) ini.Write(pname, "Image" & i & "x2", L.Width) ini.Write(pname, "Image" & i & "y2", L.Height) ini.Write(pname, "Image" & i & "location", L.FileName) ini.Write(pname, "Image" & i & "field", L.Field) Next ini.Write(qname, "Count", Draw_QRcode.Count) For i As Short = 1 To Draw_QRcode.Count '//¸ðµÎµ¹¾Æ¼­ ÀúÀåÇÑ´Ù. Dim L As S_QRCode = Draw_QRcode(i - 1) 'ini.Write(pname, "Image" & i & "pencolor", L.PenColor.ToArgb) 'ini.Write(pname, "Image" & i & "pensize", L.PenWidth) ini.Write(qname, "qrcode" & i & "x", L.X) ini.Write(qname, "qrcode" & i & "y", L.Y) ini.Write(qname, "qrcode" & i & "x2", L.Width) ini.Write(qname, "qrcode" & i & "y2", L.Height) ini.Write(qname, "qrcode" & i & "field", L.Field) Next ini.Write(rname, "Count", Draw_QRcode1.Count) For i As Short = 1 To Draw_QRcode1.Count '//¸ðµÎµ¹¾Æ¼­ ÀúÀåÇÑ´Ù. Dim L As S_QRCode1 = Draw_QRcode1(i - 1) 'ini.Write(pname, "Image" & i & "pencolor", L.PenColor.ToArgb) 'ini.Write(pname, "Image" & i & "pensize", L.PenWidth) ini.Write(rname, "rqrcode1" & i & "x", L.X) ini.Write(rname, "rqrcode1" & i & "y", L.Y) ini.Write(rname, "rqrcode1" & i & "x2", L.Width) ini.Write(rname, "rqrcode1" & i & "y2", L.Height) ini.Write(rname, "rqrcode1" & i & "field", L.Field) Next ini.Write(aname, "Count", Draw_Arrow.Count) For i As Short = 1 To Draw_Arrow.Count '//¸ðµÎµ¹¾Æ¼­ ÀúÀåÇÑ´Ù. Dim L As S_Arrow = Draw_Arrow(i - 1) ini.Write(aname, "arrow" & i & "direction", L.Direction.ToString()) ini.Write(aname, "arrow" & i & "pencolor", L.PenColor.ToArgb) '//ini.Write(pname, "arrow" & i & "fillcolor", L.FillColor.ToArgb) ini.Write(aname, "arrow" & i & "pensize", L.PenWidth) ini.Write(aname, "arrow" & i & "tx", L.TriWidth) ini.Write(aname, "arrow" & i & "ty", L.TriHeight) ini.Write(aname, "arrow" & i & "x", L.RectX) ini.Write(aname, "arrow" & i & "y", L.RectY) ini.Write(aname, "arrow" & i & "x2", L.RectW) ini.Write(aname, "arrow" & i & "y2", L.RectH) ini.Write(aname, "arrow" & i & "field", L.Field) Next Else '//¿©±â´Â Àд ºÎºÐ Draw_Box.Clear() Draw_Line.Clear() Draw_Circle.Clear() Draw_Image.Clear() Draw_QRcode.Clear() Draw_QRcode1.Clear() Draw_Arrow.Clear() bcnt = ini.Read(bname, "Count", 0) For i As Short = 1 To bcnt '//¸ðµÎµ¹¾Æ¼­ ÀúÀåÇÑ´Ù. Dim L As New S_Box L.PenColor = Drawing.Color.FromArgb(ini.Read(bname, "box" & i & "pencolor", 0)) L.PenWidth = ini.Read(bname, "box" & i & "pensize", 3) L.X = ini.Read(bname, "box" & i & "x", 0) L.Y = ini.Read(bname, "box" & i & "y", 0) L.Width = ini.Read(bname, "box" & i & "x2", 10) L.Height = ini.Read(bname, "box" & i & "y2", 10) L.Field = ini.Read(bname, "box" & i & "field", "") Draw_Box.Add(L) Next scnt = ini.Read(sname, "Count", 0) For i As Short = 1 To scnt '//¸ðµÎµ¹¾Æ¼­ ÀúÀåÇÑ´Ù. Dim L As New S_Circle L.PenColor = Drawing.Color.FromArgb(ini.Read(sname, "Circle" & i & "pencolor", 0)) L.PenWidth = ini.Read(sname, "Circle" & i & "pensize", 3) L.X = ini.Read(sname, "Circle" & i & "x", 0) L.Y = ini.Read(sname, "Circle" & i & "y", 0) L.Width = ini.Read(sname, "Circle" & i & "x2", 10) L.Height = ini.Read(sname, "Circle" & i & "y2", 10) L.Field = ini.Read(sname, "Circle" & i & "field", "") Draw_Circle.Add(L) Next lcnt = ini.Read(lname, "Count", 0) For i As Short = 1 To lcnt '//¸ðµÎµ¹¾Æ¼­ ÀúÀåÇÑ´Ù. Dim L As New S_Line L.PenColor = Drawing.Color.FromArgb(ini.Read(lname, "line" & i & "pencolor", 0)) L.PenWidth = ini.Read(lname, "line" & i & "pensize", 3) L.X = ini.Read(lname, "line" & i & "x", 0) L.Y = ini.Read(lname, "line" & i & "y", 0) L.X2 = ini.Read(lname, "line" & i & "x2", 10) L.Y2 = ini.Read(lname, "line" & i & "y2", 10) L.Field = ini.Read(lname, "line" & i & "field", "") Draw_Line.Add(L) Next pcnt = ini.Read(pname, "Count", 0) For i As Short = 1 To pcnt '//¸ðµÎµ¹¾Æ¼­ ÀúÀåÇÑ´Ù. Dim L As New S_Image 'L.PenColor = Color.FromArgb(ini.Read(pname, "Circle" & i & "pencolor", 0)) 'L.PenWidth = ini.Read(sname, "Circle" & i & "pensize", 3) L.X = ini.Read(pname, "Image" & i & "x", 0) L.Y = ini.Read(pname, "Image" & i & "y", 0) L.Width = ini.Read(pname, "Image" & i & "x2", 10) L.Height = ini.Read(pname, "Image" & i & "y2", 10) L.FileName = ini.Read(pname, "Image" & i & "location", 10) L.Field = ini.Read(pname, "Image" & i & "field", "") Draw_Image.Add(L) Next qcnt = ini.Read(qname, "Count", 0) For i As Short = 1 To qcnt '//¸ðµÎµ¹¾Æ¼­ ÀúÀåÇÑ´Ù. Dim L As New S_QRCode 'L.PenColor = Color.FromArgb(ini.Read(pname, "Circle" & i & "pencolor", 0)) 'L.PenWidth = ini.Read(sname, "Circle" & i & "pensize", 3) L.X = ini.Read(qname, "qrcode" & i & "x", 0) L.Y = ini.Read(qname, "qrcode" & i & "y", 0) L.Width = ini.Read(qname, "qrcode" & i & "x2", 10) L.Height = ini.Read(qname, "qrcode" & i & "y2", 10) L.Field = ini.Read(qname, "qrcode" & i & "field", "") Draw_QRcode.Add(L) Next rcnt = ini.Read(rname, "Count", 0) For i As Short = 1 To rcnt '//¸ðµÎµ¹¾Æ¼­ ÀúÀåÇÑ´Ù. Dim L As New S_QRCode1 'L.PenColor = Color.FromArgb(ini.Read(pname, "Circle" & i & "pencolor", 0)) 'L.PenWidth = ini.Read(sname, "Circle" & i & "pensize", 3) L.X = ini.Read(rname, "rqrcode1" & i & "x", 0) L.Y = ini.Read(rname, "rqrcode1" & i & "y", 0) L.Width = ini.Read(rname, "rqrcode1" & i & "x2", 10) L.Height = ini.Read(rname, "rqrcode1" & i & "y2", 10) L.Field = ini.Read(rname, "rqrcode1" & i & "field", "") Draw_QRcode1.Add(L) Next acnt = ini.Read(aname, "Count", 0) For i As Short = 1 To acnt '//¸ðµÎµ¹¾Æ¼­ ÀúÀåÇÑ´Ù. Dim L As New S_Arrow L.Direction = ini.Read(aname, "arrow" & i & "direction", 0) L.PenColor = System.Drawing.Color.FromArgb(ini.Read(aname, "arrow" & i & "pencolor", 0)) L.PenWidth = ini.Read(aname, "arrow" & i & "pensize", 3) ' L.FillColor = System.Drawing.Color.FromArgb(ini.Read(aname, "arrow" & i & "fillcolor", 0)) L.TriWidth = ini.Read(aname, "arrow" & i & "tx", 30) L.TriHeight = ini.Read(aname, "arrow" & i & "ty", 20) L.RectX = ini.Read(aname, "arrow" & i & "x", 0) L.RectY = ini.Read(aname, "arrow" & i & "y", 0) L.RectW = ini.Read(aname, "arrow" & i & "x2", 10) L.RectH = ini.Read(aname, "arrow" & i & "y2", 10) L.Field = ini.Read(aname, "arrow" & i & "field", "") Draw_Arrow.Add(L) Next Me.Refresh_Drawlist() End If End Sub Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click Try '//»èÁ¦ Select Case Me.ListBox1.Text.Substring(0, 1) Case "¼±" Draw_Line.RemoveAt(Me.ListBox1.Text.Split(":")(1)) Case "¹Ú" Draw_Box.RemoveAt(Me.ListBox1.Text.Split(":")(1)) Case "¿ø" Draw_Circle.RemoveAt(Me.ListBox1.Text.Split(":")(1)) Case "±×" Draw_Image.RemoveAt(Me.ListBox1.Text.Split(":")(1)) Case "Q" Draw_QRcode.RemoveAt(Me.ListBox1.Text.Split(":")(1)) Case "R" Draw_QRcode1.RemoveAt(Me.ListBox1.Text.Split(":")(1)) Case "A" Draw_Arrow.RemoveAt(Me.ListBox1.Text.Split(":")(1)) End Select Me.Refresh_Drawlist() Catch ex As Exception MessageBox.Show("¼±Åà ÈÄ »èÁ¦°¡ °¡´ÉÇÕ´Ï´Ù.", "È®ÀÎ", MessageBoxButtons.OK, MessageBoxIcon.Error) ListBox1.Focus() End Try End Sub Private Sub ContextMenuStrip1_Opening(ByVal sender As System.Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles ContextMenuStrip1.Opening If Me.cmb_style.Items.Count < 1 Then Me.cm_styleedit.Enabled = False End If End Sub Private Sub tb_pagerepeat_KeyDown(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles tb_pagerepeat.KeyDown, tb_secX.KeyDown, tb_secY.KeyDown If e.KeyCode = Keys.Enter Then Me.preview_window() End If End Sub Private Sub tb_rep_KeyUp(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles tb_rep.KeyUp If e.KeyCode = Keys.Enter Then If Me.tb_rep.Text = "" OrElse Me.tb_rep Is vbNullString Then Me.tb_rep.Text = 0 For Each A As Control In SelCon CType(A, MyLabel).Repeat = Me.tb_rep.Text Next Me.preview_window() End If End Sub Private Sub tb_repx_KeyUp(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles tb_repx.KeyUp If e.KeyCode = Keys.Enter Then If Me.tb_rep.Text = "" OrElse Me.tb_rep Is vbNullString Then Me.tb_rep.Text = 0 For Each A As Control In SelCon CType(A, MyLabel).RepeatX = Me.tb_repx.Text Next Me.preview_window() End If End Sub Private Sub tb_repy_KeyUp(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles tb_repy.KeyUp If e.KeyCode = Keys.Enter Then If Me.tb_rep.Text = "" OrElse Me.tb_rep Is vbNullString Then Me.tb_rep.Text = 0 For Each A As Control In SelCon CType(A, MyLabel).RepeatY = Me.tb_repy.Text Next Me.preview_window() End If End Sub Private Sub COSÈÞÁî¿ë·®ToolStripMenuItem_Click(sender As System.Object, e As System.EventArgs) Handles COSÈÞÁî¿ë·®ToolStripMenuItem.Click SAVE_PATTERNII(Me.ÈÞÁî¿ë·®, "FUSEPATTERNII", "F", False, "\ÈÞÁî¿ë·®.TXT") '//¼±·Î¸íÀÇ ÆÐÅÏÀ» ÀúÀåÇÕ´Ï´Ù. End Sub Private Sub »óÇ¥½ÃÂû1´ÜToolStripMenuItem_Click(sender As System.Object, e As System.EventArgs) Handles »óÇ¥½ÃÂû1´ÜToolStripMenuItem.Click SAVE_PATTERNII(Me.»óÇ¥½ÃÂû1´Ü, "SANG1PATTERNII", "I", False, "\»óÇ¥½ÃÂû1´Ü.TXT") '//¼±·Î¸íÀÇ ÆÐÅÏÀ» ÀúÀåÇÕ´Ï´Ù. End Sub Private Sub »óÇ¥½ÃÂû2´ÜToolStripMenuItem_Click(sender As System.Object, e As System.EventArgs) Handles »óÇ¥½ÃÂû2´ÜToolStripMenuItem.Click SAVE_PATTERNII(Me.»óÇ¥½ÃÂû2´Ü, "SANG2PATTERNII", "T", False, "\»óÇ¥½ÃÂû2´Ü.TXT") '//¼±·Î¸íÀÇ ÆÐÅÏÀ» ÀúÀåÇÕ´Ï´Ù. End Sub Private Sub DoolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles DoolStripMenuItem.Click SAVE_PATTERNII(Me.ºñ°í¸í, "DLPATTERNII", "K", False, "\Dl¸íÆÐÅÏ2.TXT") '//¼±·Î¸íÀÇ ÆÐÅÏÀ» ÀúÀåÇÕ´Ï´Ù. End Sub Private Sub gfdStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles gfdStripMenuItem.Click SAVE_PATTERNII(Me.¼±·Î¸í, "LINEPATTERNII", "L", False, "\¼±·Î¸íÆÐÅÏ2.TXT") '//¼±·Î¸íÀÇ ÆÐÅÏÀ» ÀúÀåÇÕ´Ï´Ù. End Sub Private Sub gfdlStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles bt_pattern_no.Click If Me.¹øÈ£.IndexOf("H") <> -1 Then MsgBox("¹øÈ£¿¡ H°¡ ÀÖ½À´Ï´Ù. ÀÌ ÆÐÅÏÀº H°¡ ¾ø´Â °æ¿ì¿¡ ÀúÀåÀÌ °¡´ÉÇÕ´Ï´Ù.", MsgBoxStyle.Critical, "È®ÀÎ") Return End If SAVE_PATTERNII(Me.¹øÈ£, "JJNUMPATTERNII", "X", False, "\¹øÈ£ÆÐÅÏ2.TXT") '//H°¡ ¾ø´Â°æ¿ì End Sub Private Sub bt_pattern_noH_Click(sender As System.Object, e As System.EventArgs) Handles bt_pattern_noH.Click If Me.¹øÈ£.IndexOf("H") = -1 Then MsgBox("¹øÈ£¿¡ H°¡ ¾ø½À´Ï´Ù. H°¡ ÀÖ¾î¾ß ÀÌ ÆÐÅÏÀ» ÀúÀåÇÒ ¼ö ÀÖ½À´Ï´Ù.", MsgBoxStyle.Critical, "È®ÀÎ") Return End If SAVE_PATTERNII(Me.¹øÈ£, "JJNUMPATTERNII", "X", True, "\¹øÈ£ÆÐÅÏ2H.TXT") '//H°¡ Àִ°æ¿ì End Sub Private Sub bt_style_manager_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles bt_style_manager.Click SAVE_PATTERNII(Me.°¨µ¶ÀÚ, "MANGPATTERNII", "M", False, "\°¨µ¶ÀÚÆÐÅÏ2.TXT") '//¼±·Î¸íÀÇ ÆÐÅÏÀ» ÀúÀåÇÕ´Ï´Ù. 'SAVE_PATTERNII(Me.°¨µ¶ÀÚ, "MANGPATTERN", "MM", "\°¨µ¶ÀÚÆÐÅÏ2.TXT") '//¼±·Î¸íÀÇ ÆÐÅÏÀ» ÀúÀåÇÕ´Ï´Ù. End Sub Private Sub bt_style_company_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles bt_style_company.Click SAVE_PATTERNII(Me.½Ã°øÀÚ, "MAKERPATTERNII", "C", False, "\½Ã°øÀÚÆÐÅÏ2.TXT") '//¼±·Î¸íÀÇ ÆÐÅÏÀ» ÀúÀåÇÕ´Ï´Ù. End Sub Private Sub Button14_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button14.Click ' Dim NewLine As S_Circle ' NewLine.PenColor = Color.Black ' NewLine.PenWidth = 3 ' NewLine.X = 100 ' NewLine.Y = 50 ' NewLine.Width = 200 ' NewLine.Height = 50 ' Draw_Circle.Add(NewLine) ' Me.Refresh_Drawlist() Dim NewLine As S_Circle NewLine.PenColor = Drawing.Color.Black NewLine.PenWidth = 3 NewLine.X = Draw_Circle.Count * 10 NewLine.Y = Draw_Circle.Count * 10 NewLine.Width = 100 + Draw_Circle.Count * 10 'NewLine.Height = NewLine.Width NewLine.Field = "" Draw_Circle.Add(NewLine) Refresh_Drawlist() End Sub Private Sub Button16_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button16.Click Dim NewLine As S_Image NewLine.X = 100 NewLine.Y = 100 NewLine.Width = 0 NewLine.Height = 0 NewLine.FileName = ".\image\±×¸²ÆÄÀϸí.jpg" NewLine.Field = "" Draw_Image.Add(NewLine) Refresh_Drawlist() End Sub Private Sub Button17_Click_1(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button17.Click Dim NewLine As S_QRCode NewLine.X = 100 NewLine.Y = 100 NewLine.Width = 0 NewLine.Height = 0 NewLine.Field = "" Draw_QRcode.Add(NewLine) Refresh_Drawlist() End Sub 'Public Sub qr_Draw() ' 'Dim scale As Int16 ' Dim version As Int16 ' Dim image As Image ' Dim data As String ' Dim errorCorrect As String ' Dim qrCodeEncoder As New QRCodeEncoder() ' Dim encoding As String ' encoding = cboEncoding.Text ' If encoding = "3" Then ' qrCodeEncoder.QRCodeEncodeMode = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ENCODE_MODE.BYTE ' ElseIf encoding = "1" Then ' qrCodeEncoder.QRCodeEncodeMode = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ENCODE_MODE.ALPHA_NUMERIC ' ElseIf encoding = "2" Then ' qrCodeEncoder.QRCodeEncodeMode = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ENCODE_MODE.NUMERIC ' 'Try ' ' scale = Convert.ToInt16(txtSize.Text) ' 'qrCodeEncoder.QRCodeScale = scale ' 'Catch ex As Exception ' ' MessageBox.Show("Invalid size!") ' 'End Try ' Try ' version = Convert.ToInt16(cboVersion.Text) ' qrCodeEncoder.QRCodeVersion = version ' Catch ex As Exception ' MessageBox.Show("Invaild Version!") ' End Try ' End If ' errorCorrect = cboCorrectionLevel.Text ' If errorCorrect = "1" Then ' qrCodeEncoder.QRCodeErrorCorrect = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ERROR_CORRECTION.L ' ElseIf errorCorrect = "2" Then ' qrCodeEncoder.QRCodeErrorCorrect = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ERROR_CORRECTION.M ' ElseIf errorCorrect = "3" Then ' qrCodeEncoder.QRCodeErrorCorrect = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ERROR_CORRECTION.Q ' ElseIf errorCorrect = "4" Then ' qrCodeEncoder.QRCodeErrorCorrect = ThoughtWorks.QRCode.Codec.QRCodeEncoder.ERROR_CORRECTION.H ' End If ' data = q½Ã°øÀÚ & qȨÆäÀÌÁö ' & q°ü¸® & q°ü¸®1 & q°ü¸®2 ' image = qrCodeEncoder.Encode(data) 'data¼³Á¤ ÀÓ½Ã.................... ' PictureBox1.Image = image 'End Sub Private Sub Button18_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button18.Click Dim NewLine As S_QRCode1 NewLine.X = 100 NewLine.Y = 100 NewLine.Width = 0 NewLine.Height = 0 NewLine.Field = "" Draw_QRcode1.Add(NewLine) Refresh_Drawlist() End Sub Private Sub Àåô3ÀÚ¸®ToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Àåô3ÀÚ¸®ToolStripMenuItem.Click 'If Not Me.cb_jc1.Checked Then ' MsgBox("±âŸ½ºÅ¸ÀÏ[Àåô3ÀÚ¸®]¸¦ »ç¿ëÇÏÁö ¾Ê±â‹š¹®¿¡ ÀúÀåÀÌ µÇÁö ¾Ê½À´Ï´Ù", MsgBoxStyle.Critical, "È®ÀÎ") ' Return 'End If 'If MsgBox("ÇöÀç ½ºÅ¸ÀÏ(±âŸ-Àåô3ÀÚ¸®)À» ÀúÀåÇϽðڽÀ´Ï±î?", MsgBoxStyle.Information + MsgBoxStyle.YesNo, "±âŸ½ºÅ¸ÀÏÀúÀå") = MsgBoxResult.Yes Then ' Me.SAVE_STYLEC(Me.cmb_style.SelectedIndex & "STYLEJANGCHOK", "J") ' NOTICE("½ºÅ¸ÀÏ(±âŸ-Àåô3ÀÚ¸®)À» ÀúÀåÇß½À´Ï´Ù", Me.lb_msg) 'Else ' NOTICE("½ºÅ¸ÀÏ(±âŸ-Àåô3ÀÚ¸®)ÀúÀåÀÌ Ãë¼ÒµÇ¾ú½À´Ï´Ù", Me.lb_msg) 'End If 'Dim A As New System.Text.StringBuilder 'A.AppendLine("[±âŸ½ºÅ¸ÀÏ] Àåô3ÀÚ¸® »ç¿ëÀÌ ¼±ÅõǾîÀÖ½À´Ï´Ù") 'A.AppendLine() 'A.AppendLine("±âŸ½ºÅ¸ÀÏ ÀúÀåÀ» Ŭ¸¯Çϼ¼¿ä") 'If Me.cb_jc1.Checked Then ' MsgBox(A.ToString, MsgBoxStyle.Critical, "È®ÀÎ") ' Return 'End If SAVE_PATTERNII(Me.Àåô, "CHOKPATTERNII", "J", False, "\ÀåôÆÐÅÏ.TXT") '//¼±·Î¸íÀÇ ÆÐÅÏÀ» ÀúÀåÇÕ´Ï´Ù. End Sub Private Sub cmb_sep_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles cmb_sep.SelectedIndexChanged Me.preview_window() End Sub Private Sub cmb_connfield_SelectedValueChanged(sender As System.Object, e As System.EventArgs) Handles cmb_connfield.SelectedValueChanged If Me.ListBox1.SelectedIndex < 0 Then Return Dim SI As Short = Me.ListBox1.SelectedIndex '//»õ·Î¸¸µé¾î¼­ ÀúÀåÇÑ´Ù. Set_NewDraw() Me.Refresh_Drawlist() Me.ListBox1.SelectedIndex = SI End Sub Private Sub Button19_Click(sender As Object, e As EventArgs) Handles Button19.Click '//¼±Ãß°¡ Dim NewLine As S_Arrow NewLine.PenColor = Drawing.Color.Black NewLine.PenWidth = 3 ' NewLine.FillColor = Drawing.Color.Black NewLine.TriHeight = 20 NewLine.TriWidth = 30 NewLine.RectX = 10 NewLine.RectY = 10 NewLine.RectW = 50 NewLine.RectH = 50 NewLine.Field = "" Draw_Arrow.Add(NewLine) Refresh_Drawlist() End Sub Private Sub LinkLabel1_LinkClicked(sender As Object, e As LinkLabelLinkClickedEventArgs) Handles LinkLabel1.LinkClicked Dim a As New ColorDialog a.Color = lbQrBg.BackColor If a.ShowDialog() = System.Windows.Forms.DialogResult.OK Then lbQrBg.BackColor = a.Color End If End Sub Private Sub LinkLabel2_LinkClicked(sender As Object, e As LinkLabelLinkClickedEventArgs) Handles LinkLabel2.LinkClicked Dim a As New ColorDialog a.Color = lbQrFG.BackColor If a.ShowDialog() = System.Windows.Forms.DialogResult.OK Then lbQrFG.BackColor = a.Color End If End Sub End Class