diff --git a/EUD Editor/Module/ProgramData.vb b/EUD Editor/Module/ProgramData.vb
index 87d040f..4365847 100644
--- a/EUD Editor/Module/ProgramData.vb
+++ b/EUD Editor/Module/ProgramData.vb
@@ -1102,24 +1102,29 @@ Module ProgramData
Private Function ReadDEF(BaseDEFtext As String, Key As String)
Try
Dim temptext2 As String
- Dim temptext As String = Mid(BaseDEFtext, InStr(BaseDEFtext, vbCrLf & Key))
-
- temptext = Mid(temptext, InStr(temptext, "="))
- 'Mid(base, InStr(base, Key), 4)
- If InStr(temptext, vbCrLf) = 0 Then
- temptext2 = Mid(temptext, 2).Trim
- If InStr(temptext2, ":") = 0 Then
- Return temptext2
+ Dim start As Integer = InStr(BaseDEFtext, vbCrLf & Key)
+ If start > 0 Then
+ Dim temptext As String = Mid(BaseDEFtext, start)
+
+ temptext = Mid(temptext, InStr(temptext, "="))
+ 'Mid(base, InStr(base, Key), 4)
+ If InStr(temptext, vbCrLf) = 0 Then
+ temptext2 = Mid(temptext, 2).Trim
+ If InStr(temptext2, ":") = 0 Then
+ Return temptext2
+ Else
+ Return Mid(temptext2, 1, InStr(temptext2, ":"))
+ End If
Else
- Return Mid(temptext2, 1, InStr(temptext2, ":"))
+ temptext2 = Mid(temptext, 2, InStr(temptext, vbCrLf) - 1).Trim
+ If InStr(temptext2, ":") = 0 Then
+ Return temptext2
+ Else
+ Return Mid(temptext2, 1, InStr(temptext2, ":"))
+ End If
End If
Else
- temptext2 = Mid(temptext, 2, InStr(temptext, vbCrLf) - 1).Trim
- If InStr(temptext2, ":") = 0 Then
- Return temptext2
- Else
- Return Mid(temptext2, 1, InStr(temptext2, ":"))
- End If
+ Return "false"
End If
Catch ex As Exception
Return "false"
diff --git a/EUD Editor/Module/initModule.vb b/EUD Editor/Module/initModule.vb
index d50368c..ea531a0 100644
--- a/EUD Editor/Module/initModule.vb
+++ b/EUD Editor/Module/initModule.vb
@@ -1,4 +1,5 @@
Imports System.IO
+Imports Microsoft.Win32
Module initModule
Public DirectoryPath As String
@@ -182,8 +183,8 @@ Module initModule
If My.User.IsInRole("administrators") = False Then
- MsgBox(Lan.GetMsgText("notAdmin"), MsgBoxStyle.Critical, ProgramSet.ErrorFormMessage)
- End
+ ' MsgBox(Lan.GetMsgText("notAdmin"), MsgBoxStyle.Critical, ProgramSet.ErrorFormMessage)
+ 'End
End If
@@ -228,35 +229,40 @@ Module initModule
'
- My.Computer.Registry.ClassesRoot.CreateSubKey(".e2s").SetValue("",
+ Dim classes As RegistryKey = My.Computer.Registry.CurrentUser.OpenSubKey("Software\Classes", RegistryKeyPermissionCheck.ReadWriteSubTree)
+
+
+
+
+ classes.CreateSubKey(".e2s").SetValue("",
"e2s", Microsoft.Win32.RegistryValueKind.String)
- My.Computer.Registry.ClassesRoot.CreateSubKey("e2s\shell\open\command").SetValue("",
+ classes.CreateSubKey("e2s\shell\open\command").SetValue("",
Application.ExecutablePath & " ""%l"" ", Microsoft.Win32.RegistryValueKind.String)
- My.Computer.Registry.ClassesRoot.CreateSubKey("e2s\DefaultIcon").SetValue("",
+ classes.CreateSubKey("e2s\DefaultIcon").SetValue("",
My.Application.Info.DirectoryPath & "\Data\icons\e2s.ico" & ",0", Microsoft.Win32.RegistryValueKind.String)
- My.Computer.Registry.ClassesRoot.CreateSubKey(".ees").SetValue("",
+ classes.CreateSubKey(".ees").SetValue("",
"ees", Microsoft.Win32.RegistryValueKind.String)
- My.Computer.Registry.ClassesRoot.CreateSubKey("ees\shell\open\command").SetValue("",
+ classes.CreateSubKey("ees\shell\open\command").SetValue("",
Application.ExecutablePath & " ""%l"" ", Microsoft.Win32.RegistryValueKind.String)
- My.Computer.Registry.ClassesRoot.CreateSubKey("ees\DefaultIcon").SetValue("",
+ classes.CreateSubKey("ees\DefaultIcon").SetValue("",
My.Application.Info.DirectoryPath & "\Data\icons\ees.ico" & ",0", Microsoft.Win32.RegistryValueKind.String)
- My.Computer.Registry.ClassesRoot.CreateSubKey(".mem").SetValue("",
+ classes.CreateSubKey(".mem").SetValue("",
"mem", Microsoft.Win32.RegistryValueKind.String)
- My.Computer.Registry.ClassesRoot.CreateSubKey("mem\shell\open\command").SetValue("",
+ classes.CreateSubKey("mem\shell\open\command").SetValue("",
Application.ExecutablePath & " ""%l"" ", Microsoft.Win32.RegistryValueKind.String)
- My.Computer.Registry.ClassesRoot.CreateSubKey("mem\DefaultIcon").SetValue("",
+ classes.CreateSubKey("mem\DefaultIcon").SetValue("",
My.Application.Info.DirectoryPath & "\Data\icons\mem.ico" & ",0", Microsoft.Win32.RegistryValueKind.String)
- My.Computer.Registry.ClassesRoot.CreateSubKey(".e2p").SetValue("",
+ classes.CreateSubKey(".e2p").SetValue("",
"e2p", Microsoft.Win32.RegistryValueKind.String)
- My.Computer.Registry.ClassesRoot.CreateSubKey("e2p\shell\open\command").SetValue("",
+ classes.CreateSubKey("e2p\shell\open\command").SetValue("",
Application.ExecutablePath & " ""%l"" ", Microsoft.Win32.RegistryValueKind.String)
- My.Computer.Registry.ClassesRoot.CreateSubKey("e2p\DefaultIcon").SetValue("",
+ classes.CreateSubKey("e2p\DefaultIcon").SetValue("",
My.Application.Info.DirectoryPath & "\Data\icons\e2p.ico" & ",0", Microsoft.Win32.RegistryValueKind.String)
'TextEditor.ShowDialog()
diff --git a/EUD Editor/Module/parsingModule.vb b/EUD Editor/Module/parsingModule.vb
index baa856e..d8725f5 100644
--- a/EUD Editor/Module/parsingModule.vb
+++ b/EUD Editor/Module/parsingModule.vb
@@ -302,14 +302,21 @@ Module parsingModule
Public Function FindSetting(base As String, key As String, Optional strflag As Boolean = False) As String
Try
- Dim text As String = Mid(base, InStr(base, key & " "))
- 'If key = "extraedssetting" Then
- ' MsgBox(InStr(text, vbCrLf) - key.Count - 4)
- 'End If
- If InStr(text, vbCrLf) = 0 Then
- Return Mid(text, key.Count + 4)
+ Dim start As Integer = InStr(base, key & " ")
+ If start > 0 Then
+ Dim text As String = Mid(base, start)
+ 'If key = "extraedssetting" Then
+ ' MsgBox(InStr(text, vbCrLf) - key.Count - 4)
+ 'End If
+ If InStr(text, vbCrLf) = 0 Then
+ Return Mid(text, key.Count + 4)
+ Else
+ Return Mid(text, key.Count + 4, InStr(text, vbCrLf) - key.Count - 4)
+ End If
+ ElseIf strflag Then
+ Return ""
Else
- Return Mid(text, key.Count + 4, InStr(text, vbCrLf) - key.Count - 4)
+ Return "0"
End If
Catch ex As Exception
diff --git a/EUD Editor/My Project/Application.Designer.vb b/EUD Editor/My Project/Application.Designer.vb
index 4452b02..bde9792 100644
--- a/EUD Editor/My Project/Application.Designer.vb
+++ b/EUD Editor/My Project/Application.Designer.vb
@@ -1,10 +1,10 @@
'------------------------------------------------------------------------------
'
-' 이 코드는 도구를 사용하여 생성되었습니다.
-' 런타임 버전:4.0.30319.42000
+' This code was generated by a tool.
+' Runtime Version:4.0.30319.42000
'
-' 파일 내용을 변경하면 잘못된 동작이 발생할 수 있으며, 코드를 다시 생성하면
-' 이러한 변경 내용이 손실됩니다.
+' Changes to this file may cause incorrect behavior and will be lost if
+' the code is regenerated.
'
'------------------------------------------------------------------------------
@@ -14,16 +14,16 @@ Option Explicit On
Namespace My
- '참고: 자동으로 생성되므로 직접 이 파일을 수정하지 마세요. 변경할 사항이 있거나
- ' 파일에서 빌드 오류가 발생하는 경우 프로젝트 디자이너로
- ' 이동([프로젝트 속성]으로 이동하거나 솔루션 탐색기에서 My Project 노드를
- ' 두 번 클릭)한 다음 [응용 프로그램] 탭에서 변경하십시오.
+ 'NOTE: This file is auto-generated; do not modify it directly. To make changes,
+ ' or if you encounter build errors in this file, go to the Project Designer
+ ' (go to Project Properties or double-click the My Project node in
+ ' Solution Explorer), and make changes on the Application tab.
'
Partial Friend Class MyApplication
_
Public Sub New()
- MyBase.New(Global.Microsoft.VisualBasic.ApplicationServices.AuthenticationMode.Windows)
+ MyBase.New(Global.Microsoft.VisualBasic.ApplicationServices.AuthenticationMode.ApplicationDefined)
Me.IsSingleInstance = false
Me.EnableVisualStyles = true
Me.SaveMySettingsOnExit = true
diff --git a/EUD Editor/My Project/Application.myapp b/EUD Editor/My Project/Application.myapp
index db2c607..5462ce4 100644
--- a/EUD Editor/My Project/Application.myapp
+++ b/EUD Editor/My Project/Application.myapp
@@ -5,6 +5,6 @@
false
0
true
- 0
+ 1
true
\ No newline at end of file
diff --git a/EUD Editor/My Project/app.manifest b/EUD Editor/My Project/app.manifest
index 2d3db86..283411a 100644
--- a/EUD Editor/My Project/app.manifest
+++ b/EUD Editor/My Project/app.manifest
@@ -16,7 +16,7 @@
이전 버전과의 호환성을 위해 응용 프로그램에 가상화가 필요한 경우
이 요소를 제거합니다.
-->
-
+