[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: IFS folder listing



   I do ignore those values.
   I do agree, if you try from DOS you can see those directories. What it
   signifies, just trying to understand.
   Thanks,
   Musthafa

   On Fri, Jan 15, 2010 at 8:51 AM, Rick Connor
   <[1]rconnor@xxxxxxxxxxxxx> wrote:

     The program returns a directory listing. The directory listing
     contains
     . and .. because those are in the directory.
     If you don't need them simply ignore them.
     C                   Dow       p_entry <> *NULL
     C                   Eval      wFileName =
     C
     %subst(wdEntry.d_name:1:wdEntry.d_nameLen)
      * Don't include directory values
     C                   If        wFileName <> '.' and
     C                             wFileName <> '..'
     C                   Endif
     C                   Eval      p_entry = readdir(dirh)
     C                   Enddo

   -----Original Message-----
   From: [2]ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx
   [mailto:[3]ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx] On Behalf Of Mohamed
   Musthafa Safarulla

   Sent: Friday, January 15, 2010 9:29 AM
   To: HTTPAPI and FTPAPI Projects

   Subject: Re: IFS folder listing
   Thanks Rick but why do we really need that . and ..?
   Thanks,
   Musthafa
   On Thu, Jan 14, 2010 at 4:58 PM, Rick Connor
   <[4]rconnor@xxxxxxxxxxxxx>
   wrote:
   > There are two "special" entries inside each directory, as well. They
   are
   > "." (a single dot) and ".." (two dots). These
   > signify the "current directory" and the "parent directory"
   respectively.
   >
   > -----Original Message-----
   > From: [5]ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx
   > [mailto:[6]ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx] On Behalf Of
   Mohamed
   > Musthafa Safarulla
   > Sent: Thursday, January 14, 2010 5:29 PM
   > To: HTTPAPI and FTPAPI Projects
   > Subject: IFS folder listing
   >
   > I want directory listing of an IFS folder , I got the sample program
   > from
   >
   > [7]http://www.scottklement.com/rpg/ifs_ebook/ifs_ebook.pdf  page 81
   >
   > The program is like
   >
   >  dir = OpenDir('/customer');
   >  p_dirent = readdir(dir);
   >  Dow p_dirent <> *NULL;
   >   Msg = %subst(d_name:1:d_namelen);
   >   p_dirent = readdir(dir);
   >  EndDo;
   >  CloseDir(dir);
   >  *InLR = *On;
   >
   > The file listing is coming perfect but i have extra entries in the
   > listing
   > like
   > "." and ".."
   >
   > No idea, what it is. Any pointers? Please
   >
   > --
   > Thanks,
   > Musthafa
   >
   ----------------------------------------------------------------------
   -
   > This is the FTPAPI mailing list.  To unsubscribe, please go to:
   > [8]http://www.scottklement.com/mailman/listinfo/ftpapi
   >
   ----------------------------------------------------------------------
   -
   >
   --
   Thanks,
   Musthafa
   ----------------------------------------------------------------------
   -
   This is the FTPAPI mailing list.  To unsubscribe, please go to:
   [9]http://www.scottklement.com/mailman/listinfo/ftpapi
   ----------------------------------------------------------------------
   -

   --
   Thanks,
   Musthafa

References

   1. mailto:rconnor@xxxxxxxxxxxxx
   2. mailto:ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx
   3. mailto:ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx
   4. mailto:rconnor@xxxxxxxxxxxxx
   5. mailto:ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx
   6. mailto:ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx
   7. http://www.scottklement.com/rpg/ifs_ebook/ifs_ebook.pdf
   8. http://www.scottklement.com/mailman/listinfo/ftpapi
   9. http://www.scottklement.com/mailman/listinfo/ftpapi
-----------------------------------------------------------------------
This is the FTPAPI mailing list.  To unsubscribe, please go to:
http://www.scottklement.com/mailman/listinfo/ftpapi
-----------------------------------------------------------------------