Page 1 of 2
					
				AkelPad RePlace Notepad
				Posted: Sun Oct 09, 2022 10:34 am
				by SharkyEXE
				Hello
1) I have make modifidied notepad.exe file
2) I deleted original notepad.exe file in directory
C:\Windows\notepad.exe
C:\Windows\System32\notepad.exe
C:\Windows\SysWOW64\notepad.exe
3) I copy modifidied notepad.exe file in directory
C:\Windows\notepad.exe
C:\Windows\System32\notepad.exe
C:\Windows\SysWOW64\notepad.exe
4) If i run modifidied file notepad.exe, start C:\Program Files\AkelPadPortable\AkelPad.exe
Please, how this make?
If write modifidied notepad.exe file on AutoIt language - 
work solution
0) Deleted original notepad.exe file in directory
C:\Windows\notepad.exe
C:\Windows\System32\notepad.exe
C:\Windows\SysWOW64\notepad.exe
1) Compile this au3 file
Code: Select all
#AutoIt3Wrapper_UseX64=n
#AutoIt3Wrapper_Compression=0
#AutoIt3Wrapper_UseUpx=n
#AutoIt3Wrapper_OutFile=AkelPad_RePlace_Notepad.exe
#NoTrayIcon
ShellExecute ( "C:\Program Files\AkelPadPortable\AkelPad.exe", $CmdLineRaw )
Exit
2) Rename AkelPad_RePlace_Notepad.exe as Notepad.exe
3) Copy Notepad.exe file in directory
C:\Windows\notepad.exe
C:\Windows\System32\notepad.exe
C:\Windows\SysWOW64\notepad.exe
4) If run modifidied file notepad.exe, start C:\Program Files\AkelPadPortable\AkelPad.exe
 
			
					
				Re: AkelPad RePlace Notepad
				Posted: Sun Oct 09, 2022 10:55 am
				by Olli
				Don't copy akelpad.exe by renaming it : just change the shortcut system. If anybody clicks on a *.txt file, akelpad.exe is executed from its original path.
			 
			
					
				Re: AkelPad RePlace Notepad
				Posted: Sun Oct 09, 2022 11:10 am
				by SharkyEXE
				Olli wrote: Sun Oct 09, 2022 10:55 am
Don't copy akelpad.exe by renaming it : just change the shortcut system. If anybody clicks on a *.txt file, akelpad.exe is executed from its original path.
 
Hello
No, No
I have hint - replace original file to mod file
In default i open txt file - txt files open on AkelPad (withOUT change in registry)
 
			
					
				Re: AkelPad RePlace Notepad
				Posted: Sun Oct 09, 2022 11:37 am
				by BarryG
				Doesn't Windows (the OS) just replace the Notepad.exe file for not being the original? As part of its security.
			 
			
					
				Re: AkelPad RePlace Notepad
				Posted: Sun Oct 09, 2022 11:42 am
				by SharkyEXE
				BarryG wrote: Sun Oct 09, 2022 11:37 am
Doesn't Windows (the OS) just replace the Notepad.exe file for not being the original? As part of its security.
 
Hello
1) Excusme, my question - how write exe file on PureBasic, such as
"C:\Program Files\AkelPadPortable\AkelPad.exe", $CmdLineRaw
2) My broken-example code on PureBasic
Code: Select all
Filename$ = "C:\Program Files\AkelPadPortable\AkelPad.exe"
param$=ProgramParameter(0)
RunProgram(Filename$, param$, "", #PB_Program_Open|#PB_Program_Read)
Do not work
 
			
					
				Re: AkelPad RePlace Notepad
				Posted: Sun Oct 09, 2022 12:20 pm
				by AZJIO
				Code: Select all
Filename$ = "C:\Program Files\AkelPadPortable\AkelPad.exe"
Count = CountProgramParameters()
If Count
	param$=ProgramParameter(0)
	If FileSize(param$) > 0
		RunProgram(Filename$, param$, GetPathPart(param$))
	Else
		RunProgram(Filename$, param$, GetPathPart(Filename$))
	EndIf
Else
	RunProgram(Filename$)
EndIf
 
			
					
				Re: AkelPad RePlace Notepad
				Posted: Sun Oct 09, 2022 12:28 pm
				by SharkyEXE
				AZJIO wrote: Sun Oct 09, 2022 12:20 pm
 
Hello
1) I create 1.exe file on PureBasic 4.20 (Windows - x86)
Code: Select all
Filename$ = "C:\Program Files\AkelPadPortable\AkelPad.exe"
RunProgram(Filename$, param$, "")
2) I rename 1.exe in notepad.exe
3) I copy notepad.exe file in directory
C:\Windows\notepad.exe
C:\Windows\System32\notepad.exe
C:\Windows\SysWOW64\notepad.exe
4) I open cmd file - AkelPad started, but cmd file do not open - see 
gif animation
My operating system: Microsoft Windows 7 Service pack 1 Professional x64
 
			
					
				Re: AkelPad RePlace Notepad
				Posted: Sun Oct 09, 2022 1:13 pm
				by dcr3
				If I understood your question.
 
 
You want to replace Notepad with AkelPad.
Here one of several links.You can search on the internet [ Replace Notepad with ].
Replace Notepad with notepad++. Just change notepad++ with AkelPad.
https://www.howtogeek.com/howto/12617/h ... windows-7/ 
			
					
				Re: AkelPad RePlace Notepad
				Posted: Sun Oct 09, 2022 4:10 pm
				by SharkyEXE
				AZJIO wrote: Sun Oct 09, 2022 12:20 pm
Code: Select all
Filename$ = "C:\Program Files\AkelPadPortable\AkelPad.exe"
Count = CountProgramParameters()
If Count
	param$=ProgramParameter(0)
	If FileSize(param$) > 0
		RunProgram(Filename$, param$, GetPathPart(param$))
	Else
		RunProgram(Filename$, param$, GetPathPart(Filename$))
	EndIf
Else
	RunProgram(Filename$)
EndIf
 
Hello
1) I create 1.exe file on PureBasic 4.20 (Windows - x86)
Code: Select all
Filename$ = "C:\Program Files\AkelPadPortable\AkelPad.exe"
Count = CountProgramParameters()
If Count
	param$=ProgramParameter(0)
	If FileSize(param$) > 0
		RunProgram(Filename$, param$, GetPathPart(param$))
	Else
		RunProgram(Filename$, param$, GetPathPart(Filename$))
	EndIf
Else
	RunProgram(Filename$)
EndIf
2) I rename 1.exe in notepad.exe
3) I copy notepad.exe file in directory
C:\Windows\notepad.exe
C:\Windows\System32\notepad.exe
C:\Windows\SysWOW64\notepad.exe
4) I open C:\!\Test_WinRAR29.cmd file - AkelPad started, C:\!\Test_WinRAR29.cmd file open - excellent, super
6) But - I open C:\!\inal11404 -дла оощ ыф                                  цумщлзкщл3з мц ацул MNNMMMqpl v23 953 53262v32  - копия (2).log file - AkelPad started, C:\!\inal11404 -дла оощ ыф                                  цумщлзкщл3з мц ацул MNNMMMqpl v23 953 53262v32  - копия (2).log file NOT open - see 
gif animation
Maybe - need more spaces in name C:\!\inal11404 -дла оощ ыф                                  цумщлзкщл3з мц ацул MNNMMMqpl v23 953 53262v32  - копия (2).log?
My operating system: Microsoft Windows 7 Service pack 1 Professional x64
 
			
					
				Re: AkelPad RePlace Notepad
				Posted: Sun Oct 09, 2022 5:14 pm
				by AZJIO
				Code: Select all
Filename$ = "C:\Program Files\AkelPadPortable\AkelPad.exe"
#q$ = Chr(34)
Count = CountProgramParameters()
If Count
	param$ = ProgramParameter(0)
	If FileSize(param$) > 0
		RunProgram(Filename$, #q$ + param$ + #q$, GetPathPart(param$))
	Else
		RunProgram(Filename$, param$, GetPathPart(Filename$))
	EndIf
Else
	RunProgram(Filename$)
EndIf
 
			
					
				Re: AkelPad RePlace Notepad
				Posted: Sun Oct 09, 2022 5:25 pm
				by SharkyEXE
				AZJIO wrote: Sun Oct 09, 2022 5:14 pm
Code: Select all
Filename$ = "C:\Program Files\AkelPadPortable\AkelPad.exe"
#q$ = Chr(34)
Count = CountProgramParameters()
If Count
	param$ = ProgramParameter(0)
	If FileSize(param$) > 0
		RunProgram(Filename$, #q$ + param$ + #q$, GetPathPart(param$))
	Else
		RunProgram(Filename$, param$, GetPathPart(Filename$))
	EndIf
Else
	RunProgram(Filename$)
EndIf
 
Hello
I open C:\!\inal11404 -дла оощ ыф цумщлзкщл3з мц ацул MNNMMMqpl v23 953 53262v32 - копия (2).log file - AkelPad started, C:\!\inal11404 -дла оощ ыф цумщлзкщл3з мц ацул MNNMMMqpl v23 953 53262v32 - копия (2).log file NOT open - see 
gif animation
If tested, on disk 
C:\ create folder 
!
In folder 
C:\! create empty file 
inal11404 -дла оощ ыф цумщлзкщл3з мц ацул MNNMMMqpl v23 953 53262v32 - копия (2).log 
			
					
				Re: AkelPad RePlace Notepad
				Posted: Sun Oct 09, 2022 5:47 pm
				by AZJIO
				Permission to use ingenuity.
Code: Select all
Filename$ = "C:\Program Files\AkelPadPortable\AkelPad.exe"
#q$ = Chr(34)
Count = CountProgramParameters()
If Count
	param$ = ProgramParameter(0)
	If FileSize(param$) > 0
		MessageRequester("1", "|" + param$ + "|")
		RunProgram(Filename$, #q$ + param$ + #q$, GetPathPart(param$))
	Else
		MessageRequester("2", "|" + param$ + "|")
		RunProgram(Filename$, param$, GetPathPart(Filename$))
	EndIf
Else
	MessageRequester("3", "|" + param$ + "|")
	RunProgram(Filename$)
EndIf
 
			
					
				Re: AkelPad RePlace Notepad
				Posted: Sun Oct 09, 2022 5:51 pm
				by SharkyEXE
				AZJIO wrote: Sun Oct 09, 2022 5:47 pm
Permission to use ingenuity.
Code: Select all
Filename$ = "C:\Program Files\AkelPadPortable\AkelPad.exe"
#q$ = Chr(34)
Count = CountProgramParameters()
If Count
	param$ = ProgramParameter(0)
	If FileSize(param$) > 0
		MessageRequester("1", "|" + param$ + "|")
		RunProgram(Filename$, #q$ + param$ + #q$, GetPathPart(param$))
	Else
		MessageRequester("2", "|" + param$ + "|")
		RunProgram(Filename$, param$, GetPathPart(Filename$))
	EndIf
Else
	MessageRequester("3", "|" + param$ + "|")
	RunProgram(Filename$)
EndIf
 
Hello
See animation, please
https://cloud.mail.ru/public/PoXp/1XPWKChSa 
			
					
				Re: AkelPad RePlace Notepad
				Posted: Sun Oct 09, 2022 6:07 pm
				by AZJIO
				Change in the registry
notepad.exe %1
on the
notepad.exe "%1"
			 
			
					
				Re: AkelPad RePlace Notepad
				Posted: Sun Oct 09, 2022 6:16 pm
				by SharkyEXE
				AZJIO wrote: Sun Oct 09, 2022 6:07 pm
Change in the registry
notepad.exe %1
on the
notepad.exe "%1"
 
Hello
Excuse me, please
I respect your work, your help to me
But when I had this idea - I fundamentally do not change the registry, I do not want any associations and other things, only by means of PureBasic
So there is no way to put a path containing spaces in quotation marks?
Thank You!