Welcome!

By registering with us, you'll be able to discuss, share and private message with other members of our community.

SignUp Now!

Recent content by old coot

  1. old coot

    DO varname IN fileset sometimes includes complete filepath in result

    Sometimes, when I use a DO varname IN filesetcommand, the output list of files includes the full filepath; sometimes not. This makes it awkward (but not really too hard) to handle the output in a consistent and clean manner. The filepath-prepending seems to be triggered by the use of regular...
  2. old coot

    Regex problem: \xnn not recognized as a hex character

    I apologize (once again) for resurrecting this thread, but thought I'd post the answer, for anyone who happens to stumble across the thread. In my response #13, I forgot to specify case-insensitivity (or, alternatively, specify upper-case characters). In addition, it wanted the double-quotes...
  3. old coot

    Can I turn off the minimize to tray mechanism in TCC?

    That solution works for me in both TCmd and TCC. Turns it off, just as you (and I) wanted.
  4. old coot

    Can I turn off the minimize to tray mechanism in TCC?

    Vince: see my last paragraph for how I turned it off. I think I'm encountering a variation of the same problem. In Multi-Edit, I have Undo and Redo assigned to Ctrl-Z and Shift-Ctrl-Z. These work fine, as long as TCmd isn't running. Just recently (I'm not sure how long ago), Shift-Ctrl-Z...
  5. old coot

    Another regex-in-RENAME question

    I like REs: they can be very precise in selecting the fileset I want to operate on and what I want to do to it. But they can also be a PITA, especially when it comes to greedy/non-greedy, escape characters, and the apparent inability to match hex/octal patterns (see first post). They require...
  6. old coot

    Another regex-in-RENAME question

    Well, it does specify the files you want to operate on: every file whose name contains a dash. The RE is both file-selection and pattern-to-replace. If I wanted to be more specific, I could use ^ and $ anchors (or even just a little more of the name) and come up with a pattern that would...
  7. old coot

    Another regex-in-RENAME question

    Just for completeness: suppose I want to go back the other way: replace the spaces with dashes. The best way I've found to do that is this: do until errorlevel gt 0 (ren ":: (.)" ::-\1) ...with one caveat: if a filename that originally ended with dashes had those dashes converted to spaces...
  8. old coot

    Another regex-in-RENAME question

    [D:\TMP] dir /b /a-d *-* a-b a-b--c---d a--b-c a-b-c-d If I want to convert all those dashes to underscores in the filenames, I can use this command: ren ::- ::_ But what if I want to convert the dashes to spaces? I haven't figured out how to include a space character that is recognized as...
  9. old coot

    Debugging .btm with >3 arguments fails on step.

    Well, technically, it can, by referencing %[%@inc[%i]]. Yes, it can: [D:\TMP] type foo.btm @ echo off set retval=0 do i=1 to %# iff %retval gt 0 then set retval=0 iterate endiff gosub foo %[%i] set retval=%_? enddo quit :foo [var] echo var passed is %var...
  10. old coot

    Debugging .btm with >3 arguments fails on step.

    Vince, maybe I'm missing something. In your example, the subroutine can still see all the parameters by using %[%i]. In general, your approach offers an advantage over SHIFT in that all parameters are available all the time.
  11. old coot

    Debugging .btm with >3 arguments fails on step.

    Resolved in 28.02.18.
  12. old coot

    Parameter-handling discrepancy in debugger when stepping

    But only until I shut down the debugger.
  13. old coot

    Parameter-handling discrepancy in debugger when stepping

    I was entering the parms in the ribbon in the debugger. Going to 18 fixed it. Thanks, Vince!
  14. old coot

    Parameter-handling discrepancy in debugger when stepping

    I'm starting it from the Tools | Edit/Debug menu item.
Back
Top