Link text file to open with my application

0

I am trying to associate the text files to open with my application but when I click on a text file of the error.

ThisisthecodeIuse

PublicSubChecAssocation()TryMy.Computer.Registry.ClassesRoot.CreateSubKey(".txt").SetValue("", "Mdlabs_Text_editor", Microsoft.Win32.RegistryValueKind.String)
        My.Computer.Registry.ClassesRoot.CreateSubKey("Mdlabs_Text_editor\shell\open\comand").SetValue("", "C:\Program Files\mdlabs_text_editor\editor_de_texto.exe" & " ""%1"" ", Microsoft.Win32.RegistryValueKind.String)
        My.Computer.Registry.ClassesRoot.CreateSubKey("Mdlabs_Text_editorDefaultIcon").SetValue("", "C:\Program Files\mdlabs_text_editor\" & "\my new icon for apps.ico")
    Catch ex As Exception

    End Try
End Sub
    
asked by anonymous 30.10.2018 / 12:13

0 answers