Using ComboBox for changing Jpanels Jtables - sql

Im new in Java GUI and i have a problem with combining ComboBox with my Jtable on Jpanel. I want to make 5 Jpanels with 1 Jtable on each of them that takes data from online SQLite database and using combobox to switch between Jpanels. Could someone give me some example how to do it?

using combobox to switch between Jpanels.
Use a Card Layout to switch between panels. The tutorial example shows you exactly how to do this.
The other approach is to use a JTabbed Pane. Again the tutorial shows how to add a panel to a different tab.

Related

VB.NET - How to Create Information Box

I'm creating a form that will display a long list of properties and their associated value. I'd like to display them in a sort of table-like control. Something with heading values at the top and a list of organized data underneath it. Something like these:
I realize those 2 examples aren't exactly the same but I'm flexible on what I produce as long as it gives a similar effect. My question is, how do I create a list like that? Is there a control in the Visual Studio toolbox that will produce this effect?
I'm sure there's something similar that easy to find but I can't figure out what to call that control so my searches haven't turned up anything useful.
Any help would be greatly appreciated. Thanks!
A combination of ListView and TabControl controls could be used to emulate what you're showing above. See the links for ListView and TabControl to help you get started.
Yes, there are windows form controls that provides this functionality.
For the tabbed windows use the TabControl:
For the different lists use a ListView control in the mode Details - which means a list with columns:
For the second feature, the ListView control has the Group features:
In order to group items togheter set the group for the chosen item(s):
All of this can be of course done programatically. There are good tutorials on MSDN and Channel9.

Embed CommandBar into Form

I'm not sure if this is at all possible, but I'd like to be able to 'embed' a CommandBar into an Access 2003 Form.
I'd like to do this because the nature of my application is such that its forms are 'floating' so it doesn't look like it was developed in Access.
I know I can put Command Buttons on the form, which would achieve something similar, but I'd like a way to differentiate between the two types of buttons.
I'll be using it (if it's possible) to have a help menu present on some Forms.
Any ideas would be greatly appriciated!
I managed to achieve a similar effect by placing labels of a different color at the top of the form, then assign custom context menus to appear on left click. This is similar to the code found here:
How to add a menu item to the default right click context menu

LongListSelector in WP8

I am trying to create my first WP8 application. I have good experience on Silverlight & WPF however this is not a cake for me which I expected :(.
I am making a Create Employ Form in which user entered different information of the employ. I need to show Country List Combobox. I noticed that in WP8, I will have to use LongListSelector but I am confused that how will I display it with my other textboxes etc control into the FORM. LongListSelector work on the full page but I want to show it like a ComboBox in simple window form application.
I know this is very basic question but I will appreciate for your help.
you cant use combobox in wp8 ...
you can use ListPicker it is a new control introduced in wp8 toolkit...
in this if your list contains less than 5 members than it will show it as dropdown otherwise it will show it as a list on a different page.
Set the Height and Width properties for Lonlistselector or otherwise change the control ListPicker simmler to CombooBox.

Closing an XAML form

I am creating a windows 8 store application using vs2012.
I am tying to switch to another xaml form by click of a button but cannot do it.
I want the code to close or hide the current form and to switch over to new form .
Regards
If you are looking to wholesale replace the content then you can use the Frame.Navigate() method.
Frame rootFrame = Window.Current.Content as Frame;
rootFrame.Navigate(typeof(YourPageClass));
or simply
this.Frame.Navigate(typeof(YourPageClass));
remember that not every elemet has property hide or something like that. If you want to hide a grid with form or do a simillar thing you need to know the property that is responsible for visibility (in most cases it is Visibility and it is a bool).
The second thing is that you can be a newbie but if you want help make some effort and give us what you want
The third thing. If you want to change a page after click use Marc`s solution

how to place the imagekey to the right side of the listview

I am trying to add an imagekey to my items and it works fine except that the image
appears on the leftside of the listview in vb.net.
What I am trying to do is have it appear on the right side or in another column,
but I can't seem to do that.
can anyone help?
Thanks
Gibit
I assume you want to have an image in some other column when the listview is in Detail mode. You can't do that in the standard .NET listview control by default. I believe you would need to override a bunch of drawing-related events and possibly deal with some Win32 calls to have images show in subitems.
However, there is an open source custom listview control for .NET called ObjectListView that supports this feature. You could use that instead of the built-in one.