Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

I can not see button on a frame 1

Status
Not open for further replies.

stewang

Programmer
Aug 21, 2003
77
NZ
Hello all:
I want to put some buttons on two frame, but I can not see them, when I run it.Could anyone help me? Thanks

MY code as follow;
Code:
frame .frame1 label .frame1.one -text one -background lightblue label
.frame1.two -text two -background lightgreen label .frame1.three -text
three -background yellow

frame .frame2
label .frame2.four -text four -background beige
label .frame2.five -text five -background lightgrey

pack .frame1.one .frame1.two .frame1.three -side left
pack .frame2.four .frame2.five -side right
 
All is right.
You only need to pack the frames too:
Code:
  frame .frame1 
  label .frame1.one -text one -background lightblue 
  label .frame1.two -text two -background lightgreen 
  label .frame1.three -text three -background yellow

  frame .frame2
  label .frame2.four -text four -background beige
  label .frame2.five -text five -background lightgrey

  pack .frame1.one .frame1.two .frame1.three -side left
  pack .frame2.four .frame2.five -side right
  # added pack
  pack .frame1 .frame2
HTH

ulis

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top