• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

JInternalFrame not fit on desktopPane in full size

 
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have created a JInternalFrame Class

And call run time from JFrame class Menu Item open event.

code is following .............

DailyGreyInspectionReport ob1=new DailyGreyInspectionReport();

desktopPane.add(ob1);
ob1.setVisible(true);


when i click on open menu item JinternalFrame is open but on cover full screen.

How can i set jInternal frame in full size.

Please Help me!
 
Greenhorn
Posts: 16
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi manish, can you please be more clear as i am unable to understand what this "DailyGreyInspectionReport" class is an your problem also.
and please write the code in code tags.
 
manish kr. pandey
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sorry for my bad english.


DailyInspectionReport is a java class which extends JInternalFrame.

i am using netbeans ide to create java desktop application.

and select JInternalFrame from Swing gui category.

and add graphics component into the DailInspectionReport form.

and call DailInspectionReport file on MenuItem event of main MDI ApplicationForm which extends JFrame.
 
Rancher
Posts: 3191
29
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Read the JInternalFrame API and look at the "set" methods. You will find one that allows you to maximize the frame.
 
manish kr. pandey
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i am trying following method but NullPointerException occured.



GreyInspectionData ob=new GreyInspectionData();
try{
ob.setMaximum(true);
}catch(Exception e)
{
System.out.println(e);
}

where GreyInspectionData is a JInternalFrame Class.
 
Ranch Hand
Posts: 176
Mac Chrome Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Howdy Manish,

JInternalFrame is an extension on Component, that means you can use setSize(Dimension) on it to explicitly set its size. However I recommend you do this only if you want your frame to be a specific constant size. Using something like...is more generic if you want a resizeable window.
 
Don't MAKE me come back there with this tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
    Bookmark Topic Watch Topic
  • New Topic