Author Topic: FTP and SlickEdit 2008 Not Allowing me to Save  (Read 11583 times)

sgranado

  • Community Member
  • Posts: 27
  • Hero Points: 0
FTP and SlickEdit 2008 Not Allowing me to Save
« on: May 16, 2008, 07:58:57 PM »
I just installed 2008.  Now when I connect to an FTP site,  I can open remote files just fine.  However, when I attempt to save the FTP file I get an error saying:

Unable to save C:\Documents and Settings\Administrator\My Documents\My SlickEdit Config\13.0.0\ftphostname\pathname to " C:\Documents and Settings\Administrator\My Documents\My SlickEdit Config\13.0.0\ftphostname\pathname"
Invalid Option



I have applied the 2 hotfixes.

The server type in the FTP setup is set to Auto.

I am connecting to a z/OS (formerly known as OS/390) system.
*****************************************************************
Update:
I can use File -> FTP -> Upload to save updates.  In the past, ctrl-s would force the upload.  Has this feature been removed?

Thanks.
Saheem
« Last Edit: May 16, 2008, 08:42:38 PM by sgranado »

kenkahn

  • Community Member
  • Posts: 33
  • Hero Points: 1
Re: FTP and SlickEdit 2008 Not Allowing me to Save
« Reply #1 on: May 16, 2008, 09:49:17 PM »
I just had this exact problem.  Go to

  Macros --> Set Macro Variable --> def_save_options

Somehow my options had been set to

  +O -Z -ZR +E +S +DDF-L +FU
                           ------

The option +DDF-L is not valid.  I changed the options to

  +O -Z -ZR +E +S +D -L +FU
                          -----

and that resolved the problem.  Your invalid option might be different, but this is how you find and change them.

sgranado

  • Community Member
  • Posts: 27
  • Hero Points: 0
Re: FTP and SlickEdit 2008 Not Allowing me to Save
« Reply #2 on: May 16, 2008, 09:56:12 PM »
I have this value:

-O -Z -ZR -E -S +DM+L +DD

I don't want to break anything... is this a bad value?  If so, how should I fix it?

I just had this exact problem.  Go to

  Macros --> Set Macro Variable --> def_save_options

Somehow my options had been set to

  +O -Z -ZR +E +S +DDF-L +FU
                           ------

The option +DDF-L is not valid.  I changed the options to

  +O -Z -ZR +E +S +D -L +FU
                          -----

and that resolved the problem.  Your invalid option might be different, but this is how you find and change them.

sgranado

  • Community Member
  • Posts: 27
  • Hero Points: 0
Re: FTP and SlickEdit 2008 Not Allowing me to Save
« Reply #3 on: May 16, 2008, 09:59:11 PM »
I fixed it by -O -Z -ZR -E -S +DM+L +DD removing the M.

I guess the next question is why did this happen?

kenkahn

  • Community Member
  • Posts: 33
  • Hero Points: 1
Re: FTP and SlickEdit 2008 Not Allowing me to Save
« Reply #4 on: May 16, 2008, 10:13:31 PM »
I just figured out how to reproduce this, at least on my system.  My current save options are

  +O -Z -ZR +E +S +D -L +FU

Go to

   tools --> options --> file options --> backup

Change backup directory option to "create backup history on save".  My options now look like

  +O -Z -ZR +E +S +DD-L +FU

Notice the extra "D".  I believe this is slickedit trying to add the '+D' option which, according to the help for backup:

  "if you are using the save command to save files, use the switch +D to specify this option"

Sounds like a bug (which I'll report).

ScottW, VP of Dev

  • Senior Community Member
  • Posts: 1471
  • Hero Points: 64
Re: FTP and SlickEdit 2008 Not Allowing me to Save
« Reply #5 on: May 16, 2008, 10:15:36 PM »
Bug noted. Thanks!

sgranado

  • Community Member
  • Posts: 27
  • Hero Points: 0
Re: FTP and SlickEdit 2008 Not Allowing me to Save
« Reply #6 on: May 19, 2008, 11:39:37 PM »
After I change from +DD to +D, I see in the Backup options that global directory is set.  I wanted to have the backup history kept.

Does this mean I cannot use the backup history save option until this is fixed?

Graeme

  • Senior Community Member
  • Posts: 2793
  • Hero Points: 347
Re: FTP and SlickEdit 2008 Not Allowing me to Save
« Reply #7 on: May 20, 2008, 10:10:14 AM »
After I change from +DD to +D, I see in the Backup options that global directory is set.  I wanted to have the backup history kept.

Does this mean I cannot use the backup history save option until this is fixed?

+DD is a valid option - it means "Delta" backup.  +DM means global nested directory.  +DB means same directory as .Bak  +DK means child directory.  +D is valid too.  All options must be space separated so this is part of the reason you get "invalid option" so go back into tools-> options file options -> backup and select what you want.  After saving the options, look at def_save_options and try adding spaces where they are missing  - there might not be any missing to start with.

I've never had a problem with the def_save_options getting corrupted and I use backup history every day.  The def_save_option string I have is -O -Z -ZR -E -S -L +DD

In previous versions of slickedit there was a function in filecfg.e called oncloseSaveBackupOptions() which built the def_save_options string and went to great trouble to insert a space between each option but this function has disappeared in SE2008.

There seems to be a bug in _file_load_select function in optionsxml.e where it calls _set_load_save_select with the first argument set to false when it should be set to true.  This causes it to modify def_save_options when it should be modifying def_load_options.  The function _set_load_save_select is also puzzling because it seems to assume that each option is followed by a value, however I don't understand the regular expression it's using.  It's also going to have a problem matching +D because this will also match +DM +DD etc. but it doesn't seem to get called with the D option. 

Graeme

Edit I had another look at this and _fbuo_backup_directory_option calls _file_save_select with the D option so set_load_save_select gets called with the D option and as far as I can see, it will work incorrectly if the existing options string has a +/-D option with no second character after the first D  - in that case it will incorrectly strip a space character.  However nothing seems to call _fbuo_backup_directory_option.  =D by itself supposedly means the backup option is "global directory" but if I select global directory, the D option gets removed from def_save_options completely so I don't know how you'd ever get just +D (unless you edit the string yourself).  By playing with the backup options I'm actually getting increasing amounts of redundant spaces added to it.  This is what my def_save_options look like now!  -O -Z -ZR -E -S  -L          +DD

« Last Edit: May 20, 2008, 12:19:07 PM by Graeme »

Sandra

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 754
  • Hero Points: 36
Re: FTP and SlickEdit 2008 Not Allowing me to Save
« Reply #8 on: May 20, 2008, 01:21:41 PM »
Graeme is right on the money.  The problem is not the extra 'D,' but the missing space.  I'll post again when the fix is in the cumulative hotfix (probably later today).

Sandra

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 754
  • Hero Points: 36
Re: FTP and SlickEdit 2008 Not Allowing me to Save
« Reply #9 on: May 20, 2008, 03:55:23 PM »
A brand-spanking-new hotfix is now available here:  http://www.slickedit.com/content/view/506.  Please make sure and get the updated required hotfix (revision 2) if you have not done so already.  You should now be able to change the Backup directory option with impunity.  Please let me know if this does not work for you.

Also note that if you have a corrupted def_save_options due to the bug, you'll need to get that straightened out, otherwise this hotfix won't help you much.  Most of the time, this will involve inserting a space.  See earlier posts in this thread for more info.  Also, if after applying the hotfix, you see an "Error retrieving value" in the options dialog, try setting the value and applying.  If that doesn't straighten you out, please let me know.

Thanks for all the help reporting and finding the bug!

Graeme

  • Senior Community Member
  • Posts: 2793
  • Hero Points: 347
Re: FTP and SlickEdit 2008 Not Allowing me to Save
« Reply #10 on: May 21, 2008, 12:08:26 PM »
Sandra, thanks for the fast fix.  I notice you didn't fix the problem I mentioned in _file_load_select().  Did I get that wrong or is it a harmless bug?

I'm also curious to know what this regular expression means in _set_load_save_select()
      ss := '[+|-]'key'(:c):0,1( |$)';

What is the :0,1 ?

Graeme

Sandra

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 754
  • Hero Points: 36
Re: FTP and SlickEdit 2008 Not Allowing me to Save
« Reply #11 on: May 21, 2008, 01:28:23 PM »
It is a bug, I just didn't fix it for the hotfix since nothing is calling it.  I will go ahead and fix it for 13.0.1, for my own future sanity sake.  Thanks for catching that.

Aw, man, I have to go back and figure out a regular expression I did months ago?  8)  If you look up the SlickEdit Regular Expressions in the help, there's an entry for X:n1,n2, where it will do a maximal match of at least n1 occurrences of X, but not more than n2.  In this case, X is (:c), an alphabetic character.  It's looking for 0 or 1 character(s), so you'd be able to find "+DK" or "+D". 

Graeme

  • Senior Community Member
  • Posts: 2793
  • Hero Points: 347
Re: FTP and SlickEdit 2008 Not Allowing me to Save
« Reply #12 on: May 21, 2008, 08:18:16 PM »
Ah, I didn't notice those X: entries. Thanks.

Graeme