Service Virtualization

Expand all | Collapse all

How to use property in the Location field of a "Save property value to a File" filter

  • 1.  How to use property in the Location field of a "Save property value to a File" filter

    Posted Dec 16, 2018 08:51 AM

    Hi All,

     

    I am trying to use a property, which is the dataset name for "Load a set of File Names".

     

    However, i am not able to use the property in the location field.

     

    Please find the screenshot below.

     

     

    Filter "Save Property Value to a file" on Output Log Message Step.

     

    Can anyone please suggest if there is a way to append dynamic content to different files within a folder.

    Example: "textOne" in FileOne.txt

    "textTwo" in FileTwo.txt and so on....

     

    Thanks.



  • 2.  Re: How to use property in the Location field of a "Save property value to a File" filter
    Best Answer

    Broadcom Employee
    Posted Dec 16, 2018 11:47 AM

    Hi Aman,

     

    The property {{Value1}} should contain the file path for the current loop of your data set, if you think it does not then let us know if there is any error message in the workstation log. When you are configuring the Data Set, and you click "Test and Keep" then does it not show something like:

    But as you can see the file path is the full absolute path, starting with the drive name. So, using {{Value1}} as dynamic part of the file name in your filter will not work. You will have to parse Value1 property first and get the substring after the last "/"

     

    Cheers,

    Danny