Alpha Video Training
Results 1 to 7 of 7

Thread: how can i hide linkedgrid's child grid

  1. #1
    Member
    Real Name
    ken tjia
    Join Date
    Jan 2008
    Location
    Vancouver, BC Canada
    Posts
    560

    Default how can i hide linkedgrid's child grid

    i would like to know how to hide linked grid's child grid.
    a button on parent to show and hide is a good start.

    what i actually want it to be hidden when there is no record exist on child

  2. #2
    Volunteer Moderator
    Real Name
    James A. Talbott, Jr.
    Join Date
    Apr 2000
    Location
    Lexington, KY
    Posts
    1,459

    Default Re: how can i hide linkedgrid's child grid

    Put the child grid in a div and then check out this web page:
    http://www.plus2net.com/javascript_t...hide-layer.php

    Hope this helps.
    Jay
    Jay Talbott
    Lexington, KY


  3. #3
    Member
    Real Name
    ken tjia
    Join Date
    Jan 2008
    Location
    Vancouver, BC Canada
    Posts
    560

    Default Re: how can i hide linkedgrid's child grid

    thanks Jay,
    was hoping there is simple alpha option to simply hide them when no parent records.
    in ordinary simple linked grid, what we have is ok,
    once you get complicated (decorated) childs, the scene look ugly

  4. #4
    "Certified" Alphaholic
    Real Name
    Gaby Hernandez
    Join Date
    Sep 2008
    Posts
    1,170

    Default Re: how can i hide linkedgrid's child grid

    Ken:
    See attached.
    To hide the child grid when there are no child records and show it when there are, Peter Greulich posted a good example some time ago. I believe V11 will have a feature for this.
    Attached Files Attached Files

  5. #5
    Member
    Real Name
    ken tjia
    Join Date
    Jan 2008
    Location
    Vancouver, BC Canada
    Posts
    560

    Default Re: how can i hide linkedgrid's child grid

    Excellent solution, i have it applied as a button & tested well.

    How do we use the value of {Total_record} inside a java statement ?

    like after parent grid initialized. we found {Total_record} = 0
    then fire the java function to hide child grid(s)

    ongridrender event ?

    {
    if {Total_record} = 0;
    hidegrid(); // have the codes in java function
    }


    i am new to java, don;t believe i coded right.
    appreciate input, i am getting closer

  6. #6
    Member
    Real Name
    ken tjia
    Join Date
    Jan 2008
    Location
    Vancouver, BC Canada
    Posts
    560

    Default Re: how can i hide linkedgrid's child grid

    Assisted By Selwyn,

    Thanks...

    var count ={grid.object}._totalRecordsInGrid;
    var ele = $('gridpart');
    if(count==0) ele.style.display = 'none';
    else ele.style.display = '';


    http://screencast.com/t/x2PfyIsQ

  7. #7
    "Certified" Alphaholic
    Real Name
    Gaby Hernandez
    Join Date
    Sep 2008
    Posts
    1,170

    Default Re: how can i hide linkedgrid's child grid

    Hi Ken:
    see attached. Not the best but... close
    Attached Files Attached Files

Similar Threads

  1. Hide grid in when calling the grid a second time
    By ruudluiten in forum Application Server Version 10 - Web/Browser Applications
    Replies: 7
    Last Post: 05-20-2011, 07:52 AM
  2. LinkedGrid as field and show/hide expression
    By tekri in forum Application Server Version 10 - Web/Browser Applications
    Replies: 5
    Last Post: 04-13-2011, 11:06 AM
  3. Updating the main grid with info from the child grid in a tabed grid linker
    By Mwhite in forum Application Server Version 9 - Web/Browser Applications
    Replies: 5
    Last Post: 06-30-2009, 06:40 PM
  4. Can I hide the grid?
    By Wanda Tucker in forum Web Application Server v6
    Replies: 3
    Last Post: 09-22-2005, 07:38 AM
  5. Search hide / Grid Hide
    By David Henderson in forum Alpha Five Version 6
    Replies: 5
    Last Post: 08-07-2004, 10:24 PM

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
  •