Removes a file or directory indicated by a path, if the path makes reference to a directory.
 

1 file.delete

<file.delete>
    <file /> !
</file.delete>
Example

Remove a file.

Copy
<xsql-script name='file_delete_sample1'>
    <body>
        <set name='m_path'>
            <string>c:<file.separator />tmp<file.separator />data.txt</string>
        </set>
        <set name='m_result'>
            <file.delete>
                <file name='#m_path' type='absolute' />
            </file.delete>
        </set>
        <if>
            <expr>
                <eq>
                    <m_result/>
                    1
                </eq>
            </expr>
            <then>
                <set name='m_word'>exito</set>
            </then>
            <else>
                <set name='m_word'>fracaso</set>
            </else>
        </if>
        <println>Result of the erased: <m_word/></println>
    </body>
</xsql-script>