<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic no save file in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/no-save-file/m-p/474464#M71920</link>
    <description>&lt;P&gt;Hello everyone, my problem is that when I press the button "Annuler" (=Cancel), it still saves the file to me even though I don't want it, how can I do that?&lt;BR /&gt;I put you the attached script.&lt;BR /&gt;Thanks&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="NetflixCrow956_0-1648643389055.png" style="width: 685px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/41304i891097032AA36B79/image-dimensions/685x381?v=v2" width="685" height="381" role="button" title="NetflixCrow956_0-1648643389055.png" alt="NetflixCrow956_0-1648643389055.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;path_save = Pick Directory( "Où sauver les fichiers analyse rendement?" );

NAME = "_ANALYSE_RENDEMENT";
//////////////////////////////////////        DEFINE DIR AND FILE NAMES (MONTH / YEAR) + CREATE DIR              /////////////////////////////////////////////////////////
DAY_   = Day(Today());
MONTH_ = Month( Today() );
YEAR_ = Year( Today() );
HOUR_ = Hour(Today());
MINUTE_ = Minute(Today());
SECONDE_ = Second(Today());


If(MONTH_ &amp;lt; 10 , NAME_MONTH= "0" || Char(MONTH_), NAME_MONTH= Char(MONTH_) );
If(DAY_   &amp;lt; 10 , NAME_DAY= "0"   || Char(DAY_)  , NAME_DAY  = Char(DAY_)   );
NAME_TIME = "_" || Char(HOUR_) || "H" || Char(MINUTE_) || "M" || Char(SECONDE_) || "S";

//DIR_NAME = Char(MONTH_ )|| " - " || Word(1,NAME,"_") || "_" || Char( YEAR_ ) ;
DIR_NAME = Char( YEAR_ ) || NAME_MONTH || NAME_DAY || NAME_TIME || NAME;

If( Directory Exists( path_save || DIR_NAME ), ,	Create Directory( path_save || DIR_NAME ));&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 09 Jun 2023 18:14:50 GMT</pubDate>
    <dc:creator>NetflixCrow956</dc:creator>
    <dc:date>2023-06-09T18:14:50Z</dc:date>
    <item>
      <title>no save file</title>
      <link>https://community.jmp.com/t5/Discussions/no-save-file/m-p/474464#M71920</link>
      <description>&lt;P&gt;Hello everyone, my problem is that when I press the button "Annuler" (=Cancel), it still saves the file to me even though I don't want it, how can I do that?&lt;BR /&gt;I put you the attached script.&lt;BR /&gt;Thanks&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="NetflixCrow956_0-1648643389055.png" style="width: 685px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/41304i891097032AA36B79/image-dimensions/685x381?v=v2" width="685" height="381" role="button" title="NetflixCrow956_0-1648643389055.png" alt="NetflixCrow956_0-1648643389055.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;path_save = Pick Directory( "Où sauver les fichiers analyse rendement?" );

NAME = "_ANALYSE_RENDEMENT";
//////////////////////////////////////        DEFINE DIR AND FILE NAMES (MONTH / YEAR) + CREATE DIR              /////////////////////////////////////////////////////////
DAY_   = Day(Today());
MONTH_ = Month( Today() );
YEAR_ = Year( Today() );
HOUR_ = Hour(Today());
MINUTE_ = Minute(Today());
SECONDE_ = Second(Today());


If(MONTH_ &amp;lt; 10 , NAME_MONTH= "0" || Char(MONTH_), NAME_MONTH= Char(MONTH_) );
If(DAY_   &amp;lt; 10 , NAME_DAY= "0"   || Char(DAY_)  , NAME_DAY  = Char(DAY_)   );
NAME_TIME = "_" || Char(HOUR_) || "H" || Char(MINUTE_) || "M" || Char(SECONDE_) || "S";

//DIR_NAME = Char(MONTH_ )|| " - " || Word(1,NAME,"_") || "_" || Char( YEAR_ ) ;
DIR_NAME = Char( YEAR_ ) || NAME_MONTH || NAME_DAY || NAME_TIME || NAME;

If( Directory Exists( path_save || DIR_NAME ), ,	Create Directory( path_save || DIR_NAME ));&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 09 Jun 2023 18:14:50 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/no-save-file/m-p/474464#M71920</guid>
      <dc:creator>NetflixCrow956</dc:creator>
      <dc:date>2023-06-09T18:14:50Z</dc:date>
    </item>
    <item>
      <title>Re: no save file</title>
      <link>https://community.jmp.com/t5/Discussions/no-save-file/m-p/474484#M71922</link>
      <description>&lt;P&gt;Adding check for empty path might be enough:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here(1);

path_save = Pick Directory( "Où sauver les fichiers analyse rendement?" );

If(path_save == "",
	Show("Cancel pressed");
	stop(); //or use throw()
);

NAME = "_ANALYSE_RENDEMENT";
//////////////////////////////////////        DEFINE DIR AND FILE NAMES (MONTH / YEAR) + CREATE DIR              /////////////////////////////////////////////////////////
DAY_   = Day(Today());
MONTH_ = Month( Today() );
YEAR_ = Year( Today() );
HOUR_ = Hour(Today());
MINUTE_ = Minute(Today());
SECONDE_ = Second(Today());


If(MONTH_ &amp;lt; 10 , NAME_MONTH= "0" || Char(MONTH_), NAME_MONTH= Char(MONTH_) );
If(DAY_   &amp;lt; 10 , NAME_DAY= "0"   || Char(DAY_)  , NAME_DAY  = Char(DAY_)   );
NAME_TIME = "_" || Char(HOUR_) || "H" || Char(MINUTE_) || "M" || Char(SECONDE_) || "S";

//DIR_NAME = Char(MONTH_ )|| " - " || Word(1,NAME,"_") || "_" || Char( YEAR_ ) ;
DIR_NAME = Char( YEAR_ ) || NAME_MONTH || NAME_DAY || NAME_TIME || NAME;

If( Directory Exists( path_save || DIR_NAME ), ,	Create Directory( path_save || DIR_NAME ));
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 30 Mar 2022 12:43:24 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/no-save-file/m-p/474484#M71922</guid>
      <dc:creator>jthi</dc:creator>
      <dc:date>2022-03-30T12:43:24Z</dc:date>
    </item>
  </channel>
</rss>

