1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

SafeChars plugin misbehaving...

Discussion in 'Plugins' started by mathewsdw, Dec 24, 2012.

  1. mathewsdw

    Joined:
    May 24, 2010
    Messages:
    855
    Likes Received:
    0
    First, look at this output:
    Code:
    #ABCD EFGH IJKL#
    # EFGH IJKL#
    #ABCDEF, GHI, JKLMNOP#
    #, GHI, JKLMNOP#
    
    I'll note here that the output should be:
    Code:
    #ABCD EFGH IJKL#
    #ABCD EFGH IJKL#
    #ABCDEF, GHI, JKLMNOP#
    #ABCDEF, GHI, JKLMNOP#
    
    It is missing everything before the either the first space or the first comma.

    I would swear that this problem (or one very similar) came up in the not too distant past and it was fixed. Whether or not that's the case, it's there now.

    Below is the transcript of a complete TCC session, unmodified by me in any way, that illustrates everything related to this problem and nothing else:
    Code:
       Mon  Dec 24, 2012   6:11:49a
    
    Chill v1.1.0 loaded.
    TCC: Plugin already loaded "Event64"
    HTags plugin v0.60.3 loaded.
    HTMLDump plugin v1.0.5 loaded.
    ISO8601 plugin v1.3.7 loaded.
    PopInfo v1.0.3 loaded; hotkey is Control-Q.
    QCAL plugin v1.3.7 loaded.
    SafeChars plugin v1.7.0 loaded.
    Say plugin v1.0.7 loaded.
    
    TCC  14.03.52 x64   Windows 7 [Version 6.1.7601]
    Copyright 2012 JP Software Inc.  All Rights Reserved
    Registered to Daniel Mathews
    
    [Z:\]cdd "C:\Program Files\JPSoft\TCMD14x64\Plugins"
    
    [C:\Program Files\JPSoft\TCMD14x64\Plugins]fdir safe*
     9/04/2012  11:16          40,960  safechars-x64.dll
     9/04/2012  11:23          35,326  SafeChars.chm
     9/04/2012  11:23          43,482  safechars.html
    
    [C:\Program Files\JPSoft\TCMD14x64\Plugins]cdd "E:\FireFox Downloads\SafeChars.unz
    ip
    
    [E:\FireFox Downloads\SafeChars.unZip]fdir
    10/02/2009  10:55           1,128  demo.btm
     9/04/2012  11:16          40,960  safechars-x64.dll
     9/04/2012  11:23          35,326  SafeChars.chm
     9/04/2012  11:16          36,864  safechars.dll
     9/04/2012  11:23          43,482  safechars.html
    12/24/2012   5:21         111,642  safechars.zip
    
    [E:\FireFox Downloads\SafeChars.unZip]type Z:\SafeDemo.btm
    @Echo Off
    SetLocal
    UnSafe /E:,
    Set Data=ABCD EFGH IJKL
    @Echo #%Data#
    @Echo #%@UnSafe[%@SafeExp[%Data]]#
    Set Data=ABCDEF, GHI, JKLMNOP
    @Echo #%Data#
    @Echo #%@UnSafe[%@SafeExp[%Data]]#
    EndLocal
    
    [E:\FireFox Downloads\SafeChars.unZip]Z:\SafeDemo
    #ABCD EFGH IJKL#
    # EFGH IJKL#
    #ABCDEF, GHI, JKLMNOP#
    #, GHI, JKLMNOP#
    
    [E:\FireFox Downloads\SafeChars.unZip]
    
    Sadly, because I regularly use characters in my file names that TCC really doesn't like this problem has me dead in the water as the saying goes.
     
  2. Steve Fabian

    Joined:
    May 20, 2008
    Messages:
    3,520
    Likes Received:
    4
    Sorry, the problem is incorrect use of @SAFEEXP. Plesae the below warning in the HELP for @SAFEEXP (emphasis added):
    "Note: Do not type a percent sign before the variable or function name. If you do, TCC’s parser will expand the argument before @SAFEEXP gets to see it"
    --
    HTH, Steve
     
  3. Charles Dye

    Charles Dye Super Moderator
    Staff Member

    Joined:
    May 20, 2008
    Messages:
    3,351
    Likes Received:
    39
    Thanks, Steve.

    (I'll be out of contact for the next several days, so I won't be able to provide any kind of support. Sorry! A good and safe Christmas to all!)
     
  4. mathewsdw

    Joined:
    May 24, 2010
    Messages:
    855
    Likes Received:
    0
    Thank you, guys! Old habits die hard.
     

Share This Page