×
INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Contact US

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

MDI related

MDI related

MDI related

(OP)
I have this regular MDI application. Like any MDI app,  when I open sheets through MDI window, they are added as menu items and I can nevigate from one sheet to another sheet using menu. Is there any alternate method to do the same thing without using menu?

Thanks,

RE: MDI related

hi,
you can build a statusbar at the bottom of the Frame LIKE Windows OS,when you open a sheet,register the window in the status bar,when the window is registered,"create" and show a button in the statusbar datawindow,and in the datawindow's buttonclicked event ,get current clicked window's classname,and try to open.

RE: MDI related

(OP)
Thanks... Sounds like a graat idea. Can you give some more
detail? Also please note that in my applicaton froma main window, I am opening the same window (sheet) with datawindow results again and again so I am wondering if classname still works because classname will return the same name. Any thoughts?

RE: MDI related

hi,
you are right,if opening the same sheet,the classname() returns same,i suggest you declaring an instance Variables to Flag diffent instance Sheet And Show in the Title,then you can  nevigate one to another using the Window's Title,you can refer to the Sybase PowerBuilder Code Examples (w_mdi_first_next_sheet)

sorry ,i have some idea about this ,but because of my poor English,it's Difficult to Show More Detail.

RE: MDI related

(OP)
Thanks, Your suggestion to look into code example was very good. I can get the list of opened sheets in array but I am not sure how to navigate from one to another since these window sheets are already open? Anu idea? By the way don't worry about English, you have usuful suggestions and that is really importnt. Thanks again,

RE: MDI related

thanks
if a sheet is opened ,you can use window.bringtotop = true to active the sheet.
find the function mf_open_sheet(string name) in the object m_mdi_first_next,i added some test script:

CODE

w_mdi_first_next_sheet w_instance
window list[]
integer cnt,i
string temp

if mf_is_open(name) then // if it is already open then list the open sheets
    cnt = mf_list_sheets(list)
    for i = 1 to cnt
        temp = temp + list[i].title + '~r~n'
          
          IF name = list[i].Title THEN//Founded
            list[i].BringtoTop = TRUE
          END IF
          

    next
    //messagebox('Warning',name +' is already open. The list of open sheets is below.~r~n~r~n'+temp,exclamation!)
else
    opensheetwithparm(w_instance,name,parentwindow,0,original!)
end if

RE: MDI related

(OP)
Thanks, It works!!! Now I just need to find a way (may be datawindow or ddlb) to drop this list on a main sheet window so that the list shows up on each opened sheet (inharited from main sheet). Right?

Thanks again for all  your suggestions / help.

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members! Already a Member? Login


Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close