1. Bonjour tout le monde ! Veillez consulter la Politique de forum pour comprendre nos règles, Merci a vous !
    Rejeter la notice

WD How to emulate a scrollbar movements on a Lauyout Control

Discussion dans 'Windev' créé par DirkPitt, Déc 29, 2024, à 9:02 AM.

  1. DirkPitt

    DirkPitt Member

    Inscrit:
    Jan 8, 2018
    Messages:
    61
    J'aime reçus:
    16
    Hello to all

    I'm trying to use the Layout control (Disposition in french) where i can insert various cells with their different controls (edit, static, table, etc etc). The Layout control has 8 different sectons and i would like to jump to these sections based on the section selected from a little menu.
    As i see the Layout control has its own scrollbar, but i think it isn't available for a emulate solution, but it needs to be used manually scrolling the mouse.

    Can i use Windows API calls to emulate and get the control of the scrollbar of the Layout control?
    If yes, what kind of approach do i need?

    Thanks in advance
    Dirk
     
    Tags:
  2. popoy

    popoy Well-Known Member
    MEMBRE WX

    Inscrit:
    Fev 23, 2018
    Messages:
    2,962
    J'aime reçus:
    1,575
    J'ai pas bien compris ta réponse sur

    Bonjour visiteur, Merci de vous Inscrire ou de vous connectez pour voir les liens!

     
  3. DirkPitt

    DirkPitt Member

    Inscrit:
    Jan 8, 2018
    Messages:
    61
    J'aime reçus:
    16
    Hello Popoy.

    Sorry if didn't explained well the argument.
    I can inform you i found a simple solution to resolve the sections positioning issue when the user choose an option.

    The solution is to assign an integer value to the Layout scroolbar, like this below:


    n is int=0


    SWITCH LISTA_Opzioni
    CASE 1
    n=0
    ScrollbarPosition("LAYOUT_DATI", sbVert, n) //sbHorz = Horizontal
    CASE 2
    n=50
    ScrollbarPosition("LAYOUT_DATI", sbVert, n) //sbHorz = Horizontal

    CASE 3
    n=4450
    ScrollbarPosition("LAYOUT_DATI", sbVert, n) //sbHorz = Horizontal
    CASE 4
    n=5029
    ScrollbarPosition("LAYOUT_DATI", sbVert, n) //sbHorz = Horizontal
    CASE 5
    n=7470
    ScrollbarPosition("LAYOUT_DATI", sbVert, n) //sbHorz = Horizontal

    OTHER CASE
    END

    That's all!! With this little solution i can resolve the positioning over a long Layout control (It seems like a long web page)

    Thanks
     

Partager cette page

Chargement...