WRT120N problem setting Static IP
My provider gives me static IP
IP 172.17.158.183
MASK 255.255.252.0
GW 172.17.156.255
There is a problem setting gateway 172.17.156.255 in WRT120N. It says that it's wrong gateway.
On my notebook Network settings work, but how can I setup WRT120N to work with this network settings?
Solved!
Go to Solution.
You are not right.
Using search I found solution fo my problem.
http://homecommunity.cisco.com/t5/Wireless-Routers/Bug-report-CIDR/m-p/311698/highlight/true#M163772
And it's work fine now.
There is a bug in scripts that check gateway, mask and IP.
Similar Messages
-
Problems setting up static routing
HI
I'm having a problem setting up static routing. I keep getting the message "invalid static route". I have an E1550 router and my frimware is up to date. I have tried a few different gateway addresses ie 192.168.1.1, 127.0.0.1 and my router's address on the net, but I keep getting the same message. Has anyone else had this problem and been able to fix it?I think the E1550 router supports LAN to LAN routing provided that you have two local networks. If you only have a plain modem and the E1550, I believe you can't do Static routing on that type of setup. Found this link that might help: http://kb.linksys.com/Linksys/ukp.aspx?vw=1&docid=12a84336a124498eb5d6f0204b85191e_17589.xml&pid=80&...
-
Problems setting up username & password for SQL
Due to the outstanding advice I recieved from this excellent forum, I have managed to overcome my first problem with declaring a new Class.
This leads me to request help with my next biggest problem:
Setting up a user GUI that takes a "username" & "password" that will be used to access a password protected database.
I am a simple bloke, with simple thought processes, so please, go easy on me...
import java.awt.*;
import java.awt.event.*;
import javax.swing.*;
import java.sql.*;
public class DBQuery1 {
String username = "" , password = "";
public static void main(String[] arguments) {
PassDB UPass = new PassDB();
String data = "jdbc:odbc:JavaTestDataBase";
try {
Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
Connection conn = DriverManager.getConnection(data, "" + username, "" + password);
Statement st = conn.createStatement();
ResultSet rec = st.executeQuery(
"SELECT Title, ContactID, First, Last, Dear FROM Contacts "
+ "WHERE (Title='Mr') ORDER BY ContactID");
/* ResultSet rec2 = st.executeQuery(
"SELECT Subject, ContactID FROM Calls "
+ "WHERE (Subject Is Not Null) ORDER BY ContactID");
System.out.println("\nFirst Name\tSurname\t\tNick Name\t\tSubject\n");
while(rec.next()) {
System.out.println(rec.getString(3) + "\t\t" + rec.getString(4) + "\t\t" + rec.getString(5) /* + rec2.getString(1) */ );
st.close();
catch (SQLException s) {
System.out.println("SQL Error: " + s.toString() + " " + s.getErrorCode() + " " + s.getSQLState());
catch (Exception e) {
System.out.println("Error: " + e.toString() + e.getMessage());
class PassDB extends javax.swing.JFrame implements ActionListener {
String username = "", password = "";
JTextField uname = new JTextField(10);
JTextField pword = new JTextField(10);
// JPasswordField pword = new JTextField(10);
PassDB() {
super("duBe's database logon");
setSize(220, 160);
setDefaultCloseOperation(EXIT_ON_CLOSE);
JPanel pane = new JPanel();
JLabel unameLabel = new JLabel ("Username: ");
JLabel pwordLabel = new JLabel ("Password: ");
JButton submit = new JButton("OK");
submit.addActionListener(this);
pane.add(unameLabel);
pane.add(uname);
pane.add(pwordLabel);
pane.add(pword);
pane.add(submit);
setContentPane(pane);
setVisible(true);
public void actionPerformed(ActionEvent evt) {
PassDB clicked = (PassDB)evt.getSource();
username = uname.getText();
password = pword.getText();
This code generates two errors, stating:
C:\Java_progs>javac DBQuery1.java
DBQuery1.java:14: non-static variable username cannot be referenced from a static context
Connection conn = DriverManager.getConnection(data, "" +
username, "" + password);
^
DBQuery1.java:14: non-static variable password cannot be referenced from a static context
Connection conn = DriverManager.getConnection(data, "" +
username, "" + password);
^
2 errors*****************************
The code works when I remove the reference to the variables "username" & "password" in Connection "conn" call & replace them with the actual username & password, but this is not exactly what I was after. I was hoping to make the program responsive to each individual user, not set in code.
I also would like to make the program pause after the call in "main" to "PassDB" to wait for "PassDB" to exit before continuing.
I would also like to make "PassDB" destroy itself after the "OK" button is pressed & the "username" & "password" set.
If that isn't enough for you, I would really like the program to search 2 different database tables, return their values & compare them to be sure that they are the same.
When I try & search 2 different tables, as in:
ResultSet rec = st.executeQuery(
"SELECT Title, ContactID, First, Last, Dear FROM Contacts "
+ "WHERE (Title='Mr') ORDER BY ContactID");
ResultSet rec2 = st.executeQuery(
"SELECT Subject, ContactID FROM Calls "
+ "WHERE (Subject Is Not Null) ORDER BY ContactID")javac tells me that "ResultSet" is set to null 0
As always, I am extremely appreciative of any assistance you are able to offer.
Kind regards
duBedat
[email protected]This is where I'm at now:
import java.awt.*;
import java.awt.event.*;
import javax.swing.*;
import java.sql.*;
public class DBQuery {
static String username = "" ;
static String password = "" ;
public static void main(String[] arguments) {
PassDB UPass = new PassDB();
String data = "jdbc:odbc:JavaTestDataBase";
try {
Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
Connection conn = DriverManager.getConnection(data, "" + DBQuery.username, "" + DBQuery.password);
Statement st = conn.createStatement();
ResultSet rec = st.executeQuery(
"SELECT Title, ContactID, First, Last, Dear FROM Contacts "
+ "WHERE (Title='Mr') ORDER BY ContactID");
/* ResultSet rec2 = st.executeQuery(
"SELECT Subject, ContactID FROM Calls "
+ "WHERE (Subject Is Not Null) ORDER BY ContactID");
System.out.println("\nFirst Name\tSurname\t\tNick Name\t\tSubject\n");
while(rec.next()) {
System.out.println(rec.getString(3) + "\t\t" + rec.getString(4) + "\t\t" + rec.getString(5) /* + rec2.getString(1) */ );
st.close();
catch (SQLException s) {
System.out.println("SQL Error: " + s.toString() + " " + s.getErrorCode() + " " + s.getSQLState());
catch (Exception e) {
System.out.println("Error: " + e.toString() + e.getMessage());
class PassDB extends javax.swing.JFrame implements ActionListener {
static boolean getOut = false;
JTextField uname = new JTextField(10);
JTextField pword = new JTextField(10);
// JPasswordField pword = new JTextField(10);
public PassDB() {
super("duBe's database logon");
setSize(220, 160);
setDefaultCloseOperation(EXIT_ON_CLOSE);
JPanel pane = new JPanel();
JLabel unameLabel = new JLabel ("Username: ");
JLabel pwordLabel = new JLabel ("Password: ");
JButton submit = new JButton("OK");
submit.addActionListener(this);
pane.add(unameLabel);
pane.add(uname);
pane.add(pwordLabel);
pane.add(pword);
pane.add(submit);
setContentPane(pane);
while(getOut == false)
setVisible(true);
public void actionPerformed(ActionEvent evt) {
PassDB clicked = (PassDB)evt.getSource();
DBQuery.username = uname.getText();
DBQuery.password = pword.getText();
getOut = true;
} Any advice is greatly appreciated
duBe -
A Chairde,
Am having problems setting up MPLS between a AS5350 and 7609 , I have used commands stated in this link, enable MPLS incrementally on a network.
http://www.cisco.com/univercd/cc/td/doc/product/software/ios121/121cgcr/switch_c/xcprt4/xcdtagc.pdf
The commands below are added to each router, and some troubleshooting.
7609
ip cef distributed
interface Loopback0
ip address 192.168.254.1 255.255.255.255
tag-switching advertise-tags
interface GigabitEthernet3/12
ip address 192.168.230.162 255.255.255.248
mpls label protocol tdp
tag-switching ip
AS5350
ip cef
mpls label protocol tdp
tag-switching advertise-tags
interface Loopback0
ip address 192.168.254.2 255.255.255.255
interface FastEthernet0/0
ip address 192.168.230.161 255.255.255.248
duplex auto
speed auto
mpls ip
h323-gateway voip interface
h323-gateway voip id cnibhco111 ipaddr 192.168.230.129 1719
h323-gateway voip h323-id cnibhco112
h323-gateway voip tech-prefix 71401
h323-gateway voip tech-prefix 0030
h323-gateway voip bind srcaddr 192.168.230.161
ip rsvp bandwidth 64 64
cnibhco112#sh tag-switching tdp neighbor
Peer TDP Ident: 192.168.254.1:0; Local TDP Ident 192.168.230.161:0
TCP connection: 192.168.254.1.49842 - 192.168.230.161.711
State: Oper; PIEs sent/rcvd: 18/23; Downstream
Up time: 00:12:54
TDP discovery sources:
FastEthernet0/0, Src IP addr: 192.168.230.162
Addresses bound to peer TDP Ident:
192.168.100.17 192.168.100.25 159.107.212.49 172.16.8.81
192.168.230.130 192.168.230.77 192.168.230.81 192.168.254.1
192.168.210.6 192.168.127.6 192.168.210.106 192.168.127.66
192.168.127.138 192.168.210.146 192.168.210.142 192.168.210.122
192.168.210.17 192.168.230.140 192.168.230.26 192.168.230.74
192.168.230.10 192.168.230.14 192.168.127.130 192.168.127.142
192.168.230.6 192.168.230.70 192.168.230.34 192.168.210.178
192.168.200.25 192.168.210.126 192.168.232.1 192.168.231.1
192.168.200.17 192.168.210.102 190.168.200.245 190.168.200.225
190.168.201.241 192.168.230.98 192.168.210.14 190.168.201.201
190.168.201.209 192.168.210.162 192.168.210.210 190.168.201.205
192.168.230.38 190.168.200.249 190.168.200.217 190.168.200.253
192.168.230.162
cnibhco112#
cnibhco112#sh tag-switching forwarding-table 192.168.254.1 detail
Local Outgoing Prefix Bytes tag Outgoing Next Hop
tag tag or VC or Tunnel Id switched interface
cnibhco112#traceroute 192.168.254.1
Type escape sequence to abort.
Tracing the route to 192.168.254.1
1 192.168.230.162 0 msec 0 msec *
cnibhco112#traceroute 192.168.230.162
Type escape sequence to abort.
Tracing the route to 192.168.230.162
1 192.168.230.162 0 msec 0 msec *
cnibhco112#Ro,
Thanks for the respone, have been playin, with MPLS for last few hours.
The routing between the loopbacks is now working, can PING 7609 Loopback from AS5350 ,and vice versa. (used static routes).
Having problem with TDP / LDP on routers,
mpls label protocol ldp / tdp command works correctly on both routers, but the
tag-switching tdp router-id Loopback0 force
command works on the 7609, but when I add it onto the AS5350 , the command "mpls ldp router-id Loopback0 force" appears on the startup script.
The opposite is true for the 7609 , you add MPLS LDP command, and TAG-SWITCHING command appears instead.
Any Ideas, as different configs of this leave me with forwarding table with both tags added, but not been able to ping the loopbacks !!!
When I can ping bot loopbacks, the OUTGOING TAG , disapears.....
Problem is LOOPBACK Commands on bot routers default to LDP (AS5350) , or TDP (7609). Any Ideas ...
mpls label protocol tdp
tag-switching tdp router-id Loopback0 force
mpls label protocol tdp
mpls ldp router-id Loopback0 force
cnibhco100#sh tag-switching forwarding-table 192.168.254.2 detail
Local Outgoing Prefix Bytes tag Outgoing Next Ho
tag tag or VC or Tunnel Id switched interface
18 17 192.168.254.0/24 0 Gi3/12 192.168.2
MAC/Encaps=14/18, MRU=1500, Tag Stack{17}
00097CA3293000127FCDBA808847 00011000
No output feature configured
Per-packet load-sharing
cnibhco100#traceroute 192.168.254.2
Type escape sequence to abort.
Tracing the route to 192.168.254.2
1 192.168.230.161 [MPLS: Label 17 Exp 0] 0 msec 0 msec 0 msec
2 192.168.230.162 0 msec 0 msec 0 msec
But no PINGING 192.168.254.2
cnibhco112#sh tag-switching forwarding-table 192.168.254.1 detail
Local Outgoing Prefix Bytes tag Outgoing Next Hop
tag tag or VC or Tunnel Id switched interface
17 18 192.168.254.0/24 1915668 Fa0/0 192.168.230.162
MAC/Encaps=14/18, MRU=1500, Tag Stack{18}
00127FCDBA8000097CA329308847 00012000
No output feature configured
Per-packet load-sharing
cnibhco100#sh tag-switching forwarding-table 192.168.254.2 detail
Local Outgoing Prefix Bytes tag Outgoing Next Ho
tag tag or VC or Tunnel Id switched interface
18 17 192.168.254.0/24 752551 Gi3/12 192.168.2
MAC/Encaps=14/18, MRU=1500, Tag Stack{17}
00097CA3293000127FCDBA808847 00011000
No output feature configured
Per-packet load-sharing
WHEN BOTH LOCAL AND OUTGOING TAG, CANNOT PING EITHER WAY !!!
HAVE LABEL PROTOCOL AND LOOPBACK FORCE on AS5350
HAVE LABEL PROTOCOL ON 7609
WHEN ADD LOOPBACK FORCE on 7609 , CAN PING BOTH LOOPBACKS,
BUT OUTGOING TAG DISAPEARS
cnibhco112#PING 192.168.254.2
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.254.2, timeout is 2 seconds:
Success rate is 100 percent (5/5), round-trip min/avg/max = 1/1/1 ms
cnibhco112#sh tag-switching forwarding-table 192.168.254.1 detail
Local Outgoing Prefix Bytes tag Outgoing Next Hop
tag tag or VC or Tunnel Id switched interface
17 Untagged 192.168.254.0/24 598678 Fa0/0 192.168.230.162
MAC/Encaps=0/0, MRU=1504, Tag Stack{}
No output feature configured
Per-packet load-sharing
cnibhco112#
mpls label protocol tdp
tag-switching tdp router-id Loopback0 force -
How to set static IP for C4599 printer ???
Was afraid if we clicked 'answered' <per 'answer' below> we may never get an answer to a followup question to 'PrintDoc' at http://h30434.www3.hp.com/psg/board/message?board.id=Networking&thread.id=5277 .
Hopefully this re-post will help.
Question/s...
1. When trying to set 'static IP', and click on 'this' link ( http://h30434.www3.hp.com/t5/forums/replypage/board-id/Networking/message-id/NetGear%20'RangeMax'%20... ) at your email < below> get...
"An Unexpected Error has occurred."
2. Also, getting printing error after HP Director shows C4500 wireless connected and starts printing.
At 'Component Services' / 'Event Properties' shows...
"The document http://wwwapps.ups.com/WebTracking/processInputRequest?HTMLVers owned by Alan failed to print on printer HP Photosmart C4500 series (Wireless). Data type: NT EMF 1.008. Size of the spool file in bytes: 48960. Number of bytes printed: 0. Total number of pages in the document: 2. Number of pages printed: 0. Client machine: \\AKM. Win32 error code returned by the print processor: 2250 (0x8ca).
For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp."
When click on 'events.aps' link get...
'Event Viewer' showing 'xpsp2res.dll' file info ?
Does #2. have anything to do with 'IP' question, and will 'static IP' fix ?"
Please advise.
Thanks much.
Original answer...
10-13-2009 10:03 AM
PrintDoc
Master's Graduate
Posts: 1383
Registered: 08-19-2009
Message 8 of 10
Viewed 481 times
Re: C4599, wireless Error-Printing, unable to 'communicate' with the device ???
Sure we can set a static IP (actually we are going to reserve an IP address - even better). But first, please mark the post that helped you solve the problem as "Accepted Solution".
Connect to the wireless router by typing the IP address of the wireless router in the address field of your browser, then click Enter. 192.168.1.1 is the default IP address of the wireless router. The wireless router will prompt you to enter the user name of 'admin' and the password. The default password is 'password'.
See the procedure on page 8-16 of this < http://h30434.www3.hp.com/t5/forums/replypage/board-id/Networking/message-id/NetGear%20'RangeMax'%20... > document to reserve and IP address for your printer.
You will need the MAC address of your printer (this is on the Network Config Page you printed from the front panel of the printer).
(Although I am employed by HP, I am speaking for myself and not for HP)
Original Posters - please mark the post that solves your problem as "Accepted Solution"
Thanks again for your help !
akm (XPproSP-3,IE-7,Office2003)
This question was solved.
View Solution.Thank you for the followup.
Just got back to this thread after trying what you suggested re new install program.
Months ago, when originally tried to install new C4500, spent weekend, literally 4hrs on a Sat and 4hrs the following Sun with HP support on the phone trying to get C4500 wireless to work.
Finally downloaded a new install program and after installing that and making other numerous setup adjustments, which I cant remember, it worked (the only saving grace for the time spent) for a while.
But for the sake of trying, we did put in the original disk, just like page 4 (or our original paper manual) instructed (per your last post).
The disk loaded and the program did its thing and then get...
"A newer version fo this software is alredy installe on you HP HPPhotosmare C4500 series computer."
So clicked 'finish'.
Then loaded...
PS_AIO_04_C4500_USW_Full_Win_enu_120_210_NB.exe
...which we thougth was the new installer program which we downloaded those months ago (same one you suggested).
Started the '4 step' process.
Got to 'step 3' and it connected to printer with usb cable.
Along the way got message from 'network diagnostics'...
"The PC and the printer are connected to different networks(192.168.1.0 and 192.168.0.0). They must be connected to the same network. This can happen when you use the manufacturer's default network name (SSID) and another nearby network is using the same name.
The gateway address of the printer does not match the network to which the printer is connected. Reconfigure the setting on your printer to match."
Tried changing ip addresses at network settings, but no help.
Clicked on disregard and proceed.
Started 'Network diagnostics' and got...
HPPhotoshopEssential 'install' bar window.
Either way, disk or new install program, get pop-up window with message...
'The feature you are tryong to use is on a CD-ROM or tother removabledisk that inot available. Insert the 'HPPyotosmartEsesential' disk and click OK."
Moved HP .msi and .cab files to same directory with ...NB.exe file.
Install went ahead, and then needed 'setup.exe'.
Opened setup.exe at disk and install went ahead.
Installed latext updated 'HP Solution Center'.
It showed both the C4500usb and wireless, but still wireless not 'connected'.
Ran diagnostics and got same 'diagnostics' message as above.
Made sure hardware enabled etc.
How to fix ?
Thanks again for your help !
akm (XPproSP-3,IE-7,Office2003) -
Unable to set static ip on Network Manager
when i try to set static ip on Network manager
i open the applet on gnome,change the ip setting and when i try to save, appear for a nano-second the authentication window and disappear
this happens only whit the ethernet connection and not with the wireless connection
can anyone help mehttps://bbs.archlinux.org/viewtopic.php?id=118412
had the same problem, maybe it helps you. -
Having problems setting text to a JLabel!!
HI *.*,
i'm having problems setting text to a JLabel.
i have a JFrame with a JPanels and on the JPanel i have a JLabel.
I have a text field wihich is used to input text.
So, i'm using textField.getText() to read the text of the text field and setText() to write it to the Label.
but setText() isn't displaying the text on the label.
I'm using NetBeans as an ide
Does anyone have any ideas??Here is some code
public class AddClass extends JFrame implements ActionListener{
public AddClass() {
initComponents();
}//end of 1st constructor with initComp
//initComponents
private void initComponents() {
getContentPane().setLayout(new java.awt.GridLayout(3, 1));
setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
prodPanel.setLayout(new java.awt.GridLayout(1, 3));
prodPanel.setBackground(new java.awt.Color(255, 255, 255));
prodPanel.setBorder(javax.swing.BorderFactory.createTitledBorder(javax.swing.BorderFactory.createEtchedBorder(), "Production", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Arial", 1, 12)));
westPanel.setLayout(new java.awt.GridLayout(6, 0));
westPanel.setBackground(new java.awt.Color(255, 255, 255));
westPanel.add(westLab1);
westLab2.setBackground(new java.awt.Color(255, 255, 255));
westLab2.setFont(new java.awt.Font("Arial", 1, 36));
westLab2.setForeground(new java.awt.Color(0, 204, 0));
westLab2.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
westLab2.setIcon(new javax.swing.ImageIcon("C:\\icontexto-webdev-bullet-048x048.png"));
westLab2.setText("MQ 35");
westLab2.setHorizontalTextPosition(javax.swing.SwingConstants.LEFT);
westLab2.setIconTextGap(10);
westLab2.setInheritsPopupMenu(false);
westPanel.add(westLab2);
westPanel.add(westLab3);
westPanel.add(westLab4);
westPanel.add(westLab5);
prodPanel.add(westPanel);
setJMenuBar(menuBar);
setTitle("Broker Monitor");
this.setSize(700, 700);
BrokerWindowCloser brkWindowCloser = new BrokerWindowCloser();
this.addWindowListener(brkWindowCloser);
pack();
// setVisible(true);
}//end of initComponents
public AddClass(String st) {
initComponents();
westLab6.setVisible(true);
// System.out.println("in broker " + st);
westLab6.setText(st);
System.out.println(st);
westLab6.setBackground(new java.awt.Color(255, 255, 255));
westLab6.setFont(new java.awt.Font("Arial", 1, 36));
westLab6.setForeground(new java.awt.Color(0, 204, 0));
westLab6.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
westLab6.setIcon(new javax.swing.ImageIcon("C:\\PNG\\icontexto-webdev-bullet-048x048.png"));
westLab6.setEnabled(true);
westLab6.setHorizontalTextPosition(javax.swing.SwingConstants.LEFT);
westLab6.setIconTextGap(15);
westLab6.setInheritsPopupMenu(false);
westPanel.add(westLab6);
// this.validate();
westPanel.repaint();
public void actionPerformed(ActionEvent ae) {
Object source = ae.getSource();
if(source == exitMI) {
System.exit(0);
}//end of if exitMI
if(source == addMI){
new AddMQ_1_1();
if(source == removeMI){
new RemoveMQ_1();
}//end of actionPerformed
class BrokerWindowCloser extends WindowAdapter {
public void windowClosing(WindowEvent we) {
}//end of windowcloserclass
public static void main(String args[]) {
java.awt.EventQueue.invokeLater(new Runnable() {
public void run() {
new AddClass().setVisible(true);
}//end of main
}// End of variables declaration
public void addButtonActionPerformed(java.awt.event.ActionEvent evt) {
// TODO add your handling code here:
Object source = evt.getSource();
if(source == addButton){
System.out.println("here");
String st = mqNameJTF.getText();
Broker1 br = new Broker1(st);
AddClass adc = new AddClass(st);
this.repaint();
this.dispose();
}//end of if addButton
}//end addButtonActionPerformed -
How to set static IP for Deskjet Ink Advantage 6525 printer ???
Hello,
I try to set static IP address,but when i put the IP address from network configuration page in the browser's address bar ,can't find anything.Hi,
Can you ping it ? It may not have anything in there for browsing.
Updated: Well actually I use my printer and it shows many things - left side:
Please refer to the following link:
http://h30434.www3.hp.com/t5/Printer-All-in-One-Install-Setup-e-g-Windows-8/HP-Photosmart-6525-reboo...
Regards.
BH
**Click the KUDOS thumb up on the left to say 'Thanks'**
Make it easier for other people to find solutions by marking a Reply 'Accept as Solution' if it solves your problem. -
Problem setting JComboBox background in Nimbus
I am having a problem setting the background component of a JComboBox when using the Nimbus L&F. The call to JComboBox.setBackground() changes the background of both the content area and the button. I do not want the background color of the button to be changed. I reviewed a number of similar posts in the forums and found a suggested change that results in the button keeping its original background. The code for the suggested change is shown below:
JComboBox bandComboBox;
bandComboBox.setBackground(Color.YELLOW);
// This next line of code changes the background color of the button back to its original value
bandComboBox.getComponent(0).setBackground(UIManager.getColor("control"));
This change did not work for the Nimbus L&F but it did work for the Metal L&F. I really need a solution for the Nimbus L&F. Any suggestions would be greatly appreciated.
I am currently running java 1.6_u13.
Thanks!
CaseyExcept for the actual arrow, the combo box arrow button doesn't paint anything in Nimbus. The highlight, the border, and the gradient background of the arrow button are drawn by the combo box painter. Hence, when you set the background color on the combo box, it also affects the look of the arrow button.
So I thought, what if I made the arrow button opaque? Well.. it does become its own color, but it essentially becomes a giant solid-color square appended to the end of the combo box. Not exactly what we were looking for.
So then I thought that maybe we could use the "Nimbus.Overrides" feature to override the colors on the combo box. Turns out you can't do that. The feature doesn't apply to colors. To change the base colors, you would have to go through the UIManager, and in effect change colors for all the components. Plus, the JComboBox uses colors derived from the same core color - "nimbusBase" - to paint the background of the combo box and the arrow button. So if you change "nimbusBase" to yellow then the whole combo box is still effected (although the results admittedly look better then setBackground(Color.yellow) since the gradient effects are retained).
Anyway, after fiddling around with some ideas, this is what I came up with.
import javax.swing.*;
import javax.swing.UIManager.LookAndFeelInfo;
import java.awt.Color;
import java.awt.Graphics;
public class Test {
public static void main(String[] args) throws Exception {
SwingUtilities.invokeLater(new Runnable() {
public void run() {
createAndShowGUI();
public static void createAndShowGUI(){
try {
for (LookAndFeelInfo laf : UIManager.getInstalledLookAndFeels()) {
if ("Nimbus".equals(laf.getName())) {
UIManager.setLookAndFeel(laf.getClassName());
} catch (Exception e) {
e.printStackTrace();
}finally {
if(!("Nimbus".equals(UIManager.getLookAndFeel().getName()))) {
System.err.println("Could not find/install Nimbus LAF!");
System.exit(-1);
SpecialNimbusComboBox specialBox = new SpecialNimbusComboBox(new String[] {
"One","Two","Three"
specialBox.boxColor ; = Color.yellow;
specialBox.arrowBoxColor = Color.red;
JComboBox regularBox = new JComboBox(new String[] {
"One","Two","Three"
JFrame frame = new JFrame();
frame.setLayout(new java.awt.FlowLayout());
frame.add(specialBox);
frame.add(regularBox);
frame.setSize(250,150);
frame.setLocationRelativeTo(null);
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
frame.setVisible(true);
public static class SpecialNimbusComboBox extends JComboBox{
public Color boxColor;
public Color arrowBoxColor;
private boolean ignoreRepaint;
public SpecialNimbusComboBox() {}
public SpecialNimbusComboBox(ComboBoxModel aModel) {super(aModel);}
public SpecialNimbusComboBox(Object[] items) {super(items);}
@Override
public void paintComponent(Graphics g) {
ignoreRepaint = true;
try {
java.awt.Rectangle b = getComponent(0).getBounds();
g.setClip(0, 0, getWidth() - b.width, getHeight());
setBackground(boxColor);
super.paintComponent(g);
g.setClip(b.x, b.y, b.width, b.height);
setBackground(arrowBoxColor);
super.paintComponent(g);
} finally {
ignoreRepaint = false;
@Override
public void repaint() {
if(!ignoreRepaint)
super.repaint();
} -
Problems setting up an NFS server
Hi everybody,
I just completed my first arch install. :-)
I have a desktop and a laptop, and I installed Arch on the desktop (the laptop runs Ubuntu 9.10). I had a few difficulties here and there, but I now have the system up and running, and I'm very happy.
I have a problem setting up an NFS server. With Ubuntu everything was working, so I'm assuming that the Ubuntu machine (client) is set-up correctly. I'm trying to troubleshoot the arch box (server) now.
I followed this wiki article: http://wiki.archlinux.org/index.php/Nfs
Now, I have these problems:
- when I start the daemons, I get:
[root@myhost ~]# /etc/rc.d/rpcbind start
:: Starting rpcbind [FAIL]
[root@myhost ~]# /etc/rc.d/nfs-common start
:: Starting rpc.statd daemon [FAIL]
[root@myhost ~]# /etc/rc.d/nfs-server start
:: Mounting nfsd filesystem [DONE]
:: Exporting all directories [BUSY] exportfs: /etc/exports [3]: Neither 'subtree_check' or 'no_subtree_check' specified for export "192.168.1.1/24:/home".
Assuming default behaviour ('no_subtree_check').
NOTE: this default has changed since nfs-utils version 1.0.x
[DONE]
:: Starting rpc.nfsd daemon [FAIL]
- If I mount the share on the client with "sudo mount 192.168.1.20:/home /media/desktop", IT IS mounted but I can't browse it because I have no privileges to access the home directory for the user.
my /etc/exports looks like this:
# /etc/exports: the access control list for filesystems which may be exported
# to NFS clients. See exports(5).
/home 192.168.1.1/24(rw,sync,all_squash,anonuid=99,anongid=99))
/etc/conf.d/nfs-common.conf:
# Parameters to be passed to nfs-common (nfs clients & server) init script.
# If you do not set values for the NEED_ options, they will be attempted
# autodetected; this should be sufficient for most people. Valid alternatives
# for the NEED_ options are "yes" and "no".
# Do you want to start the statd daemon? It is not needed for NFSv4.
NEED_STATD=
# Options to pass to rpc.statd.
# See rpc.statd(8) for more details.
# N.B. statd normally runs on both client and server, and run-time
# options should be specified accordingly. Specifically, the Arch
# NFS init scripts require the --no-notify flag on the server,
# but not on the client e.g.
# STATD_OPTS="--no-notify -p 32765 -o 32766" -> server
# STATD_OPTS="-p 32765 -o 32766" -> client
STATD_OPTS="--no-notify"
# Options to pass to sm-notify
# e.g. SMNOTIFY_OPTS="-p 32764"
SMNOTIFY_OPTS=""
# Do you want to start the idmapd daemon? It is only needed for NFSv4.
NEED_IDMAPD=
# Options to pass to rpc.idmapd.
# See rpc.idmapd(8) for more details.
IDMAPD_OPTS=
# Do you want to start the gssd daemon? It is required for Kerberos mounts.
NEED_GSSD=
# Options to pass to rpc.gssd.
# See rpc.gssd(8) for more details.
GSSD_OPTS=
# Where to mount rpc_pipefs filesystem; the default is "/var/lib/nfs/rpc_pipefs".
PIPEFS_MOUNTPOINT=
# Options used to mount rpc_pipefs filesystem; the default is "defaults".
PIPEFS_MOUNTOPTS=
/etc/hosts.allow:
nfsd: 192.168.1.0/255.255.255.0
rpcbind: 192.168.1.0/255.255.255.0
mountd: 192.168.1.0/255.255.255.0
Any help would be very appreciated!Thanks, I finally got it working.
I realized that even though both machines had the same group, my Ubuntu machine (client) group has GID 1000, while the Arch one has GID 1001. I created a group that has GID 1001 on the client, and now everything is working.
I'm wondering why my Arch username and group both have 1001 rather than 1000 (which I suppose would be the default number for the first user created).
Anyway, thanks again for your inputs. -
Problems Setting Up Developer Users
I am having a problem setting up developer users and I am trying to determine if I am missing a step or if there is a configuration problem on my staging and production systems.
What I want to do should be very simple. I want to create a user that can create an application and see the information under the "Application" tab in the Navigator.
I have created the user using the following steps on 3.0.9.82 for Unix:
1. Create the user
2. Make the user a full administrator (rather than end user)
3. Make the user a member of the portal_developers group
4. Make the user's default group the portal_developers group
However, when I do this the user does not see the information under the
"Application" tab. The only way I can get the user to see the info under the
"Application" tab is to make him a member of the Portal_administrators
and/or DBA group. Both my staging and production boxes have the same result.
Does anyone have any thoughts or suggestions on what might be happening?Thank you- I have read through that thread and can see some resonance with my issue.
My AOL emails work VERY fast with BB, in fact almost simultaneously received on PC & Torch " ping ping!"
This issue only raised its ugly head when I had 2 Torches replaced by my insurers.
Whilst the claim was in process I used a new Curve, loaded from backup on PC to keep emails going and of course phone & web facilities. ( I use the BB to power internet via bluetooth to my PC / laptop when living on a remote island with no phone lines or power supplies) All was fine. Swapping email accounts took a few minutes with the usual password confirmations for each AOL screenname etc.
Then the new Torches came back from insurers, and I tried to swap devices. Phoning & texting is fine. Al data and contacts swap over fine.
SETUP email accounts.............stymied every time. It says repeatedly that my user name/password is invalid etc etc etc
Have tried security wipes. Have tried setting up new BB ID & passwords on PC website. All is OK until I try to setup emails on the Torches. This has used up ridiculous amounts of time- all wasted.
I love the BB phones and the fast email push......in fact I recently bought a new Sony Xperia Z1 but sent it back because of wifi coverage meant no emails on that superb phone for lots of the time.
Good old BB I said..........I always get emails wherever I am. ( Rural Scotland has very patchy radio & wifi coverage)
Was about to purchase new Z10s just to get a bigger screen, but now I am averse to buying ANY BB phone again because this present mess means I may never get emails set up again. How nuts is that?
Many thanks for all help & suggestions..........boy do I need them!!
Kind wishes from West of Scotland
Fair winds and kind landfalls -
Problems setting up VVSA 6.0 (lookup service adresse)
Hi,
I was happy to see VVSA 6.0 released, but i'm having problems setting it up. It keeps saying that the lookup service adresse is not reachable. But I have tried with the VVSA 5.5 and 5.5.1.1 and they work just fine with the lookup service adresse.
Anyone else having this issue?
Also trying to check for updates within the appliance failes since the repository is not online at vmware it seems.
Might not be ready for primetime (like ESXi6).If Developer has a separate Oracle Home on your PC, then it has a separate TNSNAMES.ORA file that is uses to connect to the database. If you search for all tnsnames.ora files, you should find the one used by Developer 6.
Since Enterprise manager works, the tnsnames.ora in your Enterprise Manager's home will have an entry for your server database. You should be able to cut and paste this into the tnsnames.ora file used by Developer, or try copying the E.M. tnsnames.ora file directly.
John Alexander www.SummitSoftwareDesign.com -
I recently downloaded mysql Connector for my project.
However, I have problems setting it up.
When I run my program, It gives me a class not defined error.
System.out.println("Registering Driver...");
Class.forName("com.mysql.jdbc.Driver").newInstance();
System.out.println("Connected to database");
System.out.println("Creating Connection");
connection= DriverManager.getConnection("jdbc:mysql://localhost:8080/neuis");
System.out.println("Connection created");
catch(Exception ex)
System.out.println("Error in loading jdbc Driver: "+ex);
ex.printStackTrace();
I have put the jar file of the JDBC Bridge in a folder
C:\Drivers\Sql Connector
I have also added the absolute path of the jar to the system classpath
The value put in is:
C:\Drivers\Sql Connector\mysql-connector-java-3.1.10-bin.jar.
I am not sure what the problem is because I was told by the API that this was all I needed to do. Are there any other files I need to include with the jar file? Also, Is there a specific folder I must put it in?
Thank you in advance.Hi,
Take a look at the below link
http://www.cs.nott.ac.uk/TSG/manuals/databases/mysql/jdbc.html
may help you to setting up the jdbc with mysql
regards
MJ -
Problems setting up email account
Have recently got a blackberry 9300 and having problems setting up my aol email account.
Do not know how to fix this problem, can anyone please give advice?Hi and Welcome to the Forums!
Well, a bit more detail than "having problems" might help us just a bit...keep us from guessing, after all. In the meantime, see this:
http://us.blackberry.com/support/blackberry101/setup.jsp#tab_tab_email
Good luck and let us know!
Occam's Razor nearly always applies when troubleshooting technology issues!
If anyone has been helpful to you, please show your appreciation by clicking the button inside of their post. Please click here and read, along with the threads to which it links, for helpful information to guide you as you proceed. I always recommend that you treat your BlackBerry like any other computing device, including using a regular backup schedule...click here for an article with instructions.
Join our BBM Channels
BSCF General Channel
PIN: C0001B7B4 Display/Scan Bar Code
Knowledge Base Updates
PIN: C0005A9AA Display/Scan Bar Code -
Problems Setting up my wireless network with an Xb...
Hi, I have had some problems setting up my wireless networking.
I have everything switched on and am able to go online with the laptop and the Xbox with no problems but when I try to share media with the xbox I have problems.
I have opened the ports specified in the setup from xbox on windows firewall and have no problem connection Via Ethernet cable but when using wireless the xbox cannot detect the laptop.
I have checked the network map and both xbox and laptop are connected and have enabled sharing and am running sharing software.
Below is the network map.
I have also been having problems with BT software, the free virus protection will not install, The desktop help will not launch although it shows up on task manager and the installation disk does not launch correctly it doesn't get past the loading screen.
I have had a printer on the wireless network and had no problems printing.
If anyone knows how to resolve this please help.I have this same Motorola modem and I just verified that my 802.11n AirPort Express Base Station (AXn) can get Internet access with this modem without any issues.
When changing ISPs (or networking equipment) it's always a good idea to start from "scratch" in configuring your equipment.
I would recommend that you do the following as a minimum:
Power-down the modem, AirPort base station, and computer(s).
While all of the devices are powered-down, perform a "factory default" reset on the base station. This will get it back to its "out-of-the-box" configuration and make setting it up much easier, especially if you use the "Assist me" process within the AirPort Utility. (ref: Resetting an AirPort Base Station or Time Capsule)
After the base station resets, go ahead and power it back down.
Power-up the modem; wait at least 10-15 minutes.
Power-up the base station; wait at least 5-10 minutes.
Power-up your computer(s).
In this basic configuration, computers connected to the base station, either by wire or wireless (as appropriate for the base station type), should now be able to access the Internet through the ISP's modem. Once Internet connectivity has been verified, you can use the AirPort Utility to configure the base station for wireless security and any other desired options.
Maybe you are looking for
-
Remote TC access via port forwarding
I have been trying to setup my network for remote TC access via port forwarding. Here's my setup: Verizon FiOS router (main router, dhcp & nat) -> connected to TC set in bridge mode with a static IP I can remotely access the TC using Back to my Mac w
-
Etrecheck report - please advise
Can you please let me know how to fix the items in red? thanks! EtreCheck version: 2.1.8 (121) Report generated 9 April 2015 9:45:34 pm GMT+2 Download EtreCheck from http://etresoft.com/etrecheck Click the [Click for support] links for help with non-
-
I just got this error while upgrading the kernel after a fresh-install: error: could not prepare transaction error: failed to commit transaction (confliting files) kernel26: /lib/modules/2.6.23-ARCH/modules.alias exists in filesystem kernel26: /lib/m
-
How do I remove photos synced from computer
How do I remove photo albums synced from computer without losing them on the computer
-
Email phishing, malware, trojan horses, key stroke
I have a iMac with the new Yosemite 10.10.1 SW installed. I received an email and clicked on a web link that was characterised as Phishing and I enterred private information. I have since truned off all online contacts that may be compromised. What i