No announcement yet.

Exit conversion for specific FTP matches

  • Filter
  • Time
  • Show
Clear All
new posts

  • Exit conversion for specific FTP matches

    I refer to the topic and would like to know if the following is doable.

    Assume you have an FTP folder called ftp://[email protected]/'qual1.qual2.qual3' (a PDS on the mainframe). I would like to be able to define a file format for this with a mask of (say) ftp://[email protected]/'qual1.* (or whatever). What I would then like to do is, if they select a PDS member (file) from this folder, a conversion program is run that massages the data.

    For example, they might want the source data changed such that any occurrences of A.B.C.D are changed to A.C.D

    Can this be done ? (This presupposes that I can specify a match on something like ftp://[email protected]/'qual1.* so that a specific file format is used)

  • #2
    The mask matching is assuming masks use '\' for the path delimiter on Windows. Also, '*' just matches a single level, whereas '...\' matches "zero or more parent directories".

    This will work:


    If you want it to be server specific, this will work:


    And if you want it to be user specific this will work:

    ftp://[email protected]*\...\*

    Most of BC doesn't know about the mainframe 'dir.dir.file' syntax, so the first filter actually thinks it matching a file named "'qual1.qual2.qual3'", rather than a file two folders deep. I don't see that changing, but it shouldn't cause too much trouble in practice.
    Zoë P Scooter Software


    • #3
      Hmmm - that's not working too well

      I can get the actual conversion program to kick in, but only after deliberately selecting the file format I want.

      As an experiment, I deliberately deselected all file formats so I was only left with one which contained the following general mask (xxxxx is deliberately changed from our prefix)
      (Our mainframe PDS is called 'xxxxxx.PROCLIB' and that's what I want this mask to match up against)

      I have tried every variation I can think of to get BC to recognize this mask, but nothing seems to help. When opening the file, I always see the following:-

      The date/time for the PDS member from the mainframe, Unknown size <default> ANSI

      As soon as I change the file format to be the one I've defined, all works well.

      What am I doing wrong ???


      • #4
        Have you tried removing the trailing ' character?
        Zoë P Scooter Software


        • #5

          That's why I wrote I have tried every variation I can think of.

          If the filename I want to match is 'A.B.C' (where A is not my userid, ie, from a mainframe point of view, I have to specify quotes), I have tried (I think)

          Basically, any of the obvious options, I reckon I've tried them.


          • #6
            Just been talking to an enthuiastic BC user

            regarding BC and showed him the exit program I'd written.

            To my surprise, when he selected the same mainframe members as I did, BC chose the "correct" file formats automatically for him.

            My BC is 3.2.3, build 13046, his is 3.0.15 build 9758, so something's obviously (?) been corrupted between the 2 builds.


            • #7
              I was testing 3.2.4 when I originally responded, so I don't think anything changed that would have affected this. Have him do a portable install of 3.2.3 then copy the contents of his %AppData%\Scooter Software\Beyond Compare 3 directory into the install directory so they're using the same settings and see if he sees the same behavior you do.
              Zoë P Scooter Software


              • #8
                Portable install might be a problem

                inasmuch as BC3 is "pushed" onto our machines at work by a central application - we don't install the code ourselves (apart from the updates)


                • #9
                  The portable install doesn't touch the registry or your existing settings and doesn't require administrative access. It's just a standalone version that sits in its own directory, and you can delete it by deleting the folder.

                  If you can't do that for some reason, you can get the same results just by copying files. Copy your BC v3.2.4 install directory somewhere, and copy their %AppData%\Scooter Software\Beyond Compare 3 contents into it (so BCState.xml is in the same folder as BCompare.exe). That's a portable install. Just launch the exe directly.
                  Zoë P Scooter Software


                  • #10
                    Well - that didn't work too well

                    I did what you said. Exported MY BC folder to a USB stick and copied the "correct" user's BCSTATE.XML to the same directory on the stick.

                    Started BC from the stick, and of course (?), the file formats weren't available. Imported them and tried to open a folder on the mainframe. Instead of getting a list of all the members in each folder, I get a message stating
                    File not found (ftp.//[email protected]_site/'userid.boka.cobol')
                    Running from my C-drive, everything works fine (well, apart from BC not recognizing and using the correct file format)


                    • #11
                      Export all of your settings into that folder, not just BCState.xml. That's just the file that tells BC it's in portable mode.
                      Zoë P Scooter Software


                      • #12
                        I must be missing something here

                        You're saying that I should copy the BC folder to a USB stick as well as exporting all the settings to that same stick plus BCState.xml.

                        If this is correct, from where should these 3 items come - his or my PC ?


                        • #13
                          Copy your entire BC install directory and his entire %AppData%\Scooter Software\Beyond Compare folder. BCState.xml will be one of several files from his folder; you need them all.
                          Zoë P Scooter Software


                          • #14
                            If I did everything correctly....

                            I exported my whole BC folder to the USB stick. Then I exported his files (various XML files) as well.

                            I then ran BC from this stick on his PC and the problem of the FTP formats not being recognized/chosen kicked in. Remove the stick and run BC from his C-drive, no problem.

                            It certainly seems like it's a problem with the latest build (or least some build after his one and before mine)

                            Experimented some more. Copied HIS BC directory to the stick and ran BC from there. Now it tries to apply the file format to both windows, even though one mask is specified as ftp://...\'sysabc* and the other is defined as ftp://...\'sysabc.proclib.* and the mainframe files are ftp://[email protected]/'sysabc.ft.proclib.member' and ftp://[email protected]/'sysabc.proclib.member'
                            Last edited by misi01; 25-Jan-2011, 07:58 AM.


                            • #15

                              Which version of BC3 are you running on your machine, and which version is it working for your coworker on his machine?

                              When you "export", are you navigating to the %AppData% directory and copying all of the files out of that directory and placing them on your usb stick? You should see your BC3key.txt, BCState.xml, BCSessions.xml, BCCommands.xml, and various other BCSettingsfiles.xml files in the directory. Alternatively to navigating manually, you can use the Help menu -> Support; Export option to generate a that contains all of these files. Then extract the zip into your portable install. This way, you can generate a from his working setup and apply it to a Portable install (either your BC directory or his). If created correctly, if you make a Portable install of HIS directory and use his settings from the, this Portable Install should function identically to normally running BC3 on his machine.
                              Aaron P Scooter Software