Populate Tab

Use this board to ask questions or have discussions with other Genie users.
Post Reply
bgrassie
New User
Posts: 8
Joined: Fri Jan 17, 2014 3:57 pm
First Name: Robert
Last Name: Grassie
Company Name: Casino Control Commission
Phone: 6094413168
Address 1: Tennessee Avenue & Boardwalk
City: Atlantic City
State / Province: New Jersey
Zip / Postal Code: 08401
Country: United States
Contact:

Populate Tab

Post by bgrassie »

On the "Green Screen" I have a page that has an enter button that takes you to page 2. When I bring this into Genie It functions as it should...you hit enter it goes to the new page hit enter again returns you to the 1st so on and so on....

I would like to put this into a new tab automatically w/o the need for user input and the ability to just select the tab to see this information. I cant seem to get it work....Any suggestions would be greatly appreciated.

Thank you in advance.....
Scott Klement
Experienced User
Posts: 2711
Joined: Wed Aug 01, 2012 8:58 am
First Name: Scott
Last Name: Klement
Company Name: Profound Logic
City: Milwaukee
State / Province: Wisconsin

Re: Populate Tab

Post by Scott Klement »

What problems are you running into?
bgrassie
New User
Posts: 8
Joined: Fri Jan 17, 2014 3:57 pm
First Name: Robert
Last Name: Grassie
Company Name: Casino Control Commission
Phone: 6094413168
Address 1: Tennessee Avenue & Boardwalk
City: Atlantic City
State / Province: New Jersey
Zip / Postal Code: 08401
Country: United States
Contact:

Re: Populate Tab

Post by bgrassie »

Scott, Im trying to put the information from page 2 onto tab 2 right now information stays on tab1...Im trying to get the information cleanly onto tab2 without any user interaction. Hitting enter works like a charm....but trying to avoid that.
Scott Klement
Experienced User
Posts: 2711
Joined: Wed Aug 01, 2012 8:58 am
First Name: Scott
Last Name: Klement
Company Name: Profound Logic
City: Milwaukee
State / Province: Wisconsin

Re: Populate Tab

Post by Scott Klement »

A tab panel is used to organize the fields on a screen. It's actual just a special field within that screen -- so it really wasn't intended as a way to switch between multiple screens... just to organize stuff that's on a single screen by putting some fields on one tab, and some on another tab. Having said that, to do what you're asking, I can think of three different approaches:

1) You could create a new screen that combines all of the fields on the two screens. Then, in the Genie designer, move the fields for one screen to one tab, and the fields for another screen to another tab. This is probably the "right" way to do it, as it'll be the easiest to maintain over time. It's also the most intuitive for programmers, because all of the fields belonging to the screen are there together on one screen.

2) If it's important not to change the underlying screen, and easy technique is to 'fake it' by putting identical tab panels on both screens. On the first screen have a tab panel where the "active tab" is 0 (the first tab) and put all the fields on that tab. On the second screen, make the 'active tab' be 1 (the second tab) and put all of the fields on that tab. Use te 'ontabclick' property to run something like pressKey("Enter"), so that when they click the tabs, it pressees enter for them automatically. It'll therefore look like they are switching tabs when they click on the tabs, even though under the covers they're really switching screens.

3) The most complex method (and one I wouldn't really recommend) is to use JavaScript to navigate to both green-screens and read all of the field info from both screens and use it to build the tab panel. Then when they are finished, the same javascript can go and fil-in the underlying 5250 fields and submit both screens (for any input fields, I mean.) This would be complex to code and hard to maintain -- and I'd only do it as a last resort.
Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests