Combo box visual update
Hi all,
I have got a JCombobox and a JList both uses the same DefaultComboBoxModel. JList is on a dialog which edits the Vector in the Model.
My problem is,
After editing the Vector, the JComboBox items disappear. However, items place in the combo box are still visible but not the items.
Any ideas how to solve it?
>
Any ideas how to solve it?>1) Try calling comboBox.invalidate();
And if that fails..
2) Post an SSCCE of failing code.
Similar Messages
-
Combo box list update or insert restriction
Dear all,
I have a list item which type is combo box.
it shows the Departments list from the department table at run time.
i populate at through a procedure at runtime.
problem
the user could update the list by writing something into it.
i want to force the user to just select a value from the list, not update or insert.
i change the properties of the list item which prevent insertion or updation,
but it disable the selection from the list as well.
how to prevent the user to write something in the combo box list while giving him the
selection authority using the combo box list item?
Thanks and Regardsthank you dear,
but i want to use the combo box instead.
for popup list there is a problem of the null value,
you must assign a value to the popup list and set its required property to true for doing so.
and the combo box do not need this. and my desired functionality require it.
Edited by: Muhammad on Feb 28, 2010 3:10 AM
Edited by: Muhammad on Feb 28, 2010 3:21 AM -
JComboBox not visually updating after setSelectedItem
Hi there,
I'm having a strange problem wherein I have a JComboBox item, I call setSelectedItem, and visually the control does not update. It will update if I drag the window wider or move my mouse over it, but not immediately after the call. Isn't there some sort of hookup already there such that calling setSelectedItem should automatically update the combo box visually? What am I missing? Do I have to call some sort of repaint on the control after setting the selected item, or have I done something improperly?
Thanks in advance for any help you can provide me with -- this is driving me nuts!
Edited by: aardvarkk on Nov 10, 2010 7:21 PMaardvarkk wrote:
I thought perhaps the problem was that I was reusing a ComboBoxModel across several combo boxes. I've since fixed that problem, however, and the repainting is not taking place correctly. Note that if I simply write:
tagComboBox.setSelectedItem(tagAgg);
tagComboBox.repaint();
it works as I would expect. However, when I remove the call to repaint(), I have to mouse over the combo box before it shows me its 'actual' value. It may or may not be important that I'm using the Nimbus LAF?The best way to find out is to run the program with another LaF.
Why would a repaint be necessary here if I'm making the call to setSelectedItem from the EDT?It shouldn't be necessary.
db -
While updating combo box in a JTable, after updating the first row when pointer (logical) goes to the second row it says value already exists. Kindly let me know if anyone has the solution for the same.
While updating combo box in a JTable, after updating the first row when pointer (logical) goes to the second row it says value already exists. Kindly let me know if anyone has the solution for the same.
-
Hi All,
I'm developing a Form which has BP Code and a ComboBox which, after entering a valid Supplier in the BPCode EditText, updates the ComboBox with the Supplier Catalog Numbers of all the Items where the CardCode (in OITM) matches the BPCode. I have this working for the first change of BPCode but when the BPCode changes I want to update the ComboBox ValidValues. I have tried many methods but cannot remove the ValidValues which are already there. I have tried linking the ComboBox to a DataTable, clearing the DataTable and rebinding but this doesn't seem to work either.
Any help on removing ValidValues from a list when I don't know what is already there (as the VV list is now out of scope) or adding a data bound ComboBox would be most appreciated.
Thanks in anticipation,
DavidHi David,
Try following
'get the reference to the state combo box
oCombo = oForm.Items.Item("combo box unique id").Specific
'remove existing items if any
'before adding new items
For Flag = 0 To oCombo.ValidValues.Count - 1
oCombo.ValidValues.Remove(0, SAPbouiCOM.BoSearchKey.psk_Index)
Next
After this, use a recordset or datatable to retrieve the records, and than a loop to add valid values to the combo box.
Rahul -
How to update items in combo box programmat​ically
I have a problem on updating items in combo box programmatically, such as add or remove a item from the list. I can add or delete without any problem once the vi is running. I can see it is changed by pressing drop button. But after I close the vi and rerun it, the change I did last time is lost. It seems it not permenatly change the list. Anyone has an idea?
If you are changing the list programmatically why do you believe that it should be permanent? If it's permanent, why are you changing it programmatically? Doesn't make a whole lot of sense.
If you're talking about saving the values as "default" in the same way you do with the development environment, you cannot do this with an EXE. This is a FAQ. You have to update the list programmatically, saving the "new" default values to file. -
Programmatically update Combo box won't update its Local variable
Hello all,
I followed a tutorial from NI website and programmatically edit items in a combo box. It worked successfully but not for the Local variables. Local variables still retain items that it had before.
Any suggestions ?
Thanks !
Solved!
Go to Solution.You need to programmatically update the value property in order to change what the local variable will return, the value that you will wire doesn't have to match with one of the Strings[] array.
Perhaps you need to do something like this to update your value to change from "Two" to "Five". -
Strange behaviour with my updating of combo box
public class EditVideoDialog extends JPanel implements ActionListener{
JTextField text_Name, text_Price, text_Producer, path_Picture;
JTextArea textarea_Description;
public JComboBox combo_Genre, combo_Name;
String old_VideoName;
Vector <String> myVideoName = new Vector <String>();
public EditVideoDialog(){
public EditVideoDialog(Vector <String> myVideoName){
combo_Name = new JComboBox();
combo_Name.setEditable(false);
combo_Name.setMaximumRowCount(4);
combo_Name.setPreferredSize(new Dimension(300,25));
currentVideoName(myVideoName);
//Function to set current video name
public void currentVideoName(Vector <String>videoName){
combo_Name.removeAllItems();
combo_Name.addItem("");
for(int k =0; k<videoName.size(); k++){
combo_Name.addItem(videoName.get(k));
}I tried with the script above, the combo_box first got compiled nicely after retrieving data from the database.
However, when i tried to do the updating of combo box with function currentVideoName, it fails.
I also tried puttng a ComboBoxModel inside my function but it fails. It just doesn't get updated...
ComboBoxModel model = new DefaultComboBoxModel(myVideoName);
combo_Name.setModel(model);can someone advise me or show me some simple code on this?
Edited by: diskhub on Mar 16, 2008 11:27 AMhttp://forum.java.sun.com/thread.jspa?threadID=5275345
-
How do you get the value of a combo box as the operator scrolls thru the list with the arrow keys? Combo box updates once the operator presses enter but I would like the value in real-time.
Thanks,
Paul
I have attached a very small example I am working with. I need it to work with the event structure in order for it to be implemented into my current software.
Attachments:
Combo Box Update.vi 36 KBHi Novatronics,
You could try replacing it with a Dialog Ring?
See attached.
Charlie Rodway
Test Design Engineer
Rolls-Royce Controls and Data Services Ltd
Attachments:
Dialog Ring Update.vi 47 KB -
SBO 2005 combo box does not update value at first time
Hi!I developed an addon for sbo 2004 with a combo box populated with the months of the year, and it works. The same code run on SBO 2005 works only after the second selection. Has anyone found the same problem?
definition of the item:
item = form.Items.Add("oMese", SAPbouiCOM.BoFormItemTypes.it_COMBO_BOX)
item.Left = 245
item.Top = 5
item.Width = 80
item.DisplayDesc = True
combo = item.Specific
combo.DataBind.SetBound(True, "", "uMese")
combo.ValidValues.Add(1, "Gennaio")
combo.ValidValues.Add(2, "Febbraio")
event handling:
inside ItemEvent in case the item is selected
Case SAPbouiCOM.BoEventTypes.et_COMBO_SELECT
Select Case pVal.FormUID
Case "PRG_UFM_0002_RegIVAAcq"
retCode = oTy_RACQ.FormComboSelect(pVal, BubbleEvent)
Public Shared Function FormComboSelect(ByVal pVal As SAPbouiCOM.ItemEvent, _
ByRef BubbleEvent As Boolean, _
ByRef funCaller As Object, _
ByVal funCallerID As Integer, _
ByRef aForm As SAPbouiCOM.Form) _
As Integer
Dim msg As String
Dim edt As SAPbouiCOM.EditText
Dim cmb As SAPbouiCOM.ComboBox
Dim obt As SAPbouiCOM.OptionBtn
Dim cbx As SAPbouiCOM.CheckBox
Dim mtx As SAPbouiCOM.Matrix
Try
If pVal.Before_Action = True Then
Select Case pVal.ItemUID
Case "oMese"
Dim stre As New strEstremi
cmb = aForm.Items.Item("oMese").Specific
edt = aForm.Items.Item("anno").Specific
If Not cmb.Selected Is Nothing Then
GetEstremiPeriod(edt.Value, cmb.Selected.Value, "M", stre)
edt = aForm.Items.Item("dtFrom").Specific
edt.String = stre.dtFrom
edt = aForm.Items.Item("dtTo").Specific
edt.String = stre.dtTo
End If
end function
thank you I hope is enough otherwise please tell me -
I can't get my combo box to change it's list. It always displays the original list. I know that this code is being executed, cause I verified it with the debugger. I can't understand this.
String[] stringArray = {"Why","Can't","I","Change","You"};
cboMessageHeader = new javax.swing.JComboBox();
cboMessageHeader.setModel(new javax.swing.DefaultComboBoxModel(stringArray));I've also tried
cboMessageHeader = new javax.swing.JComboBox(stringArray );And
cboMessageHeader = new JComboBox(new EnumComboBoxModel(CANHeader.class));Which is what I really want to do (use the enum to create the list).
Ahh yes and thanks to anyone who responds to this, i'm pretty frustrated at the moment and help is appreciated,
NathanCould someone tell me exactly why you can't assign
cboMessageHeader = new ...
twice?you can, but the second one is a new instance of JComboBox, and not the one
you see on the screen.
to get it to work with the new comboBox, you would have to remove the old one,
then add back the new one, revalidate the panel, perhaps repaint - overall, messy.
much easier to just change the combobox's model -
How to fill combo box with list of all SQL server
Ok, I know how to find all SQL servers that I need, I have code for that task, and I have Array of all servers.
My problem is ...
I made setup project and do a huge work, and in the end this task appear!
I used ORCA tool to change TextBox (A) template in visual studio (2008 by the way), and I transform first TextBox to ComboBox.
Now, the little part that I'am missing is how to fill this combo box with a result of my function for listin SQL servers?
Can I somehow send combobox object to myMethod:
private void FillCombo(ComboBox cmb)
// do the job
or
instanceOfThisCombo.Items.Add(listOfSQLServers);
please help me to solve this... thanksc#Hi Valerij,
The ComboBox control in an MSI dialog uses the ComboBox table to populate the items in it. To get what you want, you need to update the ComboBox table in the MSI package with your application and run the MSI package. The following KB article describes how to dynamically populate a ListBox control in Windows Installer:
http://support.microsoft.com/kb/291329
This method introduced in the above KB article also applies to populating a ComboBox control in Windows Installer.
I don't think it's possible to run the application as a Custom Action from within the MSI package because the application will modify the content of the MSI package which is currently running. So you need to launch the MSI package from within your application after updating the ComboBox table. In short, when installing, just run your application which updates the ComboBox table and install the MSI package.
Hope this helps.
If you have any question, please feel free to let me know.
Sincerely,
Linda Liu -
Looping through an array to get the index for each measure in a combo box
Hi folks,
I am working on a web application that has two combo boxes, one for year (called yearcombo) and for measures (called myURL) for that selected year, and also two radiobuttons (in radioBtnGroup). I have two years and a bunch of measure for each year. I have a map tool tip that when you mouse over the county you see a measure for that specific year. However I have a bunch of measures for each year and I want to be able to loop through the measures (which are in an array collection inside a combobox) so my "if" expression can find every selectedIndex and bring me the tool tip for that selected measure for that selected radio button. Right now I would have to create if statements for each measure (each selectedIndex inside the myURL combobox)and each radiobutton (inside the radioBtnGroup) instead of creating a if expression to get a map tip tool for each measure. I know I would have to create a loop to search for these indexes and enter that in the if expression and also change the graphic.attributes to reflect the right measure or index selected. Do you API for Flex wizards can give me any tips on how to code this according to my code below ? Any help is greatly appreciated! (the print scree is attached)
Below is the code snippet:
if (yearcombo.selectedItem.year == "2007" && myURL.selectedIndex == 0 && radioBtnGroup.selectedValue == 0)
fLayer.definitionExpression = "DATA_YEAR_TXT like '2007'"
var graphic:Graphic = Graphic(event.currentTarget);
graphic.symbol = mouseOverSymbol;
var htmlText:String = graphic.attributes.htmlText;
var textArea:TextArea = new TextArea();
try{
textArea.htmlText = myURL.selectedItem.label + graphic.attributes.ForDirIndOut.toString()
myMap.infoWindow.content=textArea
myMap.infoWindow.label = graphic.attributes.NAME;
myMap.infoWindow.closeButtonVisible = false;
myMap.infoWindow.show(myMap.toMapFromStage(event.stageX, event.stageY));}
catch(error:Error) {
trace("Caught Error: "+error);
And below is the combo boxes with the arrays
<mx:FormItem label="Year :" >
<mx:ComboBox id="yearcombo" selectedIndex="0" labelField="label" width="100%" change="changeEvt(event)" >
<mx:ArrayCollection id="year" >
<fx:Object label="2007" year="2007" />
<fx:Object label="2009" year="2009" />
</mx:ArrayCollection>
</mx:ComboBox>
</mx:FormItem>
<mx:FormItem label="Measure:">
<mx:ComboBox id="myURL" selectedIndex="8" width="80%" mouseOver="clickEv2(event)" close="closeHandler(event)">
<mx:ArrayCollection id="measures" >
<fx:Object id="forindout07" labeltext="2007 Forestry Industry Output" label="Forestry Industry Output " value="RADIO_BUTTONS/TFEI_07_forest_industry_output" year="2007" />
<fx:Object id="foremp07" label="2007 Forestry Employment " value="RADIO_BUTTONS/TFEI_07_forest_employment" year="2007" />
<fx:Object id="forlabinc07" label="2007 Forestry Labor Income " value="RADIO_BUTTONS/TFEI_07_forest_labincome" year="2007" />
<fx:Object id="forindbustax07" label="2007 Forestry Indirect Business Tax" value="RADIO_BUTTONS/TFEI_07_forest_business_tax" year="2007" />
<fx:Object id="forindout09" label="Forestry Industry Output " value="RADIO_BUTTONS/TFEI_09_forest_industry_output" year="2009" />
<fx:Object id="foremp09" label="2009 Forestry Employment " value="RADIO_BUTTONS/TFEI_09_forest_employment" year="2009" />
<fx:Object id="forlabinc09" label="2009 Forestry Labor Income " value="RADIO_BUTTONS/TFEI_09_forest_labincome" year="2009" />
<fx:Object id="forindbustax09" label="2009 Forestry Indirect Business Tax" value="RADIO_BUTTONS/TFEI_09_forest_business_tax" year="2009" />
<fx:Object id="blank" label=" " />
</mx:ArrayCollection>And here is the entire code
<?xml version="1.0" encoding="utf-8"?>
<mx:Application
xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:mx="library://ns.adobe.com/flex/mx"
xmlns:esri="http://www.esri.com/2008/ags"
paddingBottom="8" paddingLeft="8"
paddingRight="8" paddingTop="8"
backgroundColor="0xffffff"
layout="vertical" >
<!-- Start Declarations -->
<fx:Declarations>
<esri:SimpleFillSymbol id="mouseOverSymbol" alpha="0.5" color="0x808080">
<esri:SimpleLineSymbol width="0" color="#000000"/>
</esri:SimpleFillSymbol>
<esri:SimpleFillSymbol id="defaultsym" alpha="0.01" color="#E0E0E0" >
<esri:SimpleLineSymbol width="1" color="#000000"/>
</esri:SimpleFillSymbol>
<!-- End Declarations -->
</fx:Declarations>
<fx:Script>
<![CDATA[
import com.esri.ags.Graphic;
import com.esri.ags.SpatialReference;
import com.esri.ags.esri_internal;
import com.esri.ags.events.GraphicEvent;
import com.esri.ags.geometry.Extent;
import com.esri.ags.layers.ArcGISDynamicMapServiceLayer;
import com.esri.ags.symbols.SimpleFillSymbol;
import com.esri.ags.symbols.SimpleLineSymbol;
import flash.utils.flash_proxy;
import mx.collections.ArrayCollection;
import mx.controls.Alert;
import mx.controls.RadioButton;
import mx.controls.TextArea;
import mx.events.DropdownEvent;
import mx.events.ItemClickEvent;
import mx.rpc.Fault;
import mx.rpc.events.FaultEvent;
import flash.display.Sprite;
import flash.events.ErrorEvent;
import flash.events.MouseEvent;
private function closeHandler(evt:DropdownEvent):void {
myLabel.text = ComboBox(evt.target).selectedItem.labeltext;
private function loadLayerName():void
myLegend.layers = null;
layerPanel.removeAllChildren();
//loop through each layer and add as a radiobutton
for(var i:uint = 0; i < (dynamicLayer.layerInfos.length); i++)
var radioBtn:RadioButton = new RadioButton;
radioBtn.groupName = "radioBtnGroup";
radioBtn.value = i;
radioBtn.label = dynamicLayer.layerInfos[i].name;
if (dynamicLayer.layerInfos[i].name == "Direct Impact (Million $)")
radioBtn.label = "Direct Impact";
else if (dynamicLayer.layerInfos[i].name == "Total Impact (Million $)")
{radioBtn.label = "Total Impact";
else if (dynamicLayer.layerInfos[i].name == "Total Impact (Jobs)")
{radioBtn.label = "Total Impact";
else if (dynamicLayer.layerInfos[i].name == "Direct Impact (Jobs)")
{radioBtn.label = "Direct Impact";
else
{radioBtn.visible= false;
layerPanel.addChild(radioBtn);
/* myDividerBox.getDividerAt(0).visible = false; */
//set the visible layer the first radio button
radioBtnGroup.selectedValue = 0;
dynamicLayer.visibleLayers = new ArrayCollection([0]);
myLegend.layers = [dynamicLayer];
myLegend.visible = true;
private function radioClickHandler(event:ItemClickEvent):void
myLegend.layers = null;
// update the visible layers to only show the layer selected
dynamicLayer.visibleLayers = new ArrayCollection([event.index]);
myLegend.layers = [dynamicLayer];
private function changeEvt(event:Event):void {
if (yearcombo.selectedItem.year == "2007")
measures.filterFunction=filter1
measures.refresh()
myURL.dataProvider=measures
else if (yearcombo.selectedItem.year == "2009")
measures.filterFunction=filter2
measures.refresh();
public function filter1(item:Object):Boolean
if (item.year=="2007") return true
else return false
public function filter2(item:Object):Boolean
if (item.year=="2009") return true
else return false
private function clickEvt(event:Event):void {
if (yearcombo.selectedItem.year == "2007")
measures.filterFunction=filter3
measures.refresh()
myURL.dataProvider=measures
else if (yearcombo.selectedItem.year == "2009")
measures.filterFunction=filter4
measures.refresh();
public function filter3(item:Object):Boolean
if (item.year=="2007") return true
else return false
public function filter4(item:Object):Boolean
if (item.year=="2009") return true
else return false
private function clickEv2(event:Event):void {
if (yearcombo.selectedItem.year == "2007")
measures.filterFunction=filter5
measures.refresh()
else if (yearcombo.selectedItem.year == "2009")
measures.filterFunction=filter6
measures.refresh();
else if (yearcombo.selectedItem.year == 2007 && myURL.selectedIndex==8)
myLegend.layers = null;
layerPanel.removeAllChildren();
public function filter5(item:Object):Boolean
if (item.year=="2007") return true
else return false
public function filter6(item:Object):Boolean
if (item.year=="2009") return true
else return false
/* IF YOU WANT TO INCLUDE OTHER VALUES IN THE MAP TOOLTIP LIKE COUNTY NAME AND THE LABEL OF THE SELECTED ITEM
if (myURL.selectedIndex==0)
myTextArea.htmlText = "<b>County: </b>" + gr.attributes.NAME + "\n"
+ "<b>Measure: </b>" + myURL.selectedItem.label + gr.attributes.ForDirIndOut.toString()
public function fLayer_graphicAddHandler(event:GraphicEvent):void
event.graphic.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverHandler);
event.graphic.addEventListener(MouseEvent.MOUSE_OUT, onMouseOutHandler);
public function onMouseOverHandler(event:MouseEvent):void
if (yearcombo.selectedItem.year == "2007" && myURL.selectedIndex == 0 && radioBtnGroup.selectedValue == 0)
fLayer.definitionExpression = "DATA_YEAR_TXT like '2007'"
var graphic:Graphic = Graphic(event.currentTarget);
graphic.symbol = mouseOverSymbol;
var htmlText:String = graphic.attributes.htmlText;
var textArea:TextArea = new TextArea();
try{
textArea.htmlText = myURL.selectedItem.label + graphic.attributes.ForDirIndOut.toString()
myMap.infoWindow.content=textArea
myMap.infoWindow.label = graphic.attributes.NAME;
myMap.infoWindow.closeButtonVisible = false;
myMap.infoWindow.show(myMap.toMapFromStage(event.stageX, event.stageY));}
catch(error:Error) {
trace("Caught Error: "+error);
if (yearcombo.selectedItem.year == "2007" && myURL.selectedIndex == 0 && radioBtnGroup.selectedValue == 1)
fLayer.definitionExpression = "DATA_YEAR_TXT like '2007'"
var graphic:Graphic = Graphic(event.currentTarget);
graphic.symbol = mouseOverSymbol;
var htmlText:String = graphic.attributes.htmlText;
var textArea:TextArea = new TextArea();
try{
textArea.htmlText = myURL.selectedItem.label + graphic.attributes.ForTotImpIndOut.toString()
myMap.infoWindow.content=textArea
myMap.infoWindow.label = graphic.attributes.NAME;
myMap.infoWindow.closeButtonVisible = false;
myMap.infoWindow.show(myMap.toMapFromStage(event.stageX, event.stageY));}
catch(error:Error) {
trace("Caught Error: "+error);
if (yearcombo.selectedItem.year == "2007" && myURL.selectedIndex == 1 && radioBtnGroup.selectedValue == 0)
fLayer.definitionExpression = "DATA_YEAR_TXT like '2007'"
var graphic:Graphic = Graphic(event.currentTarget);
graphic.symbol = mouseOverSymbol;
var htmlText:String = graphic.attributes.htmlText;
var textArea:TextArea = new TextArea();
try{
textArea.htmlText = myURL.selectedItem.label + graphic.attributes.ForDirEmp.toString()
myMap.infoWindow.content=textArea
myMap.infoWindow.label = graphic.attributes.NAME;
myMap.infoWindow.closeButtonVisible = false;
myMap.infoWindow.show(myMap.toMapFromStage(event.stageX, event.stageY));}
catch(error:Error) {
trace("Caught Error: "+error);
if (yearcombo.selectedItem.year == "2007" && myURL.selectedIndex == 1 && radioBtnGroup.selectedValue == 1)
fLayer.definitionExpression = "DATA_YEAR_TXT like '2007'"
var graphic:Graphic = Graphic(event.currentTarget);
graphic.symbol = mouseOverSymbol;
var htmlText:String = graphic.attributes.htmlText;
var textArea:TextArea = new TextArea();
try{
textArea.htmlText = myURL.selectedItem.label + graphic.attributes.ForTotImpEmp.toString()
myMap.infoWindow.content=textArea
myMap.infoWindow.label = graphic.attributes.NAME;
myMap.infoWindow.closeButtonVisible = false;
myMap.infoWindow.show(myMap.toMapFromStage(event.stageX, event.stageY));}
catch(error:Error) {
trace("Caught Error: "+error);
if (yearcombo.selectedItem.year == "2007" && myURL.selectedIndex == 2 && radioBtnGroup.selectedValue == 0)
fLayer.definitionExpression = "DATA_YEAR_TXT like '2007'"
var graphic:Graphic = Graphic(event.currentTarget);
graphic.symbol = mouseOverSymbol;
var htmlText:String = graphic.attributes.htmlText;
var textArea:TextArea = new TextArea();
try{
textArea.htmlText = myURL.selectedItem.label + graphic.attributes.ForDirLabInc.toString()
myMap.infoWindow.content=textArea
myMap.infoWindow.label = graphic.attributes.NAME;
myMap.infoWindow.closeButtonVisible = false;
myMap.infoWindow.show(myMap.toMapFromStage(event.stageX, event.stageY));}
catch(error:Error) {
trace("Caught Error: "+error);
if (yearcombo.selectedItem.year == "2007" && myURL.selectedIndex == 2 && radioBtnGroup.selectedValue == 1)
fLayer.definitionExpression = "DATA_YEAR_TXT like '2007'"
var graphic:Graphic = Graphic(event.currentTarget);
graphic.symbol = mouseOverSymbol;
var htmlText:String = graphic.attributes.htmlText;
var textArea:TextArea = new TextArea();
try{
textArea.htmlText = myURL.selectedItem.label + graphic.attributes.ForTotImpLabInc.toString()
myMap.infoWindow.content=textArea
myMap.infoWindow.label = graphic.attributes.NAME;
myMap.infoWindow.closeButtonVisible = false;
myMap.infoWindow.show(myMap.toMapFromStage(event.stageX, event.stageY));}
catch(error:Error) {
trace("Caught Error: "+error);
if (yearcombo.selectedItem.year == "2007" && myURL.selectedIndex == 3 )
fLayer.definitionExpression = "DATA_YEAR_TXT like '2007'"
var graphic:Graphic = Graphic(event.currentTarget);
graphic.symbol = mouseOverSymbol;
var htmlText:String = graphic.attributes.htmlText;
var textArea:TextArea = new TextArea();
try{
textArea.htmlText = myURL.selectedItem.label + graphic.attributes.ForIndirBusTax.toString()
myMap.infoWindow.content=textArea
myMap.infoWindow.label = graphic.attributes.NAME;
myMap.infoWindow.closeButtonVisible = false;
myMap.infoWindow.show(myMap.toMapFromStage(event.stageX, event.stageY));}
catch(error:Error) {
trace("Caught Error: "+error);
if (yearcombo.selectedItem.year == "2009" && myURL.selectedIndex == 0 && radioBtnGroup.selectedValue == 0)
fLayer.definitionExpression = "DATA_YEAR_TXT like '2009'"
var graphic:Graphic = Graphic(event.currentTarget);
graphic.symbol = mouseOverSymbol;
var htmlText:String = graphic.attributes.htmlText;
var textArea:TextArea = new TextArea();
try{
textArea.htmlText = myURL.selectedItem.label + graphic.attributes.ForDirIndOut.toString()
myMap.infoWindow.content=textArea
myMap.infoWindow.label = graphic.attributes.NAME;
myMap.infoWindow.closeButtonVisible = false;
myMap.infoWindow.show(myMap.toMapFromStage(event.stageX, event.stageY));}
catch(error:Error) {
trace("Caught Error: "+error);
if (yearcombo.selectedItem.year == "2009" && myURL.selectedIndex == 0 && radioBtnGroup.selectedValue == 1)
fLayer.definitionExpression = "DATA_YEAR_TXT like '2009'"
var graphic:Graphic = Graphic(event.currentTarget);
graphic.symbol = mouseOverSymbol;
var htmlText:String = graphic.attributes.htmlText;
var textArea:TextArea = new TextArea();
try{
textArea.htmlText = myURL.selectedItem.label + graphic.attributes.ForTotImpIndOut.toString()
myMap.infoWindow.content=textArea
myMap.infoWindow.label = graphic.attributes.NAME;
myMap.infoWindow.closeButtonVisible = false;
myMap.infoWindow.show(myMap.toMapFromStage(event.stageX, event.stageY));}
catch(error:Error) {
trace("Caught Error: "+error);
if (yearcombo.selectedItem.year == "2009" && myURL.selectedIndex == 1 && radioBtnGroup.selectedValue == 0)
fLayer.definitionExpression = "DATA_YEAR_TXT like '2009'"
var graphic:Graphic = Graphic(event.currentTarget);
graphic.symbol = mouseOverSymbol;
var htmlText:String = graphic.attributes.htmlText;
var textArea:TextArea = new TextArea();
try{
textArea.htmlText = myURL.selectedItem.label + graphic.attributes.ForDirEmp.toString()
myMap.infoWindow.content=textArea
myMap.infoWindow.label = graphic.attributes.NAME;
myMap.infoWindow.closeButtonVisible = false;
myMap.infoWindow.show(myMap.toMapFromStage(event.stageX, event.stageY));}
catch(error:Error) {
trace("Caught Error: "+error);
if (yearcombo.selectedItem.year == "2009" && myURL.selectedIndex == 1 && radioBtnGroup.selectedValue == 1)
fLayer.definitionExpression = "DATA_YEAR_TXT like '2009'"
var graphic:Graphic = Graphic(event.currentTarget);
graphic.symbol = mouseOverSymbol;
var htmlText:String = graphic.attributes.htmlText;
var textArea:TextArea = new TextArea();
try{
textArea.htmlText = myURL.selectedItem.label + graphic.attributes.ForTotImpEmp.toString()
myMap.infoWindow.content=textArea
myMap.infoWindow.label = graphic.attributes.NAME;
myMap.infoWindow.closeButtonVisible = false;
myMap.infoWindow.show(myMap.toMapFromStage(event.stageX, event.stageY));}
catch(error:Error) {
trace("Caught Error: "+error);
if (yearcombo.selectedItem.year == "2009" && myURL.selectedIndex == 2 && radioBtnGroup.selectedValue == 0)
fLayer.definitionExpression = "DATA_YEAR_TXT like '2009'"
var graphic:Graphic = Graphic(event.currentTarget);
graphic.symbol = mouseOverSymbol;
var htmlText:String = graphic.attributes.htmlText;
var textArea:TextArea = new TextArea();
try{
textArea.htmlText = myURL.selectedItem.label + graphic.attributes.ForDirLabInc.toString()
myMap.infoWindow.content=textArea
myMap.infoWindow.label = graphic.attributes.NAME;
myMap.infoWindow.closeButtonVisible = false;
myMap.infoWindow.show(myMap.toMapFromStage(event.stageX, event.stageY));}
catch(error:Error) {
trace("Caught Error: "+error);
if (yearcombo.selectedItem.year == "2009" && myURL.selectedIndex == 2 && radioBtnGroup.selectedValue == 1)
fLayer.definitionExpression = "DATA_YEAR_TXT like '2009'"
var graphic:Graphic = Graphic(event.currentTarget);
graphic.symbol = mouseOverSymbol;
var htmlText:String = graphic.attributes.htmlText;
var textArea:TextArea = new TextArea();
try{
textArea.htmlText = myURL.selectedItem.label + graphic.attributes.ForTotImpLabInc.toString()
myMap.infoWindow.content=textArea
myMap.infoWindow.label = graphic.attributes.NAME;
myMap.infoWindow.closeButtonVisible = false;
myMap.infoWindow.show(myMap.toMapFromStage(event.stageX, event.stageY));}
catch(error:Error) {
trace("Caught Error: "+error);
if (yearcombo.selectedItem.year == "2009" && myURL.selectedIndex == 3 )
fLayer.definitionExpression = "DATA_YEAR_TXT like '2009'"
var graphic:Graphic = Graphic(event.currentTarget);
graphic.symbol = mouseOverSymbol;
var htmlText:String = graphic.attributes.htmlText;
var textArea:TextArea = new TextArea();
try{
textArea.htmlText = myURL.selectedItem.label + graphic.attributes.ForIndirBusTax.toString()
myMap.infoWindow.content=textArea
myMap.infoWindow.label = graphic.attributes.NAME;
myMap.infoWindow.closeButtonVisible = false;
myMap.infoWindow.show(myMap.toMapFromStage(event.stageX, event.stageY));}
catch(error:Error) {
trace("Caught Error: "+error);
public function onMouseOutHandler(event:MouseEvent):void
var gr:Graphic = Graphic(event.target);
gr.symbol = defaultsym;
myMap.infoWindow.hide();
]]>
</fx:Script>
<fx:Style>
@namespace esri "http://www.esri.com/2008/ags";
@namespace s "library://ns.adobe.com/flex/spark";
@namespace mx "library://ns.adobe.com/flex/mx";
@namespace esri "http://www.esri.com/2008/ags";
@namespace components "com.esri.ags.components.*";
components|InfoWindow
content-background-alpha : 0.4;
background-color : #4A7138;
background-alpha : 0.7;
border-style : solid;
</fx:Style>
<mx:HBox width="930" height="800" id="mapHbox" horizontalAlign="center" >
<mx:HBox width="80">
</mx:HBox>
<mx:HBox id="myHBox" width="800" height="600" backgroundColor="0xffffff" >
<mx:VBox height="590" width="358" >
<!-- <mx:Panel
width="356" height="100%"
color="0x000000"
borderAlpha="0.15"
>
-->
<mx:Canvas height="100%" width="100%" backgroundColor="0xffffff" >
<esri:Map id="myMap" openHandCursorVisible="false"
height="100%"
logoVisible="false"
doubleClickZoomEnabled="false"
scrollWheelZoomEnabled="false"
zoomSliderVisible="false"
scaleBarVisible="false" scale="4000000" >
<esri:extent>
<esri:Extent xmin="-10736651.061900" ymin="4024099.909700" xmax="-10409195.669800" ymax="3440153.831100" >
<esri:SpatialReference wkid="102100"/>
</esri:Extent>
</esri:extent>
<esri:ArcGISDynamicMapServiceLayer id="dynamicLayer2"
url="http://tfs-24279/ArcGIS/rest/services/RADIO_BUTTONS/counties_layer/MapServer" />
<esri:ArcGISDynamicMapServiceLayer id="dynamicLayer" name=" "
alpha="1"
load="loadLayerName()"
url="http://tfs-24279/ArcGIS/rest/services/{myURL.selectedItem.value}/MapServer" />
<esri:FeatureLayer id="fLayer"
graphicAdd="fLayer_graphicAddHandler(event)"
mode="snapshot"
outFields="*"
symbol="{defaultsym}"
url= "http://tfs-24279/ArcGIS/rest/services/RADIO_BUTTONS/feature_layer_0709_five/FeatureServer/ 0" />
</esri:Map>
</mx:Canvas>
<!-- </mx:Panel>-->
</mx:VBox>
<mx:VBox height="590" width="20" >
</mx:VBox>
<mx:Canvas height="500" width="400" backgroundColor="0xffffff"
horizontalScrollPolicy="off"
verticalScrollPolicy="off" >
<mx:VBox width="420" height="50%" paddingLeft="5" paddingTop="10" paddingRight="10" paddingBottom="10"
verticalGap="8">
<mx:Form >
<mx:FormItem label="Year :" >
<mx:ComboBox id="yearcombo" selectedIndex="0" labelField="label" width="100%" change="changeEvt(event)" >
<mx:ArrayCollection id="year" >
<fx:Object label="2007" year="2007" />
<fx:Object label="2009" year="2009" />
</mx:ArrayCollection>
</mx:ComboBox>
</mx:FormItem>
<mx:FormItem label="Measure:">
<mx:ComboBox id="myURL" selectedIndex="8" width="80%" mouseOver="clickEv2(event)" close="closeHandler(event)">
<mx:ArrayCollection id="measures" >
<fx:Object id="forindout07" labeltext="Forestry Industry Output" label="Forestry Industry Output " value="RADIO_BUTTONS/TFEI_07_forest_industry_output" year="2007" />
<fx:Object id="foremp07" label="Forestry Employment " value="RADIO_BUTTONS/TFEI_07_forest_employment" year="2007" />
<fx:Object id="forlabinc07" label="Forestry Labor Income " value="RADIO_BUTTONS/TFEI_07_forest_labincome" year="2007" />
<fx:Object id="forindbustax07" label="Forestry Indirect Business Tax" value="RADIO_BUTTONS/TFEI_07_forest_business_tax" year="2007" />
<fx:Object id="forindout09" label="Forestry Industry Output " value="RADIO_BUTTONS/TFEI_09_forest_industry_output" year="2009" />
<fx:Object id="foremp09" label="Forestry Employment " value="RADIO_BUTTONS/TFEI_09_forest_employment" year="2009" />
<fx:Object id="forlabinc09" label="Forestry Labor Income " value="RADIO_BUTTONS/TFEI_09_forest_labincome" year="2009" />
<fx:Object id="forindbustax09" label="Forestry Indirect Business Tax" value="RADIO_BUTTONS/TFEI_09_forest_business_tax" year="2009" />
<fx:Object id="blank" label=" " />
</mx:ArrayCollection>
</mx:ComboBox>
</mx:FormItem>
</mx:Form>
<mx:VBox id="layerPanel" width="50%" height="8%" verticalGap="3" paddingLeft="17">
<mx:RadioButtonGroup id="radioBtnGroup" itemClick="radioClickHandler(event)" />
</mx:VBox>
<mx:VBox paddingLeft="17" height="50%" >
<mx:Canvas id="legendPanel" width="100%" >
<mx:Label id="myLabel" text=" " fontWeight="bold" />
<esri:Legend id="myLegend"
layers="{[dynamicLayer]}"
map="{myMap}" visible="false"
respectCurrentMapScale="false"/>
</mx:Canvas>
<mx:TextArea width="275" borderAlpha="0" height="200" >
<mx:htmlText >
<![CDATA[<font size='11'><b>Note:</b> Counties in white indicate either no data is available for that measure or the data has been supressed due to confidentiality.</font>
]]>
</mx:htmlText>
</mx:TextArea>
</mx:VBox>
</mx:VBox>
</mx:Canvas>
</mx:HBox>
</mx:HBox>
</mx:Application> -
I am working in access 2013 to update a database first created in Access 2003. It has been saved as an accdb but I have the same problem in earlier versions.
I have a Tab Control subform in my MainDataEntry form which has 5 different tabs. Each Tab has its own set of text boxes and combo boxes for data entry. At the top of the MainDataEntry form there is a Text box [Text393], which has a drop down with
the 5 TAB names, [Mobile Device],[Computer],[Loose Media],[Network] and [Original Device]. When I select one of these values in the Text box, I would like to automatically set focus on the first Textbox or ComboBox inside the corresponding TAB.
I have tried to do this using the MacroBuilder inside the "After Update" Property for the Text or Combo box that is on the MainDataEntry Form using "If" and "Else If" statements for the "GoToControl" action, however
I seem to be able to only get one Tab to work. I have tried several different variations of this, putting the If statement first and the action argument second...putting all arguments inside a group, or not grouped....nothing seems to work. What am I
doing wrong?
EXAMPLE:
If [Text393]=[Mobile Device] Then
GoToControl
Control Name Combo471
Else If [Text393]=[Computer] Then
GoToControl
Control Name Bios_Date
Else If [Text393]=[Loose Media] Then
GoToControl
Control Name Combo659
Else If [Text393]=[Network] Then
GoToControl
Control Name User Name
Else If [Text393]=[Original Device] Then
GoToControl
Control Name Combo814
End IfIn the Macro Builder's AfterUpdate event for [Text393]:
GoTo Control
Control Name =Forms!MainDataEntry.Controls(Text393.Value).Name
To ensure that the first control on each tab receives the focus, set that control's Tab Index property to zero (0). -
Problem in refreshing the combo box on selection of an item in another comb
I have a situation where values to be displayed in 2nd combo box depends on the selection of an item from the 1st combo box.
Problem observed:
The 2nd combo box is not getting refreshed if the selected item from the 1st combo box has mapping to more than 10 items.
for ex:
A - AA, AB, AC, AD, AE, AF
B - BA, BB, BC, BD, BE, BF, BG, BH, BI, BJ, BK, BL, BM, BN, BO, BP
C - CA, CB, CC
D - DA, DB, DC, DD
1st combo box list:
A
B
C
D
2nd combo box list:
If the value selected from the first combo box is A, C, or D then 2nd combo box refreshes with repective values. But when the value selected is B, then 2nd combo box is not getting refreshed with respective values.
Combo Model for 1st combo box:
public class proCLMLossTypeComboModel implements javax.swing.ComboBoxModel
package nz.co.towerinsurance.quantum.claims.pro;
import javax.swing.*;
import java.util.*;
import CoreProduct.mbsoPRDLossCauseTypeList;
import javax.swing.event.*;
public class proCLMLossTypeComboModel implements javax.swing.ComboBoxModel
Vector vector = null;
mbsoPRDLossCauseTypeList mbsoPRDLossCauseTypeListInst0 = null;
public void setData(Vector vector)
this.vector = vector;
public int getSize()
if(vector != null)
return this.vector.size();
else
return 0;
public void addListDataListener(ListDataListener l)
public void removeListDataListener(ListDataListener l)
public Object getElementAt(int index)
return this.vector.elementAt(index);
public Object getSelectedItem()
return this.mbsoPRDLossCauseTypeListInst0;
public void setSelectedItem(Object anItem)
mbsoPRDLossCauseTypeList mbsoPRDLossCauseTypeListInst1 = (mbsoPRDLossCauseTypeList)anItem;
this.mbsoPRDLossCauseTypeListInst0 = mbsoPRDLossCauseTypeListInst1;
public Vector getData()
return this.vector;
Combo Model for 2nd combo box:
package nz.co.towerinsurance.quantum.claims.pro;
import javax.swing.*;
import java.util.*;
import CoreProduct.mbsoPRDCauseTypeList;
import javax.swing.event.*;
public class proCLMCauseTypeComboModel implements javax.swing.ComboBoxModel
Vector vector = null;
mbsoPRDCauseTypeList mbsoPRDCauseTypeListInst0 = null;
public void setData(Vector vector)
this.vector = vector;
public int getSize()
if(vector != null)
return this.vector.size();
else
return 0;
public void addListDataListener(ListDataListener l)
public void removeListDataListener(ListDataListener l)
public Object getElementAt(int index)
return this.vector.elementAt(index);
public Object getSelectedItem()
return this.mbsoPRDCauseTypeListInst0;
public void setSelectedItem(Object anItem)
mbsoPRDCauseTypeList mbsoPRDCauseTypeListInst1 = (mbsoPRDCauseTypeList)anItem;
this.mbsoPRDCauseTypeListInst0 = mbsoPRDCauseTypeListInst1;
public Vector getData()
return this.vector;
The Panel inside which these combo boxes are used:
package nz.co.towerinsurance.quantum.claims.pro;
import nz.co.towerinsurance.quantum.logger.MessageLogger;
import nz.co.towerinsurance.quantum.claims.vmo.*;
import nz.co.towerinsurance.quantum.utility.uhoUTLDialogueContext;
import nz.co.towerinsurance.quantum.utility.uhoUTLModelHolder;
import nz.co.towerinsurance.quantum.utility.uhoUTLInteraction;
import nz.co.towerinsurance.quantum.utility.uhoUTLNotesContext;
import nz.co.towerinsurance.quantum.utility.uhoUTLPrivacyContext;
import nz.co.towerinsurance.quantum.utility.uhoUTLProcessImpContext;
import nz.co.towerinsurance.quantum.help.*;
import nz.co.towerinsurance.quantum.document.*;
import nz.co.towerinsurance.quantum.task.*;
import nz.co.towerinsurance.quantum.qtm.*;
import nz.co.towerinsurance.quantum.claims.uhoCLMClientModel;
import nz.co.towerinsurance.quantum.claims.utility.*;
import MCType.*;
import Claim.*;
import Client.*;
import Policy.*;
import CoreProduct.*;
import Security.*;
import MCUtil.*;
import java.awt.*;
import java.util.*;
import javax.swing.*;
import java.awt.event.*;
import javax.swing.border.*;
import javax.swing.ButtonGroup.*;
import java.text.*;
public class proSummaryPanel extends proCLMPanelBase implements proCLMRefreshInterface, proCLMDeclineReasonInterface
private static final MessageLogger msgLogger=MessageLogger.getLogger("claims.pro.proSummaryPanel");
uhoCLMClientModel uhoCLMClientModelInst0 = null;
Vector VectorInst0 = new Vector();
JRadioButton jRdBtnSummaryPM = new JRadioButton();
JRadioButton jRdBtnSummaryAM = new JRadioButton();
ButtonGroup ButtonGroupInst0 = new ButtonGroup();
JButton jBtnSummarySearch = new JButton();
JLabel jLblSummaryCompanyName = new JLabel();
JLabel jLblSummaryCauseType = new JLabel();
JTextField jTxtFldSummaryAmountSaved = new JTextField();
JTextField jTxtFldSummaryDateNotified = new JTextField();
JTextField jTxtFldSummary = new JTextField();
JTextField jTxtFldSummarySuburb = new JTextField();
JLabel jLblSummaryCatCode = new JLabel();
JLabel jLblSummaryLossDesc = new JLabel();
JLabel jLblSummaryDateNotified = new JLabel();
JLabel jLblSummaryCity = new JLabel();
JLabel jLblSummaryTime = new JLabel();
JLabel jLblSummaryDeclineReason = new JLabel();
JCheckBox jChkBxNcbLost = new JCheckBox();
JCheckBox jChkBxLegal = new JCheckBox();
JCheckBox jChkBxNoBlameBonus = new JCheckBox();
JLabel jLblSummaryPostCode = new JLabel();
JTextField jTxtFldSummaryStreetName = new JTextField();
JTextField jTxtFldSummaryLossDate = new JTextField();
JTextField jTxtFldSummaryCity = new JTextField();
JTextField jTxtFldSummaryTime = new JTextField();
JLabel jLblSummaryLossType = new JLabel();
JTextField jTxtFldSummaryPhone = new JTextField();
JTextField jTxtFldSummaryCompanyName = new JTextField();
JLabel jLblSummarySuburb = new JLabel();
JTextArea jTxtArLossDescription = new JTextArea();
JScrollPane jScrPnSummaryLossDesc = new JScrollPane(jTxtArLossDescription);
JTextField jTxtFldSummaryDeclineReason = new JTextField();
JPanel jPanel2 = new JPanel();
JPanel jPanel1 = this;
JLabel jLblSummaryPhone = new JLabel();
JTextField jTxtFldSummaryPostCode = new JTextField();
JLabel jLblSummaryAmountSaved = new JLabel();
JPanel jPnlSummaryCoy = new JPanel();
JLabel jLblSummaryStreetName = new JLabel();
Vector lossTypeVec = new Vector();
JComboBox jCmbBxSummaryLossType = new JComboBox(lossTypeVec);
proCLMLossTypeComboModel lossTypeComboModel = new proCLMLossTypeComboModel();
Vector causeTypeVec = new Vector();
JComboBox jCmbBxSummaryCauseType = new JComboBox();
proCLMCauseTypeComboModel causeTypeComboModel = new proCLMCauseTypeComboModel();
Vector CatCodeVec = new Vector();
JComboBox jCmbBxSummaryCatCode = new JComboBox();
proCLMCatCodeComboModel catCodeComboModel = new proCLMCatCodeComboModel();
JLabel jLblSummaryLossDate = new JLabel();
JButton jBtnSave = new JButton();
JButton jBtnCancel = new JButton();
Border border1;
TitledBorder titledBorder1;
Border border2;
Border border3;
TitledBorder titledBorder2;
Border border4;
TitledBorder titledBorder3;
GridBagLayout gridBagLayout1 = new GridBagLayout();
GridBagLayout gridBagLayout2 = new GridBagLayout();
Border border5;
TitledBorder titledBorder4;
GridBagLayout gridBagLayout3 = new GridBagLayout();
GridBagLayout gridBagLayout4 = new GridBagLayout();
Component component1;
Component component2;
* @parameter uhoUTLInteraction ,mbsoSEMPrivilege
* @return
public proSummaryPanel(proQTMBase parent, uhoUTLInteraction inter,mbsoSEMPrivilege services)
super(parent,inter,services);
try {
jbInit();
catch(Exception e) {
e.printStackTrace();
* Component initialization
* @parameter
* @return void
private void jbInit() throws Exception
component1 = Box.createHorizontalStrut(8);
component2 = Box.createHorizontalStrut(8);
jCmbBxSummaryLossType.setMinimumSize(new Dimension(225, 25));
// set the combo models
jCmbBxSummaryLossType.setModel(lossTypeComboModel);
jCmbBxSummaryCauseType.setModel(causeTypeComboModel);
jCmbBxSummaryCatCode.setModel(catCodeComboModel);
// renderer for the loss type combo
jCmbBxSummaryLossType.setRenderer(new DefaultListCellRenderer()
public Component getListCellRendererComponent(JList list, Object value,
int index, boolean isSelected, boolean cellHasFocus)
mbsoPRDLossCauseTypeList mbsoPRDLossTypeListObj = (mbsoPRDLossCauseTypeList) value;
String v = (mbsoPRDLossTypeListObj == null) ? null:mbsoPRDLossTypeListObj.GetLossTypeName().toString();
return super.getListCellRendererComponent(list,v,index,isSelected,cellHasFocus);
// key selection manager for loss type combo
jCmbBxSummaryLossType.setKeySelectionManager(new javax.swing.JComboBox.KeySelectionManager()
public int selectionForKey(char aKey,ComboBoxModel aModel)
try
Vector vector = lossTypeComboModel.getData();
// prepare a character array witht the first letter of loss types in lower case
char[] characterArray = new char[vector.size()];
for(int i=0;i<vector.size();i++)
mbsoPRDLossCauseTypeList mbsoPRDLossCauseTypeListInst0 = (mbsoPRDLossCauseTypeList)vector.elementAt(i);
char charac = mbsoPRDLossCauseTypeListInst0.GetLossTypeName().toString().toLowerCase().charAt(0);
characterArray[i] = charac;
Character char1 = new Character(aKey);
int index = 0;
if(char1.isUpperCase(aKey))
char char2 = char1.toLowerCase(aKey);
index = java.util.Arrays.binarySearch(characterArray,char2);
else
index = java.util.Arrays.binarySearch(characterArray,aKey);
if(index > 0)
jCmbBxSummaryLossType.setSelectedIndex(index);
else
jCmbBxSummaryLossType.setSelectedIndex(0);
jCmbBxSummaryLossType.repaint();
if(index > 0)
return index;
else
return 0;
catch(Exception e1)
msgLogger.fatal("Exception : proSumamryPanel : loss type combo key sel mgr : "+e1.getMessage());
return 0;
// renderer for cause type combo
jCmbBxSummaryCauseType.setRenderer(new DefaultListCellRenderer() {
public Component getListCellRendererComponent(JList list, Object value,
int index, boolean isSelected, boolean cellHasFocus)
mbsoPRDCauseTypeList mbsoPRDCauseTypeListObj = (mbsoPRDCauseTypeList) value;
String v = (mbsoPRDCauseTypeListObj == null) ? null:mbsoPRDCauseTypeListObj.GetCauseTypeName().toString();
return super.getListCellRendererComponent(list,v,index,isSelected,cellHasFocus);
// key selection manager for loss type combo
jCmbBxSummaryCauseType.setKeySelectionManager(new javax.swing.JComboBox.KeySelectionManager()
public int selectionForKey(char aKey,ComboBoxModel aModel)
try
Vector vector = causeTypeComboModel.getData();
// prepare a character array witht the first letter of loss types in lower case
char[] characterArray = new char[vector.size()];
for(int i=0;i<vector.size();i++)
mbsoPRDCauseTypeList mbsoPRDCauseTypeListInst0 = (mbsoPRDCauseTypeList)vector.elementAt(i);
char charac = mbsoPRDCauseTypeListInst0.GetCauseTypeName().toString().toLowerCase().charAt(0);
characterArray[i] = charac;
Character char1 = new Character(aKey);
int index = 0;
if(char1.isUpperCase(aKey))
char char2 = char1.toLowerCase(aKey);
index = java.util.Arrays.binarySearch(characterArray,char2);
else
index = java.util.Arrays.binarySearch(characterArray,aKey);
if(index > 0)
jCmbBxSummaryCauseType.setSelectedIndex(index);
else
jCmbBxSummaryCauseType.setSelectedIndex(0);
jCmbBxSummaryCauseType.repaint();
if(index > 0)
return index;
else
return 0;
catch(Exception e1)
msgLogger.fatal("Exception : proSumamryPanel : cause type combo key sel mgr : "+e1.getMessage());
return 0;
jBtnSummarySearch.setBorder(BorderFactory.createRaisedBevelBorder());
jBtnSummarySearch.setMaximumSize(new Dimension(119, 23));
jBtnSummarySearch.setPreferredSize(new Dimension(65, 23));
jBtnSummarySearch.setMnemonic(KeyEvent.VK_E); // 20/12
jBtnSummarySearch.setText("Search");
this.setLayout(gridBagLayout4);
ButtonGroupInst0.add(jRdBtnSummaryPM);
ButtonGroupInst0.add(jRdBtnSummaryAM);
border1 = BorderFactory.createEtchedBorder(Color.white,new Color(142, 142, 142));
titledBorder1 = new TitledBorder(border1,"Where Is It Now?");
border2 = BorderFactory.createEtchedBorder(Color.white,new Color(142, 142, 142));
border3 = BorderFactory.createEtchedBorder(Color.white,new Color(142, 142, 142));
titledBorder2 = new TitledBorder(border3,"Where Is It Now?");
border4 = BorderFactory.createEtchedBorder(Color.white,new Color(142, 142, 142));
titledBorder3 = new TitledBorder(border4,"Summary");
border5 = BorderFactory.createEtchedBorder(Color.white,new Color(142, 142, 142));
titledBorder4 = new TitledBorder(border5,"Location of Vehicle/Boat");
jScrPnSummaryLossDesc.setToolTipText("");
jScrPnSummaryLossDesc.setFont(new java.awt.Font("SansSerif", 0, 12));
jScrPnSummaryLossDesc.setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_ALWAYS);
jLblSummarySuburb.setText("Suburb");
jLblSummarySuburb.setForeground(Color.black);
jLblSummarySuburb.setPreferredSize(new Dimension(100, 17));
jLblSummarySuburb.setFont(new java.awt.Font("SansSerif", 1, 12));
jTxtFldSummaryCompanyName.setFont(new java.awt.Font("SansSerif", 0, 12));
jTxtFldSummaryCompanyName.setBorder(BorderFactory.createLoweredBevelBorder());
jTxtFldSummaryCompanyName.setMinimumSize(new Dimension(100, 20));
jTxtFldSummaryCompanyName.setPreferredSize(new Dimension(100, 20));
jTxtFldSummaryPhone.setToolTipText("");
jTxtFldSummaryPhone.setBorder(BorderFactory.createLoweredBevelBorder());
jTxtFldSummaryPhone.setMinimumSize(new Dimension(100, 20));
jTxtFldSummaryPhone.setPreferredSize(new Dimension(100, 20));
jTxtFldSummaryPhone.setFont(new java.awt.Font("SansSerif", 0, 12));
jLblSummaryLossType.setText("Loss Type");
jLblSummaryLossType.setForeground(Color.black);
jLblSummaryLossType.setPreferredSize(new Dimension(102, 17));
jLblSummaryLossType.setFont(new java.awt.Font("SansSerif", 1, 12));
jTxtFldSummaryTime.setBorder(BorderFactory.createLoweredBevelBorder());
jTxtFldSummaryTime.setMinimumSize(new Dimension(100, 20));
jTxtFldSummaryTime.setPreferredSize(new Dimension(100, 20));
jTxtFldSummaryTime.setFont(new java.awt.Font("SansSerif", 0, 12));
jTxtFldSummaryCity.setFont(new java.awt.Font("SansSerif", 0, 12));
jTxtFldSummaryCity.setBorder(BorderFactory.createLoweredBevelBorder());
jTxtFldSummaryCity.setMinimumSize(new Dimension(100, 20));
jTxtFldSummaryCity.setPreferredSize(new Dimension(100, 20));
jTxtFldSummaryLossDate.setBackground(Color.cyan);
jTxtFldSummaryLossDate.setBorder(BorderFactory.createLoweredBevelBorder());
jTxtFldSummaryLossDate.setMinimumSize(new Dimension(100, 20));
jTxtFldSummaryLossDate.setPreferredSize(new Dimension(100, 20));
jTxtFldSummaryLossDate.setFont(new java.awt.Font("SansSerif", 0, 12));
jBtnSave.setToolTipText("");
jBtnSave.setBorder(BorderFactory.createRaisedBevelBorder());
jBtnSave.setMnemonic('S');
jBtnSave.setText("Save");
jBtnSave.setPreferredSize(new Dimension(100,23)); // 30/07
jBtnSummarySearch.addActionListener(new java.awt.event.ActionListener(){
public void actionPerformed(ActionEvent e) {
jBtnSummarySearch_actionPerformed(e);
//the listener for losstype combobox
jCmbBxSummaryLossType.addItemListener(new java.awt.event.ItemListener() {
public void itemStateChanged(ItemEvent e) {
jCmbBxSummaryLossType_itemStateChanged(e);
//Actioin listener for Save button
jBtnSave.addActionListener(new java.awt.event.ActionListener()
public void actionPerformed(ActionEvent e)
jBtnSave_actionPerformed(e);
//Actioin listener for Cancel button
jTxtFldSummaryStreetName.setFont(new java.awt.Font("SansSerif", 0, 12));
jTxtFldSummaryStreetName.setBorder(BorderFactory.createLoweredBevelBorder());
jTxtFldSummaryStreetName.setMinimumSize(new Dimension(100, 20));
jTxtFldSummaryStreetName.setPreferredSize(new Dimension(100, 20));
jLblSummaryPostCode.setText("Post Code");
jLblSummaryPostCode.setForeground(Color.black);
jLblSummaryPostCode.setPreferredSize(new Dimension(100, 17));
jLblSummaryPostCode.setFont(new java.awt.Font("SansSerif", 1, 12));
jChkBxNcbLost.setFont(new java.awt.Font("SansSerif", 1, 12));
jChkBxNcbLost.setPreferredSize(new Dimension(130, 17));
jChkBxNcbLost.setText("NCB Lost");
jLblSummaryDeclineReason.setText("Decline Reason");
jLblSummaryDeclineReason.setForeground(Color.black);
jLblSummaryDeclineReason.setPreferredSize(new Dimension(102, 17));
jLblSummaryDeclineReason.setFont(new java.awt.Font("SansSerif", 1, 12));
jLblSummaryTime.setText("Time");
jLblSummaryTime.setForeground(Color.black);
jLblSummaryTime.setPreferredSize(new Dimension(35, 17));
jLblSummaryTime.setFont(new java.awt.Font("SansSerif", 1, 12));
jLblSummaryCity.setText("Town/City");
jLblSummaryCity.setForeground(Color.black);
jLblSummaryCity.setPreferredSize(new Dimension(100, 17));
jLblSummaryCity.setFont(new java.awt.Font("SansSerif", 1, 12));
jLblSummaryDateNotified.setText("Date Notified");
jLblSummaryDateNotified.setForeground(Color.black);
jLblSummaryDateNotified.setPreferredSize(new Dimension(102, 17));
jLblSummaryDateNotified.setFont(new java.awt.Font("SansSerif", 1, 12));
jLblSummaryLossDesc.setText("Loss Description");
jLblSummaryLossDesc.setForeground(Color.black);
jLblSummaryLossDesc.setPreferredSize(new Dimension(102, 17));
jLblSummaryLossDesc.setFont(new java.awt.Font("SansSerif", 1, 12));
jLblSummaryCatCode.setText("Catastrophe Code");
jLblSummaryCatCode.setForeground(Color.black);
jLblSummaryCatCode.setFont(new java.awt.Font("SansSerif", 1, 12));
jTxtFldSummarySuburb.setFont(new java.awt.Font("SansSerif", 0, 12));
jTxtFldSummarySuburb.setBorder(BorderFactory.createLoweredBevelBorder());
jTxtFldSummarySuburb.setMinimumSize(new Dimension(100, 20));
jTxtFldSummarySuburb.setPreferredSize(new Dimension(100, 20));
jTxtFldSummaryAmountSaved.setFont(new java.awt.Font("SansSerif", 0, 12));
jTxtFldSummaryAmountSaved.setBorder(BorderFactory.createLoweredBevelBorder());
jTxtFldSummaryAmountSaved.setMinimumSize(new Dimension(100, 20));
jTxtFldSummaryAmountSaved.setPreferredSize(new Dimension(100, 20));
jTxtFldSummaryDateNotified.setFont(new java.awt.Font("SansSerif", 0, 12));
jTxtFldSummaryDateNotified.setBorder(BorderFactory.createLoweredBevelBorder());
jTxtFldSummaryDateNotified.setMinimumSize(new Dimension(100, 20));
jTxtFldSummaryDateNotified.setPreferredSize(new Dimension(100, 20));
jLblSummaryCauseType.setText("Cause Type");
jLblSummaryCauseType.setForeground(Color.black);
jLblSummaryCauseType.setPreferredSize(new Dimension(102, 17));
jLblSummaryCauseType.setFont(new java.awt.Font("SansSerif", 1, 12));
jLblSummaryCompanyName.setText("Company Name");
jLblSummaryCompanyName.setForeground(Color.black);
jLblSummaryCompanyName.setPreferredSize(new Dimension(100, 17));
jLblSummaryCompanyName.setFont(new java.awt.Font("SansSerif", 1, 12));
jCmbBxSummaryCatCode.setFont(new java.awt.Font("SansSerif", 0, 12));
jCmbBxSummaryCatCode.setMinimumSize(new Dimension(225, 25)); // on 21/11
jCmbBxSummaryCatCode.setPreferredSize(new Dimension(126, 25));
jRdBtnSummaryPM.setFont(new java.awt.Font("SansSerif", 1, 12));
jRdBtnSummaryPM.setPreferredSize(new Dimension(40, 17));
jRdBtnSummaryPM.setText("pm");
jTxtFldSummaryDeclineReason.setFont(new java.awt.Font("SansSerif", 0, 12));
jTxtFldSummaryDeclineReason.setBorder(BorderFactory.createLoweredBevelBorder());
jTxtFldSummaryDeclineReason.setMinimumSize(new Dimension(225, 20));
jTxtFldSummaryDeclineReason.setPreferredSize(new Dimension(225, 20));
jChkBxLegal.setPreferredSize(new Dimension(130, 17));
jChkBxLegal.setText("Legal");
jChkBxLegal.setActionCommand("jChkBxLegal");
jChkBxLegal.setFont(new java.awt.Font("SansSerif", 1, 12));
jPanel2.setBorder(BorderFactory.createEtchedBorder());
jPanel2.setLayout(gridBagLayout1);
jPanel1.setLayout(gridBagLayout3);
jLblSummaryPhone.setFont(new java.awt.Font("SansSerif", 1, 12));
jLblSummaryPhone.setForeground(Color.black);
jLblSummaryPhone.setPreferredSize(new Dimension(100, 17));
jLblSummaryPhone.setText("Phone");
jRdBtnSummaryAM.setPreferredSize(new Dimension(40, 17));
jRdBtnSummaryAM.setText("am");
jRdBtnSummaryAM.setFont(new java.awt.Font("SansSerif", 1, 12));
jRdBtnSummaryAM.setSelected(true); // 20/12
jTxtFldSummaryPostCode.setBorder(BorderFactory.createLoweredBevelBorder());
jTxtFldSummaryPostCode.setMinimumSize(new Dimension(100, 20));
jTxtFldSummaryPostCode.setPreferredSize(new Dimension(100, 20));
jTxtFldSummaryPostCode.setFont(new java.awt.Font("SansSerif", 0, 12));
jLblSummaryAmountSaved.setText("Amount Saved");
jLblSummaryAmountSaved.setForeground(Color.black);
jLblSummaryAmountSaved.setPreferredSize(new Dimension(102, 17));
jLblSummaryAmountSaved.setFont(new java.awt.Font("SansSerif", 1, 12));
jPnlSummaryCoy.setFont(new java.awt.Font("SansSerif", 1, 12));
jPnlSummaryCoy.setBorder(titledBorder4);
jPnlSummaryCoy.setLayout(gridBagLayout2);
jLblSummaryStreetName.setFont(new java.awt.Font("SansSerif", 1, 12));
jLblSummaryStreetName.setForeground(Color.black);
jLblSummaryStreetName.setPreferredSize(new Dimension(100, 17));
jLblSummaryStreetName.setText("Street Name");
jCmbBxSummaryLossType.setBackground(Color.cyan);
jCmbBxSummaryLossType.setFont(new java.awt.Font("SansSerif", 0, 12));
jCmbBxSummaryLossType.setPreferredSize(new Dimension(225, 26));
jCmbBxSummaryCauseType.setBackground(Color.cyan);
jCmbBxSummaryCauseType.setFont(new java.awt.Font("SansSerif", 0, 12));
jCmbBxSummaryCauseType.setPreferredSize(new Dimension(225, 26));
jLblSummaryLossDate.setText("Loss Date");
jLblSummaryLossDate.setForeground(Color.black);
jLblSummaryLossDate.setPreferredSize(new Dimension(102, 17));
jLblSummaryLossDate.setFont(new java.awt.Font("SansSerif", 1, 12));
jTxtArLossDescription.setLineWrap(true);
jTxtArLossDescription.setWrapStyleWord(true);
jTxtArLossDescription.setBackground(Color.cyan);
jTxtArLossDescription.setFont(new java.awt.Font("SansSerif", 0, 12));
jTxtArLossDescription.setBounds(new Rectangle(124, 39, 394, 46));
jChkBxNoBlameBonus.setPreferredSize(new Dimension(130, 17));
jChkBxNoBlameBonus.setText("No Blame Bonus ");
jChkBxNoBlameBonus.setFont(new java.awt.Font("SansSerif", 1, 12));
jPanel1.setBorder(titledBorder3);
jPanel1.setBounds(new Rectangle(23, 11, 810, 436));
jPanel1.add(jLblSummaryCatCode, new GridBagConstraints(0, 6, 1, 1, 0.1, 0.05
,GridBagConstraints.CENTER, GridBagConstraints.HORIZONTAL, new Insets(0, 0, 0, 0), 0, 0));
jPanel1.add(jScrPnSummaryLossDesc, new GridBagConstraints(1, 1, 6, 1, 0.9, 0.15
,GridBagConstraints.SOUTHWEST, GridBagConstraints.BOTH, new Insets(0, 0, 0, 0), 0, 0));
jScrPnSummaryLossDesc.getViewport().add(jTxtArLossDescription, null);
jPanel1.add(jRdBtnSummaryPM, new GridBagConstraints(5, 0, 1, 1, 0.1, 0.05
,GridBagConstraints.CENTER, GridBagConstraints.NONE, new Insets(0, 0, 0, 0), 0, 0));
jPanel1.add(jTxtFldSummaryDeclineReason, new GridBagConstraints(1, 8, 2, 1, 0.1, 0.1
,GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(0, 0, 0, 0), 0, 0));
jPanel1.add(jLblSummaryLossDesc, new GridBagConstraints(0, 1, 1, 1, 0.1, 0.5
,GridBagConstraints.CENTER, GridBagConstraints.HORIZONTAL, new Insets(0, 0, 0, 0), 0, 0));
jPanel1.add(jLblSummaryLossType, new GridBagConstraints(0, 3, 1, 1, 0.1, 0.05
,GridBagConstraints.CENTER, GridBagConstraints.HORIZONTAL, new Insets(0, 0, 0, 0), 0, 0));
jPanel1.add(jLblSummaryCauseType, new GridBagConstraints(0, 4, 1, 1, 0.1, 0.05
,GridBagConstraints.CENTER, GridBagConstraints.HORIZONTAL, new Insets(0, 0, 0, 0), 0, 0));
jPanel1.add(jLblSummaryDeclineReason, new GridBagConstraints(0, 8, 1, 1, 0.1, 0.05
,GridBagConstraints.CENTER, GridBagConstraints.HORIZONTAL, new Insets(0, 0, 0, 0), 0, 0));
jPanel1.add(jLblSummaryLossDate, new GridBagConstraints(0, 0, 1, 1, 0.1, 0.05
,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(0, 0, 0, 0), 0, 0));
jPanel1.add(jTxtFldSummaryTime, new GridBagConstraints(3, 0, 1, 1, 0.1, 0.05
,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(0, 0, 0, 0), 0, 0));
jPanel1.add(jLblSummaryTime, new GridBagConstraints(3, 0, 1, 1, 0.1, 0.05
,GridBagConstraints.NORTH, GridBagConstraints.NONE, new Insets(0, 0, 0, 0), 107, 7));
jPanel1.add(jRdBtnSummaryAM, new GridBagConstraints(4, 0, 1, 1, 0.1, 0.05
,GridBagConstraints.CENTER, GridBagConstraints.NONE, new Insets(0, 0, 0, 0), 0, 0));
jPanel1.add(jCmbBxSummaryCauseType, new GridBagConstraints(1, 4, 2, 1, 0.1, 0.05
,GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(0, 0, 0, 0), 0, 0));
jPanel1.add(jTxtFldSummaryLossDate, new GridBagConstraints(1, 0, 1, 1, 1.0, 0.05
,GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(0, 0, 0, 0), 0, 0));
jPanel1.add(jTxtFldSummaryDateNotified, new GridBagConstraints(1, 7, 1, 1, 0.1, 0.05
,GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(0, 0, 0, 0), 0, 0));
jPanel1.add(jPanel2, new GridBagConstraints(0, 9, 6, 1, 1.0, 0.1
,GridBagConstraints.CENTER, GridBagConstraints.BOTH, new Insets(0, 0, 0, 0), 0, 0));
jPanel2.add(jChkBxNoBlameBonus, new GridBagConstraints(3, 0, 1, 1, 0.1, 0.0
,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(0, 0, 0, 0), 0, 0));
jPanel2.add(jChkBxLegal, new GridBagConstraints(4, 0, 1, 1, 0.1, 0.0
,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(0, 0, 0, 0), 0, 0));
jPanel2.add(jBtnSave, new GridBagConstraints(5, 0, 1, 1, 0.1, 0.0
,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(0, 0, 0, 0), 0, 0));
jPanel2.add(jChkBxNcbLost, new GridBagConstraints(2, 0, 1, 1, 0.1, 0.0
,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(0, 0, 0, 0), 0, 0));
jPanel2.add(component1, new GridBagConstraints(1, 0, 1, 1, 0.35, 0.0
,GridBagConstraints.CENTER, GridBagConstraints.HORIZONTAL, new Insets(0, 0, 0, 0), 0, 0));
jPanel2.add(component2, new GridBagConstraints(5, 0, 1, 1, 0.35, 0.0
,GridBagConstraints.CENTER, GridBagConstraints.HORIZONTAL, new Insets(0, 0, 0, 0), 0, 0));
jPanel1.add(jCmbBxSummaryLossType, new GridBagConstraints(1, 3, 2, 1, 0.1, 0.05
,GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(0, 0, 0, 0), 0, 0));
jPanel1.add(jCmbBxSummaryCatCode, new GridBagConstraints(1, 6, 2, 1, 0.1, 0.05
,GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(0, 0, 0, 0), 0, 0));
jPanel1.add(jPnlSummaryCoy, new GridBagConstraints(2, 3, 4, 6, 1.0, 0.0
,GridBagConstraints.CENTER, GridBagConstraints.BOTH, new Insets(0, 0, 0, 0), 0, 0));
jPnlSummaryCoy.add(jLblSummaryPhone, new GridBagConstraints(0, 6, 1, 1, 0.5, 0.16
,GridBagConstraints.CENTER, GridBagConstraints.NONE, new Insets(0, 0, 0, 0), 0, 0));
jPnlSummaryCoy.add(jLblSummarySuburb, new GridBagConstraints(0, 3, 1, 1, 0.5, 0.16
,GridBagConstraints.CENTER, GridBagConstraints.NONE, new Insets(0, 0, 0, 0), 0, 0));
jPnlSummaryCoy.add(jTxtFldSummaryStreetName, new GridBagConstraints(1, 2, 1, 1, 0.5, 0.16
,GridBagConstraints.CENTER, GridBagConstraints.HORIZONTAL, new Insets(0, 0, 0, 0), 0, 0));
jPnlSummaryCoy.add(jTxtFldSummaryCity, new GridBagConstraints(1, 4, 1, 1, 0.5, 0.16
,GridBagConstraints.CENTER, GridBagConstraints.HORIZONTAL, new Insets(0, 0, 0, 0), 0, 0));
jPnlSummaryCoy.add(jTxtFldSummaryPostCode, new GridBagConstraints(1, 5, 1, 1, 0.5, 0.16
,GridBagConstraints.CENTER, GridBagConstraints.HORIZONTAL, new Insets(0, 0, 0, 0), 0, 0));
jPnlSummaryCoy.add(jTxtFldSummarySuburb, new GridBagConstraints(1, 3, 1, 1, 0.5, 0.16
,GridBagConstraints.CENTER, GridBagConstraints.HORIZONTAL, new Insets(0, 0, 0, 0), 0, 0));
jPnlSummaryCoy.add(jLblSummaryPostCode, new GridBagConstraints(0, 5, 1, 1, 0.5, 0.16
,GridBagConstraints.CENTER, GridBagConstraints.NONE, new Insets(0, 0, 0, 0), 0, 0));
jPnlSummaryCoy.add(jTxtFldSummaryPhone, new GridBagConstraints(1, 6, 1, 1, 0.5, 0.16
,GridBagConstraints.CENTER, GridBagConstraints.HORIZONTAL, new Insets(0, 0, 0, 0), 0, 0));
jPnlSummaryCoy.add(jTxtFldSummaryCompanyName, new GridBagConstraints(1, 0, 1, 1, 0.5, 0.16
,GridBagConstraints.CENTER, GridBagConstraints.HORIZONTAL, new Insets(0, 0, 0, 0), 0, 0));
jPnlSummaryCoy.add(jLblSummaryCompanyName, new GridBagConstraints(0, 0, 1, 1, 0.5, 0.16
,GridBagConstraints.CENTER, GridBagConstraints.NONE, new Insets(0, 0, 0, 0), 0, 0));
jPnlSummaryCoy.add(jLblSummaryStreetName, new GridBagConstraints(0, 2, 1, 1, 0.5, 0.16
,GridBagConstraints.CENTER, GridBagConstraints.NONE, new Insets(0, 0, 0, 0), 0, 0));
jPnlSummaryCoy.add(jLblSummaryCity, new GridBagConstraints(0, 4, 1, 1, 0.5, 0.16
,GridBagConstraints.CENTER, GridBagConstraints.NONE, new Insets(0, 0, 0, 0), 0, 0));
jPanel1.add(jLblSummaryDateNotified, new GridBagConstraints(0, 7, 1, 1, 0.1, 0.05
,GridBagConstraints.EAST, GridBagConstraints.HORIZONTAL, new Insets(0, 0, 0, 0), 0, 0));
jPanel1.add(jBtnSummarySearch, new GridBagConstraints(1, 5, 1, 1, 0.0, 0.0
,GridBagConstraints.CENTER, GridBagConstraints.NONE, new Insets(0, 0, 0, 0), 0, 0));
jTxtFldSummaryLossDate.grabFocus();
jTxtFldSummaryLossDate.setNextFocusableComponent(jTxtFldSummaryTime);
jTxtFldSummaryTime.setNextFocusableComponent(jRdBtnSummaryAM);
jRdBtnSummaryAM.setNextFocusableComponent(jRdBtnSummaryPM);
jRdBtnSummaryPM.setNextFocusableComponent(jTxtArLossDescription);
jTxtArLossDescription.setNextFocusableComponent(jCmbBxSummaryLossType);
jCmbBxSummaryLossType.setNextFocusableComponent(jCmbBxSummaryCauseType);
jCmbBxSummaryCauseType.setNextFocusableComponent(jBtnSummarySearch);
jBtnSummarySearch.setNextFocusableComponent(jCmbBxSummaryCatCode);
jCmbBxSummaryCatCode.setNextFocusableComponent(jTxtFldSummaryDateNotified);
jTxtFldSummaryDateNotified.setNextFocusableComponent(jTxtFldSummaryDeclineReason);
jTxtFldSummaryDeclineReason.setNextFocusableComponent(jTxtFldSummaryCompanyName);
jTxtFldSummaryCompanyName.setNextFocusableComponent(jTxtFldSummaryStreetName);
jTxtFldSummaryStreetName.setNextFocusableComponent(jTxtFldSummarySuburb);
jTxtFldSummarySuburb.setNextFocusableComponent(jTxtFldSummaryCity);
jTxtFldSummaryCity.setNextFocusableComponent(jTxtFldSummaryPostCode);
jTxtFldSummaryPostCode.setNextFocusableComponent(jTxtFldSummaryPhone);
jTxtFldSummaryPhone.setNextFocusableComponent(jChkBxNcbLost);
jChkBxNcbLost.setNextFocusableComponent(jChkBxNoBlameBonus);
jChkBxNoBlameBonus.setNextFocusableComponent(jChkBxLegal);
jChkBxLegal.setNextFocusableComponent(jBtnSave);
jBtnSave.setNextFocusabl &nbsthe very simple strategy to do is to call removeAllItems() method for the 2nd combox box and then insert the contents. this is because the validate() method is not repeatedly called and so the contents are not updated immediately.
Maybe you are looking for
-
Float value giving exception.
Hi, I am using a bean for a shopping cart. I used this code public float getCost() Enumeration enum=hashtable.elements(); String[] tmpItem; float totalCost=0.00f; while(enum.hasMoreElements()) tm
-
Since upgrading to Yosemite on my Mac, photoshop cs5 will only print in bw. I can print in color from Word but not photoshop. I have updated all drivers and cs5. Any suggestions would be appreciated. Thank you!
-
Serial number ignored when I try to authorize AP 2.01 Trial
I have just bought the AP 2 online and immediately received a serial number in the mail. I started the AP 2.01 trial and pressed "Authorize". I entered my name and the serial sent to me, but it is completely ignored? When I press ok (or done? I forge
-
Need advice about Oracle 10G ex
Newbie question. I have set up Oracle db express on a Redhat Linux FC 8 box. It is in a workgroup with several MS computers. I have Samba runnning on the linux box and it shows up in XP network neighborhood. N\ow I need to access the ex Db instance r
-
So, I've purchased a Mac mini to replace my aging Mid 2009 mini on which I've been running Mavericks Server. In trying to answer the question of how best to move services from the old machine to the new, I've stumbled into the fact that Migration As