Page 2 of 2 FirstFirst 12
Results 11 to 18 of 18

Thread: More controls in the grid

  1. #11
    Fabio,

    Can you make a small video showing exactly what you mean?

    Thanks.

    Herb

  2. #12
    Senior Member
    Join Date
    Feb 2012
    Location
    Rome - Italy
    Posts
    1,893
    I will try again .. then I try with a video.. and all laugh..

    By definition, I want to give the same feeling and the same functionality, is if I edited a field in a grid or in a section.

    At this point, or I can put in the grid the standard formfield of the section ..

    Or, if in the grid I have to use custom controls (creted with container + textbox), or I create the same (equal) as FormItem .. or I'll have to use the same controls in the custom section...

    this is the idea for the italian "DDT" alias "Packing slip".
    Name:  Screenshot - 04_03_2015 , 16_32_41.jpg
Views: 112
Size:  120.9 KB
    I've the header and the row.

    For both table, I want to create a dedicated page, to edit all the table's field, as the Hank's example.

    But if I want to change one "item code" in the line, or the "shipment reason" on the header, I thought I could do it directly on the grid .. whith he same funcionality of the "edit header section".

    But if you can not, I'll try to think about how to do .. with grids for viewing and server page for the insertion and edit .. of course, even then when I press the insert button, I have to open the dialog. . save and close, it is not practical to do so as the grid ..

  3. #13
    Lianja MVP
    Join Date
    Dec 2012
    Location
    Croatia, Zagreb
    Posts
    1,135
    Hi Herb,

    Thanks for your example. Try to add some custom delegate to your "text1" (methods like valid() or so...).
    That is what Fabio wants. I've tried with no success.

  4. #14
    Hi Josip,

    Is that the issue?

    That's easy.

    You create your own textbox class with a valid.

    Like this.

    define class mytextbox as textbox
    proc valid()
    wait window "valid"
    endproc

    enddefine

    Then instead of adding textbox, you add mytextbox.

    Herb

  5. #15
    Lianja MVP
    Join Date
    Feb 2012
    Location
    Berea, KY, USA
    Posts
    2,184
    Or, if in the grid I have to use custom controls (creted with container + textbox),
    That's what I suggested. But it would be one custom control with all the edit fields in it.

    Hank

  6. #16
    Lianja Development Team barrymavin's Avatar
    Join Date
    Feb 2012
    Location
    UK, USA, Thailand
    Posts
    7,161
    Blog Entries
    22
    It's all about scoping the classes. If you declare a class in a custom library it stays in scope. If you declare it in a prg it will go out of scope.

    Also, Herbs approach is better for large amounts of paginated data. Creating a custom control in grid cells for big resultset is not practical.

    Better to use dialog panels and provide a more modern UI in my opinion.

    You can always save the current recno() then goto() it in the grid after editing in the slide in dialog panel.
    Principal developer of Lianja, Recital and other products

    Follow me on:

    Twitter: http://twitter.com/lianjaInc
    Facebook: http://www.facebook.com/LianjaInc
    LinkedIn: http://www.linkedin.com/in/barrymavin

  7. #17
    Lianja MVP
    Join Date
    Dec 2012
    Location
    Croatia, Zagreb
    Posts
    1,135
    Yes, Herb,
    That was exactly the code I tried.
    Here is the package: 2792.lpk

    P.S.
    If someone asks what the heck I named my app "2792", this is the number of this thread.
    This way I keep simulation code of problems in forums.
    Last edited by josipradnik; 2015-03-05 at 11:25.

  8. #18
    Lianja Team yvonne.milne's Avatar
    Join Date
    Feb 2012
    Location
    Berkshire, UK
    Posts
    1,841
    Hi Josip,

    As I recommended in the ticket you submitted:

    Try it with a command that does not change the focus - valid() is called before the control has lost focus. e.g. instead of messageBox("...") or wait window "..."

    Lianja.writeLog("...")

    Regards,

    Yvonne

Bookmarks

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Journey into the Cloud
Join us