Here you can find the source of setValue(JTextField f, String value)
Parameter | Description |
---|---|
f | - the field to update |
value | a parameter |
public static void setValue(JTextField f, String value)
//package com.java2s; //License from project: Open Source License import javax.swing.JTextField; public class Main { /**// ww w .j ava2 s . c om * For a JTextField, sets the value, validates, and repaints * @param f - the field to update * @param value */ public static void setValue(JTextField f, String value) { f.setText(value); f.validate(); f.repaint(); } }