Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to add folder to WE for easy access
Message
De
05/02/2016 17:43:45
 
 
Information générale
Forum:
Windows
Catégorie:
Autre
Versions des environnements
OS:
Windows 10
Divers
Thread ID:
01630946
Message ID:
01630982
Vues:
49
We also have visual foxpro then can use it.
*it is not superfluous to make this small code under  hand even as executable & on systray or desktop shortcut.
*this saves a lot of clicks
*it runs on any windows OS.
*Of course can filter only the folders wanted (even in a physical table)

Publi yform
yform=Newobject("myfolders")
yform.Show
Read Events
Retu
*
Define Class myfolders As Form
    Top = 5
    Left = 96
    Height = 27
    Width = 519
    ShowWindow = 2
    BorderStyle=0
    Caption = "My Custom favorite folders"
    MaxButton = .F.
    AlwaysOnTop = .T.
    Name = "Form1"

    Add Object combo1 As ComboBox With ;
        FontSize = 8, ;
        RowSourceType = 6, ;
        RowSource = "ycurs.folder", ;
        Height = 25, ;
        Left = 0, ;
        MousePointer = 15, ;
        Top = 0, ;
        Width = 517, ;
        Name = "Combo1"

    Procedure Init
        This.Caption=This.Caption+"  ["+Trans(Reccount())+ " directorie(s)]"
        This.combo1.Value=folder
    Endproc

    Procedure Load
        Close Data All
        Create Cursor ycurs (folder c(150))

        Local gnbre,m.yrep
        m.yrep="C:\Program Files\"
        gnbre=Adir(gabase,m.yrep+"*.*","D")
        For i=1 To gnbre
            If !Inlist(gabase(i,1),'.','..')
                Insert Into ycurs Values(m.yrep+Allt(gabase(i,1)))
            Endi
        Endfor
        Sele ycurs
        *brow
        Locate
    Endproc

    Procedure Destroy
        Clea Events
    Endproc

    Procedure combo1.Click
        Local m.myvar
        TEXT to m.myvar textmerge noshow
		run/n explorer "<<allt(folder)>>"
        ENDTEXT
        Execscript(m.myvar)
    Endproc

Enddefine
*
*-- EndDefine: myfolders
Regards
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform