Multi Rename Tool - Random Number Plugin?
Moderators: Hacker, petermad, Stefan2, white
Multi Rename Tool - Random Number Plugin?
Like the subject says, I would like to insert a random number. Is there a way to do this natively or via a plugin?
Something like [R8] would create an 8 digit random number.
Something like [R8] would create an 8 digit random number.
2jzekeb
Hi,
you can try my misc content plug-in. The field "Random" shows a 5 digits random number:
http://lefteous.totalcmd.net/tc/archives/misc/misc_1.03.zip
Hi,
you can try my misc content plug-in. The field "Random" shows a 5 digits random number:
http://lefteous.totalcmd.net/tc/archives/misc/misc_1.03.zip
Multi Rename Tool - Random Number Plugin?
That is indeed excellent. Would it be possible to increase the number of digits to say eight, or better, to a specified number?Lefteous wrote:2jzekeb
you can try my misc content plug-in. The field "Random" shows a 5 digits random number:
http://lefteous.totalcmd.net/tc/archives/misc/misc_1.03.zip
--
Bob
The internal plugin generates random numbers of up to five digits. You can add leading zero's and make longer numbers. For example to make a 10 digit "random" number use:MVV wrote:BTW there is an built-in plugin field for random numbers: [=tc.random number]. But you should use some sort of regex to add zeroes to number.
Code: Select all
[=tc.random number:01-5][=tc.random number:01-5]
gezgin wrote:That is indeed excellent. Would it be possible to increase the number of digits to say eight, or better, to a specified number?
Bob
MVV wrote:BTW there is an built-in plugin field for random numbers: [=tc.random number].
While in MRT press F1 to pop-up the help.
There you can read how to manipulate
the output of the variables by using: ':n-m'
For example, to get eight digits use
[=tc.Random number][=tc.Random number:1-3]
5 + 3 = 8
For one digit use
[=tc.Random number:1]
For two
[=tc.Random number:4-]
or
[=tc.Random number:1-2]
Add leading zeros
000[=tc.Random number]
.
That gave me the idea for this:Stefan2 wrote:For example, to get eight digits use
[=tc.Random number][=tc.Random number:1-3]
5 + 3 = 8
For one digit use
[=tc.Random number:1]
For two
[=tc.Random number:4-]
or
[=tc.Random number:1-2]
Add leading zeros
000[=tc.Random number]
[=tc.random number:1][=tc.random number:1][=tc.random number:1][=tc.random number:1][=tc.random number:1][=tc.random number:1][=tc.random number:1][=tc.random number:1][=tc.random number:1][=tc.random number:1]
Generates 10-digit random numbers. Surprisingly there are no "0"s among the numbers however.
--
Bob
I just figured out that the following includes zeros, including leading ones:gezgin wrote: Surprisingly there are no "0"s among the numbers however.
[=tc.random number:2][=tc.random number:2][=tc.random number:2][=tc.random number:2][=tc.random number:2][=tc.random number:2][=tc.random number:2][=tc.random number:2][=tc.random number:2][=tc.random number:2]
--
Bob
[=tc.random number] generates a number below 100.000 without leading zero's. The chance to hit zero is 1 out of 100.000.gezgin wrote:That gave me the idea for this:
[=tc.random number:1][=tc.random number:1][=tc.random number:1][=tc.random number:1][=tc.random number:1][=tc.random number:1][=tc.random number:1][=tc.random number:1][=tc.random number:1][=tc.random number:1]
Generates 10-digit random numbers. Surprisingly there are no "0"s among the numbers however.
[=tc.random number:2] will not always give a result. Do the math.gezgin wrote:I just figured out that the following includes zeros, including leading ones:gezgin wrote:
[=tc.random number:2][=tc.random number:2][=tc.random number:2][=tc.random number:2][=tc.random number:2][=tc.random number:2][=tc.random number:2][=tc.random number:2][=tc.random number:2][=tc.random number:2]
Simply use:
[=tc.random number:01-5][=tc.random number:01-3]
Just create a custom column containing [=tc.random number] and you will soon see a number with fewer digits.Stefan2 wrote:Ahh, up to five digits. I see it now too. Thanks.
I though i get always 5 digits.
Search your hard drive for "[=tc.random number] = 0" and you will find out [=tc.random number] sometimes generates a zero.