You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@openoffice.apache.org by bu...@apache.org on 2012/02/07 23:31:30 UTC

DO NOT REPLY [Bug 118886] New: Copy Method from com.sun.star.ucb.SimpleFileAccess failed when copying external file

https://issues.apache.org/ooo/show_bug.cgi?id=118886

             Bug #: 118886
        Issue Type: DEFECT
           Summary: Copy Method from com.sun.star.ucb.SimpleFileAccess
                    failed when copying external file
    Classification: Code
           Product: api
           Version: OOo 3.3 RC10
          Platform: PC
        OS/Version: Linux
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: code
        AssignedTo: tbo@openoffice.org
        ReportedBy: rmeunier@finov.com
                CC: ooo-issues@incubator.apache.org


Bug with the following method if the StartFile comes from a distant server.

demenageur = createUnoService("com.sun.star.ucb.SimpleFileAccess")
demenageur.copy(StartFile, ArrivalFichier)


Exemple:

Sub CopieDeFichier
dim oDoc, oSheet, oCell
    oDoc = ThisComponent

REM ***** COPIE D'UN FICHIER DANS LE DOSSIER COURANT *****

REM ***** RECHERCHE DU DOSSIER COURANT *****
    Chemin = oDoc.location
    FichierDepart = Chemin
    i=0
'Recherche le nom du dossier du fichier courant
    For i=Len(Chemin) to 1 step -1        
        If Right(Left(Chemin, i), 1) = "/" then
'Nom du dossier ou est le fichier courant
            Chemin = Left(Chemin, i)    
            exit for
            end if
        next
    FichierArrivee = Chemin & "Nouveau Fichier.ods"


REM ***** COPIE D'UN FICHIER LOCAL - OK NO BUG (rename and copy) *****
dim demenageur As Object
    demenageur = createUnoService("com.sun.star.ucb.SimpleFileAccess")
    demenageur.copy(FichierDepart,FichierArrivee)


REM ***** COPIE D'UN FICHIER DISTANT - ERREUR *****
' Please write your own distant file's address as below
'FichierDepart = ftp://dossier%40monsite.com:pw@ftp.monsite.com/MonFichier.ods"

    demenageur = createUnoService("com.sun.star.ucb.SimpleFileAccess")
    demenageur.copy(FichierDepart,FichierArrivee)
'in this case, an error message appear

    end sub

-- 
Configure bugmail: https://issues.apache.org/ooo/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.

[Bug 118886] [FTP ucp] css.ucb.SimpleFileAccess.copy() fails

Posted by bu...@apache.org.
https://issues.apache.org/ooo/show_bug.cgi?id=118886

--- Comment #4 from Rémy Meunier <rm...@finov.com> ---
Created attachment 80720
  --> https://issues.apache.org/ooo/attachment.cgi?id=80720&action=edit
Macro's section and error's message

As far as I understand, the link function (lien.hypertexte) involving ftp
address cannot handle the opening of Open office files.  Effectively others
files seem ok.

However, coping any files FROM ftp folder TO local folder doesn't work after
version 3.2.1.  Note that there is no problem FROM local folder TO ftp folder.

This bug force our organization to stay with an old version.  So I hope someone
can find witch change cause this bug and handle it.  Hopefully at least for
version 4!

-- 
You are receiving this mail because:
You are on the CC list for the bug.

[Bug 118886] Copy Method from com.sun.star.ucb.SimpleFileAccess failed when copying external file

Posted by bu...@apache.org.
https://issues.apache.org/ooo/show_bug.cgi?id=118886

Rémy Meunier <rm...@finov.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Version|pre AOO 3.4.0               |AOO 3.4.1
                 OS|Linux                       |All

-- 
You are receiving this mail because:
You are on the CC list for the bug.

[Bug 118886] Incoming files are not treated - Copy Method from com.sun.star.ucb.SimpleFileAccess failed when copying external file - LIEN.HYPERTEXTE function faile

Posted by bu...@apache.org.
https://issues.apache.org/ooo/show_bug.cgi?id=118886

--- Comment #2 from Rémy Meunier <rm...@finov.com> ---
I mean version 3.2.1 is working fine.  Problems involving external files began
after this version.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

[Bug 118886] [FTP ucp] css.ucb.SimpleFileAccess.copy() fails

Posted by bu...@apache.org.
https://issues.apache.org/ooo/show_bug.cgi?id=118886

Ariel Constenla-Haile <ar...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|[FTP ucb]                   |[FTP ucp]
                   |css.ucb.SimpleFileAccess.co |css.ucb.SimpleFileAccess.co
                   |py() fails                  |py() fails

-- 
You are receiving this mail because:
You are on the CC list for the bug.

[Bug 118886] [FTP ucp] css.ucb.SimpleFileAccess.copy() fails

Posted by bu...@apache.org.
https://issues.apache.org/ooo/show_bug.cgi?id=118886

--- Comment #6 from Ariel Constenla-Haile <ar...@apache.org> ---
Created attachment 80758
  --> https://issues.apache.org/ooo/attachment.cgi?id=80758&action=edit
Writer document with macro to test

Download and store the document to a writeable location
Open the macro in the Basic IDE
Define in FTPTEST the URL of an FTP server you have access

The macro will download the first file in the FTP server's folder. The file is
stored relative to the document with the macro.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

[Bug 118886] [FTP ucp] css.ucb.SimpleFileAccess.copy() fails

Posted by bu...@apache.org.
https://issues.apache.org/ooo/show_bug.cgi?id=118886

--- Comment #8 from Rémy Meunier <rm...@finov.com> ---
After trying the new package, I can confirm that the modification solve the
problem.  Waiting for Aoo 4.0 to be officially publish for everyone with
language package.  Thank's for your effort and competence.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

[Bug 118886] Copy Method from com.sun.star.ucb.SimpleFileAccess failed when copying external file

Posted by bu...@apache.org.
https://issues.apache.org/ooo/show_bug.cgi?id=118886

--- Comment #1 from Rémy Meunier <rm...@finov.com> ---
Incoming file's communication with and external source (as a server) is not
working since Ooo version 3.2.1.  It includes the function of the service
com.sun.star.ucb.SimpleFileAccess but also the link function as it appears in
the following exemple:


=LIEN.HYPERTEXTE("ftp://directory%40mydomain.com:mypassword@ftp.mydomain.com/myfile.ods";"Description
in cell")

However, note than the success of the function depends of the nature of the
file.

For exemple, this function calling a pdf file is working:

=LIEN.HYPERTEXTE("ftp://directory%40mydomain.com:mypassword@ftp.mydomain.com/myfile.pdf";"pdf
file")

...but calling the opening of a ods file doesn't work

=LIEN.HYPERTEXTE("ftp://directory%40mydomain.com:mypassword@ftp.mydomain.com/myfile.ods";"ods
file")

It looks like since 3.2.1, Ooo cannot handle a command involving a distant
file.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

[Bug 118886] [FTP ucb] css.ucb.SimpleFileAccess.copy() fails

Posted by bu...@apache.org.
https://issues.apache.org/ooo/show_bug.cgi?id=118886

--- Comment #3 from Ariel Constenla-Haile <ar...@apache.org> ---
(In reply to comment #1)
> but also the link function as it appears
> in the following exemple:
> 
> 
> =LIEN.HYPERTEXTE("ftp://directory%40mydomain.com:mypassword@ftp.mydomain.com/myfile.ods";"Description in cell")

The function is not broken. The function simply shows an hyperlink text. When
you click, I assume OpenOffice tells the system to open the hyperlink, and the
system chooses the default application associated to the file extension. So I
guess it is working for PDF, HTML, etc. but not for OpenOffice files: in this
case, the system tells OpenOffice to open the file, OpenOffice fails to open
the file on an FTP server.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

[Bug 118886] [FTP ucp] css.ucb.SimpleFileAccess.copy() fails

Posted by bu...@apache.org.
https://issues.apache.org/ooo/show_bug.cgi?id=118886

--- Comment #7 from Ariel Constenla-Haile <ar...@apache.org> ---
(In reply to Ariel Constenla-Haile from comment #5)
> Fixed with revision 1488548

Nightly build can be found at http://ci.apache.org/projects/openoffice/
Follow http://wiki.openoffice.org/wiki/Run_OOo_versions_parallel (a little
outdated) so that this build does not replace your stable version

-- 
You are receiving this mail because:
You are on the CC list for the bug.

[Bug 118886] [FTP ucb] css.ucb.SimpleFileAccess.copy() fails

Posted by bu...@apache.org.
https://issues.apache.org/ooo/show_bug.cgi?id=118886

Ariel Constenla-Haile <ar...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |arielch@apache.org
            Summary|Incoming files are not      |[FTP ucb]
                   |treated - Copy Method from  |css.ucb.SimpleFileAccess.co
                   |com.sun.star.ucb.SimpleFile |py() fails
                   |Access failed when copying  |
                   |external file -             |
                   |LIEN.HYPERTEXTE function    |
                   |faile                       |

-- 
You are receiving this mail because:
You are on the CC list for the bug.

[Bug 118886] [FTP ucp] css.ucb.SimpleFileAccess.copy() fails

Posted by bu...@apache.org.
https://issues.apache.org/ooo/show_bug.cgi?id=118886

Ariel Constenla-Haile <ar...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|---                         |FIXED
           Assignee|b.osi.ooo@gmail.com         |arielch@apache.org
   Target Milestone|---                         |AOO 4.0

--- Comment #5 from Ariel Constenla-Haile <ar...@apache.org> ---
Fixed with revision 1488548

-- 
You are receiving this mail because:
You are on the CC list for the bug.

[Bug 118886] Incoming files are not treated - Copy Method from com.sun.star.ucb.SimpleFileAccess failed when copying external file - LIEN.HYPERTEXTE function faile

Posted by bu...@apache.org.
https://issues.apache.org/ooo/show_bug.cgi?id=118886

Rémy Meunier <rm...@finov.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|Copy Method from            |Incoming files are not
                   |com.sun.star.ucb.SimpleFile |treated - Copy Method from
                   |Access failed when copying  |com.sun.star.ucb.SimpleFile
                   |external file               |Access failed when copying
                   |                            |external file -
                   |                            |LIEN.HYPERTEXTE function
                   |                            |faile

-- 
You are receiving this mail because:
You are on the CC list for the bug.

[Bug 118886] [FTP ucb] css.ucb.SimpleFileAccess.copy() fails

Posted by bu...@apache.org.
https://issues.apache.org/ooo/show_bug.cgi?id=118886

Ariel Constenla-Haile <ar...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Depends on|                            |122357

-- 
You are receiving this mail because:
You are on the CC list for the bug.