You are here: PSPad forum > Developer forum - new builds > PSPad unicode 5.0.5 (549) English

PSPad unicode 5.0.5 (549) English

Goto Page: Previous1 2 3

#21 Re: PSPad unicode 5.0.5 (549) English

Posted by: Professor Bernd | Date: 2021-02-04 23:01 | IP: IP Logged

You are right about that! (I didn't know that. Learned something new again!) smiling smiley I use Windows 10 and the setting is:

"HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\FileSystem"
=> NtfsDisable8dot3NameCreation is set to 2

Meaning: NTFS sets the 8.3 naming convention creation on a per volume basis.

That's why %ShortFileName% works for me on C: drive, but not on D: drive.

Thanks for the info!

Sorry, I forgot to translate the text to English in the last post. grinning smiley

Options: Reply | Quote | Up ^


#22 Re: PSPad unicode 5.0.5 (549) English

Posted by: Greg | Date: 2021-02-04 23:02 | IP: IP Logged

pspad:
To get content of %File%, %DIR% e.t.c. you need to have open any file in PSPad, cause variable returns file related information

It's what i did.
I use it like on "Highlighters Settings --> External applications", and there it works fine.

I added Professor Bernd code to mine :
-------------------
public sub AA_TEST_VARIABLES()
Dim sMsg

sMsg = _
"PSPath: " & getVarValue("%PSPath%") & vbCRLF & vbCRLF _
& "File: " & getVarValue("%File%") & vbCRLF & vbCRLF _
& "Dir: " & getVarValue("%Dir%") & vbCRLF & vbCRLF _
& "Name: " & getVarValue("%Name%") & vbCRLF & vbCRLF _
& "SelText: " & getVarValue("%SelText%") & vbCRLF & vbCRLF _
& "FullFileName: " & getVarValue("%FullFileName%") & vbCRLF & vbCRLF _
& "ShortFileName: " & getVarValue("%ShortFileName%") & vbCRLF & vbCRLF _
& "FilePath: " & getVarValue("%FilePath%") & vbCRLF & vbCRLF _
& "FileName: " & getVarValue("%FileName%") & vbCRLF & vbCRLF _
& "File: " & getVarValue("%File%") & vbCRLF & vbCRLF _
& "Ext: " & getVarValue("%Ext%") & vbCRLF & vbCRLF _
& "HomePath: " & getVarValue("%HomePath%") & vbCRLF & vbCRLF _
& "UserProfile: " & getVarValue("%UserProfile%") & vbCRLF & vbCRLF _
& "AppData: " & getVarValue("%AppData%") & vbCRLF & vbCRLF _
& "Temp: " & getVarValue("%Temp%") & vbCRLF & vbCRLF _
& "WinDir: " & getVarValue("%WinDir%") & vbCRLF & vbCRLF _
_
& "module_name: " & module_name & vbCRLF & vbCRLF _
& "moduleFileName: " & moduleFileName(module_name) & vbCRLF & vbCRLF _
& "modulePath: " & modulePath() & vbCRLF & vbCRLF _
& ""

Echo(sMsg)
End Sub
----------------------
It returns :

PSPath: D:\program-files\pspad\

File: DCM_PSPad-script_Externe

Dir:

Name:

SelText:

FullFileName: D:\program-files\pspad\Script\VBScript\DCM_PSPad-script_Externe.vbs

ShortFileName: D:\PROGRA~1\pspad\Script\VBScript\DCM_PS~2.VBS

FilePath: D:\program-files\pspad\Script\VBScript\

FileName: DCM_PSPad-script_Externe.vbs

File: DCM_PSPad-script_Externe

Ext: .vbs

HomePath: \Users\Greg

UserProfile: C:\Users\Greg

AppData: C:\Users\Greg\AppData\Roaming

Temp: C:\Users\Greg\AppData\Local\Temp

WinDir: C:\WINDOWS

module_name: DCM_PSPad-script_Externe

moduleFileName: D:\program-files\pspad\Script\VBScript\DCM_PSPad-script_Externe.vbs

modulePath: D:\program-files\pspad\Script\VBScript\

Options: Reply | Quote | Up ^


#23 Re: PSPad unicode 5.0.5 (549) English

Posted by: Greg | Date: 2021-02-04 23:09 | IP: IP Logged

pspad:
In the menu settings/user variables you should see variables with values

Sorry pspad and Professor Bernd, i just read that so i have the answer for the FullFileName variable :P

I confirm that settings/user variables shows me :
%FileName%
%FileName2%
%FullFileName%
%ShortFileName%
%FilePath%
%ProjectName%
%RFCTime%
%PSPad%
%PSPath%
%UNIXTime%

And the values are corrects, but i still have this behavior in VBScript :
OK : getVarValue(%PSPath%) = PSPad application path
NOK : getVarValue(%File%) = Name, without extension, of current file
NOK : getVarValue(%Dir%) = Empty string
NOK : getVarValue(%Name%) = Empty string
NOK : getVarValue(%SelText%) = Empty string

Options: Reply | Quote | Up ^


#24 Re: PSPad unicode 5.0.5 (549) English

Posted by: Greg | Date: 2021-02-04 23:22 | IP: IP Logged

Professor Bernd:
For %SelText% you can use the editor object functions in VBScript.

' editor object function

Dim obj
Set obj = NewEditor()
obj.assignActiveEditor()

sMsg = "SelText: " & obj.SelText()

Echo(sMsg)

If you need further help on this, you can create a separate thread so as not to bloat this "new builds" thread. Then you can send me a PM so that I notice the thread. winking smiley

Thank again, it worked. But i really think my first question points to a bug...

Thank you guy for your help !

Options: Reply | Quote | Up ^


#25 Re: PSPad unicode 5.0.5 (549) English

Posted by: Professor Bernd | Date: 2021-02-04 23:30 | IP: IP Logged

Greg:
Thank you very much Professor Bernd ! ... where did you find it ?

I don't know how Jan Fiala feels about it, but I think we should no longer steal this thread! tongue sticking out smiley

As I said, if you have more questions, you can create your own thread and send me a PM so I can notice the thread.

Then other users can also find the answers. smiling smiley

Options: Reply | Quote | Up ^


#26 Re: PSPad unicode 5.0.5 (549) English

Posted by: pspad | Date: 2021-02-07 11:29 | IP: IP Logged

MadCompie:
Hello,

With this version the filenames disappear from the tab.
My simulation:
- open a random file: filename OK in the tab
- minimize PSPad & restore: filename remains OK
- close PSPad (not really close but minimized close) & restore: filenames are gone
- Must now really close & restart PSPad to show the filenames again

Confirmed when PSpad is close to tray.
Fix will be available in today's build

Options: Reply | Quote | Up ^


Goto Page: Previous1 2 3





Editor PSPad - freeware editor, © 2001 - 2024 Jan Fiala, Hosted by Webhosting TOJEONO.CZ, design by WebDesign PAY & SOFT, code Petr Dvořák, Privacy policy and GDPR