Click here to Skip to main content
14,737,994 members
Home » Discussions » Java
   

Java

 
AnswerRe: Threads Priority Pin
Richard MacCutchan9-Oct-18 0:01
mveRichard MacCutchan9-Oct-18 0:01 
GeneralRe: Threads Priority Pin
ashutoshgadgil9-Oct-18 7:45
Memberashutoshgadgil9-Oct-18 7:45 
GeneralRe: Threads Priority Pin
Richard MacCutchan9-Oct-18 8:03
mveRichard MacCutchan9-Oct-18 8:03 
QuestionProject execution Pin
Member 138896166-Oct-18 9:46
MemberMember 138896166-Oct-18 9:46 
AnswerRe: Project execution Pin
OriginalGriff6-Oct-18 9:48
mveOriginalGriff6-Oct-18 9:48 
QuestionDeclaring one variable as multiple things. How? Pin
Member 1397832611-Sep-18 22:02
MemberMember 1397832611-Sep-18 22:02 
AnswerRe: Declaring one variable as multiple things. How? Pin
Richard MacCutchan11-Sep-18 22:24
mveRichard MacCutchan11-Sep-18 22:24 
QuestionHow to add a toolbar to JInternalFrame ? Pin
Withanam5-Sep-18 1:42
MemberWithanam5-Sep-18 1:42 
I am a beginner and trying to write a small Java MDI Application. I wrote a ToolBar class to use a common tool bar to child forms.

import java.awt.BorderLayout;
import javax.swing.*;

public class ToolBar extends JFrame {
    
    JToolBar tb;
    JButton exit;
    
    public ToolBar(){
    
        setSize(400,400);
        setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
        
        tb = new JToolBar();
        exit = new JButton("Exit");
        tb.add(exit);
        add(tb,BorderLayout.WEST);
    }


I called the class in the child form like below

public FrmItemTypes() {
      initComponents();

     ToolBar t = new ToolBar();
     t.setVisible(true);
  }


and used the menu to open the child form.

FrmItemTypes ft = new FrmItemTypes();
   this.desktopPane.add(ft);
   ft.setVisible(true);


Before use the tool bar, it is loading well. But when I say

ToolBar t = new ToolBar();
      t.setVisible(true);


the child form comes out from the main form and it shows like a normal form.(Not like a MDI child)

Please help...
AnswerRe: How to add a toolbar to JInternalFrame ? Pin
Richard MacCutchan5-Sep-18 1:50
mveRichard MacCutchan5-Sep-18 1:50 
QuestionJavaFX DatePicker update value to null [SOLVED] Pin
Valentinor3-Sep-18 2:11
MemberValentinor3-Sep-18 2:11 
AnswerRe: JavaFX DatePicker update value to null Pin
Valentinor29-Sep-18 7:53
MemberValentinor29-Sep-18 7:53 
QuestionJava cv Pin
Member 1391875527-Aug-18 18:53
MemberMember 1391875527-Aug-18 18:53 
AnswerRe: Java cv Pin
Richard MacCutchan27-Aug-18 23:01
mveRichard MacCutchan27-Aug-18 23:01 
AnswerRe: Java cv Pin
GiteHrudaya25-Nov-18 23:15
MemberGiteHrudaya25-Nov-18 23:15 
QuestionJavaFX program exit without Java JDK installed [SOLVED] Pin
Valentinor25-Aug-18 10:22
MemberValentinor25-Aug-18 10:22 
QuestionRe: JavaFX program exit without Java JDK installed Pin
Richard MacCutchan25-Aug-18 2:33
mveRichard MacCutchan25-Aug-18 2:33 
AnswerRe: JavaFX program exit without Java JDK installed Pin
Valentinor25-Aug-18 4:06
MemberValentinor25-Aug-18 4:06 
GeneralRe: JavaFX program exit without Java JDK installed Pin
Richard MacCutchan25-Aug-18 4:17
mveRichard MacCutchan25-Aug-18 4:17 
AnswerRe: JavaFX program exit without Java JDK installed Pin
Valentinor25-Aug-18 4:18
MemberValentinor25-Aug-18 4:18 
GeneralRe: JavaFX program exit without Java JDK installed Pin
Richard MacCutchan25-Aug-18 4:28
mveRichard MacCutchan25-Aug-18 4:28 
GeneralRe: JavaFX program exit without Java JDK installed Pin
Valentinor25-Aug-18 4:42
MemberValentinor25-Aug-18 4:42 
GeneralRe: JavaFX program exit without Java JDK installed Pin
Valentinor25-Aug-18 5:19
MemberValentinor25-Aug-18 5:19 
GeneralRe: JavaFX program exit without Java JDK installed Pin
Richard MacCutchan25-Aug-18 6:47
mveRichard MacCutchan25-Aug-18 6:47 
GeneralRe: JavaFX program exit without Java JDK installed Pin
Richard MacCutchan25-Aug-18 5:35
mveRichard MacCutchan25-Aug-18 5:35 
GeneralRe: JavaFX program exit without Java JDK installed Pin
Valentinor25-Aug-18 5:55
MemberValentinor25-Aug-18 5:55 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.