Autore Topic: La proprietà FileView.Filter: una precisazione di Minisini  (Letto 517 volte)

Offline vuott

  • Moderatore globale
  • Senatore Gambero
  • *****
  • Post: 11.303
  • Ne mors quidem nos iunget
    • Mostra profilo
Vorrei riportare un messaggio (ne ometto il file allegato) inviato da un utente della M.L.I. sulla proprietà FileView.Filter, e la risposta di Minisini:

« The FileView.Filter property does not always work like described in the
documentation, here. The problem comes up when multiple file types are
to be displayed. The attached project creates three kinds of archives under
/tmp and offers two filters.

The first one mimics how it is done in the documentation,
e.g.: http://gambasdoc.org/help/comp/gb.form/fileview/filter?v3
and yields nothing - which is wrong.

The second syntax is inspired by the shell and makes the FileView display
the files correctly.

Is this system specific or an error in the docs, or...? This may affect
other Filter properties, too. I didn't test.

Regards,
Tobi
 »


« The documentation is false. It assumes that the FileView.Filter property
works like the Dialog.Filter property, but no!

The FileView.Filter property just takes an array of "LIKE" patterns:

FileView1.Filter = ["*.tar.gz", "*.tar.xz", "*.tar.bz2"]

Regards,

--
Benoît Minisini
 »
« Ultima modifica: 27 Gennaio 2013, 16:08:29 da vuott »
« Chiunque, non ricorrendo lo stato di necessità, nel proprio progetto Gambas fa uso delle istruzioni Shell o Exec, è punito con la sanzione pecuniaria da euro 20,00 a euro 60,00. »