Login  Register

Re: String.format

Posted by Peter Haub on Nov 18, 2020; 6:20pm
URL: http://imagej.273.s1.nabble.com/String-format-tp5024199p5024207.html

Thank you Wayne
for this valuable hint.
Perfect solution.

Peter

On 18.11.2020 18:24, Wayne Rasband wrote:

>> On Nov 18, 2020, at 11:49 AM, Peter Haub <[hidden email]> wrote:
>>
>> Here is a use case
>> https://forum.image.sc/t/fiji-macro-issue-no-window-with-title-found/45525/3
> The easy way to add leading zeros to an integer is to use the IJ.pad(n,digits) function. It is not obvious how to do it using String.format().
>
> -wayne
>
>> On 18.11.2020 17:04, Kenneth Sloan wrote:
>>> I suspect that all numbers are doubles in macros.
>>> --
>>> Kenneth Sloan
>>> [hidden email]
>>> Vision is the art of seeing what is invisible to others.
>>>
>>> --
>>> ImageJ mailing list: http://imagej.nih.gov/ij/list.html
>>
>> --
>> ImageJ mailing list: http://imagej.nih.gov/ij/list.html
> --
> ImageJ mailing list: http://imagej.nih.gov/ij/list.html

--
ImageJ mailing list: http://imagej.nih.gov/ij/list.html