Is there any way to make the custom column display the current row serial number?

English support forum

Moderators: white, Hacker, petermad, Stefan2

Post Reply
ruizrzr1
Junior Member
Junior Member
Posts: 37
Joined: 2022-07-06, 06:39 UTC

Is there any way to make the custom column display the current row serial number?

Post by *ruizrzr1 »

:?:
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48021
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: Is there any way to make the custom column display the current row serial number?

Post by *ghisler(Author) »

No, sorry, the plugins don't know in which row a file is located. Why? The user can change the sort order, then it would become invalid.
Author of Total Commander
https://www.ghisler.com
User avatar
Hacker
Moderator
Moderator
Posts: 13052
Joined: 2003-02-06, 14:56 UTC
Location: Bratislava, Slovakia

Re: Is there any way to make the custom column display the current row serial number?

Post by *Hacker »

There is a more or less (maybe less) working way using AHK (and WinScript Advanced):

Code: Select all

#NoTrayIcon
SetBatchLines, -1

SplitPath, Filename, , Dir
FileRead, StoredDir, %A_Temp%\CurrDir.txt
If (StoredDir = Dir)
{
	FileRead, i, %A_Temp%\CurrNum.txt
	Content := ++i
	FileDelete, %A_Temp%\CurrNum.txt
	FileAppend, %Content%, %A_Temp%\CurrNum.txt
}
Else
{
	FileDelete, %A_Temp%\CurrDir.txt
	FileAppend, %Dir%, %A_Temp%\CurrDir.txt
	FileDelete, %A_Temp%\CurrNum.txt
	FileAppend, 1, %A_Temp%\CurrNum.txt
	Content = 1
}
Since, unless you move the view / cursor, TC requests the content fields in the order shown, this usually works if you enter a dir and wait a moment.

HTH
Roman
Mal angenommen, du drückst Strg+F, wählst die FTP-Verbindung (mit gespeichertem Passwort), klickst aber nicht auf Verbinden, sondern fällst tot um.
Post Reply