khaja mohideen

Greenhorn
+ Follow
since May 20, 2011
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
In last 30 days
0
Forums and Threads

Recent posts by khaja mohideen

Hi,
Really thankful for your reply,but i have a code like this

<HTML>
<HEAD>
<TITLE>
Login</TITLE>
<script>
<!--
function login() {
document.form.action="www.example.com";
document.form.submit();


}
//-->
</script>
</HEAD>
<BODY onLoad="login()">
<FORM NAME="form" METHOD="post">
<input type="hidden" id="login" name="loginname" value="abc" />
<input " type="hidden" id="password" name="passwordfield" value="abc"/>
<INPUT TYPE="hidden" VALUE="enter" />
</FORM>
</BODY>
</HTML>

it goes to example.com but not fill the username and password field of example.com.

any clues
thank you
Thank you for your reply ,
I use the post method to submit and pass the username and password in hidden boxes
,but it doesn't receive and put it in the texbox fields of navigate page.

the username and password feilds of navigate page is null

thankyou
Hi all,

I am really thankful if anyone guide me.

I have a link when i press the link it goes to a website and automatically fll the username password fields and automatically submit the button and move to logged page of that website

i use windows.navigate function,but i don't know how to take the id of username and password fields of navigate page.

Thank you all.
Hi



// this is done in constructor
fsPanel = new JPanel();
//fsPanel.setLayout(new BorderLayout());
fsPanel.setLayout(new BoxLayout(fsPanel, BoxLayout.PAGE_AXIS));
fsPanel.add(filterPanel,"North");
fsPanel.add(timePanel);
fsPanel.add(searchPanel,"South");
---------------------------------------------------------

public void setPanelEnabled(boolean enabled){
for(int i = 0; i < fsPanel.getComponentCount(); i++){
JPanel compPanel = (JPanel) fsPanel.getComponent(i);
for(int j = 0; j < compPanel.getComponentCount(); j++){
compPanel.getComponent(j).setEnabled(enabled);
}
}
}




i write a method setPanelEnabled to enable/disable components of the panel ( which are checkboxes,comboboxes)

this method was causing the problem , i think there is something not clean in this code
as i am new to java , your insight will help me.

but any way thankyou for the replies which helped me to track the problem is short time.

Regards
13 years ago
Hi

thank you for the replies , i am now analysing on basis of what you have suggested

just to add , this exception seems to occur only in some cases where i read a text file and update JTable( which is done inside a thread) inside the frame

after which . on resizing the mainframe , the jtable does not resize

regards
13 years ago
Hi

On reszie of jframe i.e. my masterframe , throws the following exception and main components ( jtable inside the jframe ) does not resize anymore and
i get the following messages. Please give me clue , to look for a solution

Exception in thread "AWT-EventQueue-0" java.lang.ArrayIndexOutOfBoundsException: 0 >= 0
at java.util.Vector.elementAt(Unknown Source)
at javax.swing.DefaultComboBoxModel.getElementAt(Unknown Source)
at javax.swing.plaf.basic.BasicComboBoxUI.getDisplaySize(Unknown Source)
at javax.swing.plaf.metal.MetalComboBoxUI.getMinimumSize(Unknown Source)
at javax.swing.JComponent.getMinimumSize(Unknown Source)
at java.awt.FlowLayout.minimumLayoutSize(Unknown Source)
at java.awt.Container.minimumSize(Unknown Source)
at java.awt.Container.getMinimumSize(Unknown Source)
at javax.swing.JComponent.getMinimumSize(Unknown Source)
at javax.swing.BoxLayout.checkRequests(Unknown Source)
at javax.swing.BoxLayout.preferredLayoutSize(Unknown Source)
at java.awt.Container.preferredSize(Unknown Source)
at java.awt.Container.getPreferredSize(Unknown Source)
at javax.swing.JComponent.getPreferredSize(Unknown Source)
at java.awt.BorderLayout.preferredLayoutSize(Unknown Source)
at java.awt.Container.preferredSize(Unknown Source)
at java.awt.Container.getPreferredSize(Unknown Source)
at javax.swing.JComponent.getPreferredSize(Unknown Source)
at java.awt.BorderLayout.layoutContainer(Unknown Source)
at java.awt.Container.layout(Unknown Source)
at java.awt.Container.doLayout(Unknown Source)
at java.awt.Container.validateTree(Unknown Source)
at java.awt.Container.validateTree(Unknown Source)
at java.awt.Container.validateTree(Unknown Source)
at java.awt.Container.validate(Unknown Source)
at javax.swing.RepaintManager.validateInvalidComponents(Unknown Source)
at javax.swing.SystemEventQueueUtilities$ComponentWorkRequest.run(Unknown Source)
at java.awt.event.InvocationEvent.dispatch(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)
Exception in thread "AWT-EventQueue-0" Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException
at javax.swing.BoxLayout.preferredLayoutSize(Unknown Source)
at java.awt.Container.preferredSize(Unknown Source)
at java.awt.Container.getPreferredSize(Unknown Source)
at javax.swing.JComponent.getPreferredSize(Unknown Source)
at java.awt.BorderLayout.preferredLayoutSize(Unknown Source)
at java.awt.Container.preferredSize(Unknown Source)
at java.awt.Container.getPreferredSize(Unknown Source)
at javax.swing.JComponent.getPreferredSize(Unknown Source)
at java.awt.BorderLayout.layoutContainer(Unknown Source)
at java.awt.Container.layout(Unknown Source)
at java.awt.Container.doLayout(Unknown Source)
at java.awt.Container.validateTree(Unknown Source)
at java.awt.Container.validateTree(Unknown Source)
at java.awt.Container.validateTree(Unknown Source)
at java.awt.Container.validate(Unknown Source)
at javax.swing.RepaintManager.validateInvalidComponents(Unknown Source)
at javax.swing.SystemEventQueueUtilities$ComponentWorkRequest.run(Unknown Source)
at java.awt.event.InvocationEvent.dispatch(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)
Regards
kmm
13 years ago

Rob Spoor wrote:We first need to know what key code that button is:
Once you know that you can use it in a key stroke; check how key binding works in Java.

As for the actual copying, JTextArea inherits method copy() from JTextComponent. All you need to do is call that.



JTextArea --> copy() , does not work in Solaris !!!
13 years ago
Hi

thankyou for your reply

KeyStroke ksF12 = KeyStroke.getKeyStroke("F12");
displayArea.getInputMap().put(ksF12, "copy");

KeyStroke ksF11 = KeyStroke.getKeyStroke("F11");
displayArea.getInputMap().put(ksF11, "paste");

the code above works for windows
what is the equivalent of "copy" , "paste" in Sun Solaris , how can i find it ?

although for Sun Solaris , i found the following with xev
keycode 131 = F16 F16 SunCopy
keycode 132 = F18 F18 SunPaste

Regards
13 years ago
hi

is there a way to map the keys in java i..e

if the user presses "Copy" button in sun keyboard , is it possible to translate it to "Ctrl+c" within java application

i know i can create a key listener , but after i get the Copy key , how do i map to "Ctrl+c"

or may be i can say

JTextArea area;
area.getselectedtext

and then where should i put this text in order for this text to be available for writing into say for ex. texteditor ?

regards
13 years ago
Hi

In ay java application , where i want to copy a text , with "Copy" special button in sun solariskeyboard , it does not work

but ctrl+c is working , any ideas ?

I use JTextArea in my application

Regards
kmm
13 years ago
hi
thank you for your reply

yes i thought about it , but was not sure since i am new to j2ee domain

the websites says its php-mysql based

and it does not say anything about jsp ,

i did not know that domains are either php OR jsp based

does that mean , there are also domains which are ONLY asp based ?

regards
13 years ago
JSP
hi
i programmed a basic jsp page ( learning... )

and loaded it to my webserver ( one.com ) i have a domain name registered here

but it does not show anything

any suggestions

locallly it works when i run the webserver e.g. tomcat

regards
kmm
13 years ago
JSP