How can i fill color Recent panel of colorchooser

hi all,
i want to set a color for recent panel of color chooser,
if i set color for the color chooser
colorChooser.setColor(Color.Red)it set color for the preview panel that's it, i want to fill in recent panel also,
any suggestion?
thanks
daya

It looks like it's hard to do easily, because DefaultSwatchChooserPanel (used by JColorChooser) is a private class.
So I copied its code into MyChooserPanel and modified it a little bit, now ColorChooser class has additional method
setRecentColors(Color[] c);
I deleted all Sun comments to make it shorter (probably you need to leave them if you want to use the class legally, I'm not sure).
This is a fast and ugly solution :(
also setRecentColors() should be called by Swing dispatcher thread
import java.awt.*;
import java.awt.event.*;
import java.io.*;
import javax.accessibility.*;
import javax.swing.*;
import javax.swing.border.*;
import javax.swing.colorchooser.*;
public class ColorChooser extends JColorChooser {
     private MyChooserPanel mp;
     public static void main(String[] args) {
          SwingUtilities.invokeLater(
               new Runnable(){
                    public void run() {
                         JFrame myFrame = new JFrame("ooo");
                         myFrame.setLayout(new FlowLayout());
                         final ColorChooser cc = new ColorChooser();
                         myFrame.add(cc);
                         JButton b = new JButton("Color");
                         myFrame.add(b);
                         b.addActionListener(new ActionListener(){
                                   public void actionPerformed(ActionEvent e) {
                                        cc.setRecentColors(new Color[]{Color.GREEN,Color.RED,Color.BLUE});
                         myFrame.pack();
                         myFrame.setSize(new Dimension(500, 420));
                         myFrame.setVisible(true);
                         myFrame.setLocationRelativeTo(null);
     public ColorChooser(){
          super();
          AbstractColorChooserPanel[] p=getChooserPanels();
          //remove all Panels
          for (AbstractColorChooserPanel e : p) {
               removeChooserPanel(e);
          //add panels back
          for (AbstractColorChooserPanel e : p) {
               if(e.getClass().toString().contains("DefaultSwatchChooserPanel")){
                    mp = new MyChooserPanel(); //if this is swatch panel, substitute it
                    addChooserPanel(mp);
               else
                    addChooserPanel(e);
     public void setRecentColors(Color[] cols){
          mp.setRecentColors(cols);
//Copy of standard DefaultSwatchChooserPanel
// with minor changes: added setRecentColors()
//modified RecentSwatchPanel: added setColors()
     class MyChooserPanel extends AbstractColorChooserPanel {
          SwatchPanel swatchPanel;
          RecentSwatchPanel recentSwatchPanel;
          MouseListener mainSwatchListener;
          MouseListener recentSwatchListener;
          private String recentStr = UIManager.getString("ColorChooser.swatchesRecentText");
          public MyChooserPanel() {
               super();
               setInheritsPopupMenu(true);
          public String getDisplayName() {
               return UIManager.getString("ColorChooser.swatchesNameText");
          public int getMnemonic() {
               return getInt("ColorChooser.swatchesMnemonic", -1);
          int getInt(Object key, int defaultValue) {
               Object value = UIManager.get(key);
               if (value instanceof Integer) {
                    return ((Integer)value).intValue();
               if (value instanceof String) {
                    try {
                         return Integer.parseInt((String)value);
                    catch (NumberFormatException nfe) {}
               return defaultValue;
          public int getDisplayedMnemonicIndex() {
               return getInt("ColorChooser.swatchesDisplayedMnemonicIndex", -1);
          public Icon getSmallDisplayIcon() {
               return null;
          public Icon getLargeDisplayIcon() {
               return null;
          public void installChooserPanel(JColorChooser enclosingChooser) {
               super.installChooserPanel(enclosingChooser);
          protected void buildChooser() {
               GridBagLayout gb = new GridBagLayout();
               GridBagConstraints gbc = new GridBagConstraints();
               JPanel superHolder = new JPanel(gb);
               swatchPanel =  new MainSwatchPanel();
               swatchPanel.putClientProperty(AccessibleContext.ACCESSIBLE_NAME_PROPERTY,
                                                    getDisplayName());
               swatchPanel.setInheritsPopupMenu(true);
               recentSwatchPanel = new RecentSwatchPanel();
               recentSwatchPanel.putClientProperty(AccessibleContext.ACCESSIBLE_NAME_PROPERTY,
                                                            recentStr);
               mainSwatchListener = new MainSwatchListener();
               swatchPanel.addMouseListener(mainSwatchListener);
               recentSwatchListener = new RecentSwatchListener();
               recentSwatchPanel.addMouseListener(recentSwatchListener);
               JPanel mainHolder = new JPanel(new BorderLayout());
               Border border = new CompoundBorder(new LineBorder(Color.black),
                                                          new LineBorder(Color.white));
               mainHolder.setBorder(border);
               mainHolder.add(swatchPanel, BorderLayout.CENTER);
               gbc.anchor = GridBagConstraints.LAST_LINE_START;
               gbc.gridwidth = 1;
               gbc.gridheight = 2;
               Insets oldInsets = gbc.insets;
               gbc.insets = new Insets(0, 0, 0, 10);
               superHolder.add(mainHolder, gbc);
               gbc.insets = oldInsets;
               recentSwatchPanel.addMouseListener(recentSwatchListener);
               recentSwatchPanel.setInheritsPopupMenu(true);
               JPanel recentHolder = new JPanel(new BorderLayout());
               recentHolder.setBorder(border);
               recentHolder.setInheritsPopupMenu(true);
               recentHolder.add(recentSwatchPanel, BorderLayout.CENTER);
               JLabel l = new JLabel(recentStr);
               l.setLabelFor(recentSwatchPanel);
               gbc.gridwidth = GridBagConstraints.REMAINDER;
               gbc.gridheight = 1;
               gbc.weighty = 1.0;
               superHolder.add(l, gbc);
               gbc.weighty = 0;
               gbc.gridheight = GridBagConstraints.REMAINDER;
               gbc.insets = new Insets(0, 0, 0, 2);
               superHolder.add(recentHolder, gbc);
               superHolder.setInheritsPopupMenu(true);
               add(superHolder);
          public void uninstallChooserPanel(JColorChooser enclosingChooser) {
               super.uninstallChooserPanel(enclosingChooser);
               swatchPanel.removeMouseListener(mainSwatchListener);
               recentSwatchPanel.removeMouseListener(recentSwatchListener);
               swatchPanel = null;
               recentSwatchPanel = null;
               mainSwatchListener = null;
               recentSwatchListener = null;
               removeAll();  // strip out all the sub-components
          public void updateChooser() {
          class RecentSwatchListener extends MouseAdapter implements Serializable {
               public void mousePressed(MouseEvent e) {
                    Color color = recentSwatchPanel.getColorForLocation(e.getX(), e.getY());
                    getColorSelectionModel().setSelectedColor(color);
          class MainSwatchListener extends MouseAdapter implements Serializable {
               public void mousePressed(MouseEvent e) {
                    Color color = swatchPanel.getColorForLocation(e.getX(), e.getY());
                    getColorSelectionModel().setSelectedColor(color);
                    recentSwatchPanel.setMostRecentColor(color);
          public void setRecentColors(Color[] cols) {
               recentSwatchPanel.setColors(cols);
     class SwatchPanel extends JPanel {
          protected Color[] colors;
          protected Dimension swatchSize;
          protected Dimension numSwatches;
          protected Dimension gap;
          public SwatchPanel() {
               initValues();
               initColors();
               setToolTipText(""); // register for events
               setOpaque(true);
               setBackground(Color.white);
               setRequestFocusEnabled(false);
               setInheritsPopupMenu(true);
          public boolean isFocusTraversable() {
               return false;
          protected void initValues() {
          public void paintComponent(Graphics g) {
               g.setColor(getBackground());
               g.fillRect(0, 0, getWidth(), getHeight());
               for (int row = 0; row < numSwatches.height; row++) {
                    int y = row * (swatchSize.height + gap.height);
                    for (int column = 0; column < numSwatches.width; column++) {
                         g.setColor(getColorForCell(column, row));
                         int x;
                         if ((!this.getComponentOrientation().isLeftToRight()) &&
                              (this instanceof RecentSwatchPanel)) {
                              x = (numSwatches.width - column - 1) * (swatchSize.width + gap.width);
                         else {
                              x = column * (swatchSize.width + gap.width);
                         g.fillRect(x, y, swatchSize.width, swatchSize.height);
                         g.setColor(Color.black);
                         g.drawLine(x + swatchSize.width - 1, y, x + swatchSize.width - 1, y + swatchSize.height - 1);
                         g.drawLine(x, y + swatchSize.height - 1, x + swatchSize.width - 1, y + swatchSize.height - 1);
          public Dimension getPreferredSize() {
               int x = numSwatches.width * (swatchSize.width + gap.width) - 1;
               int y = numSwatches.height * (swatchSize.height + gap.height) - 1;
               return new Dimension(x, y);
          protected void initColors() {
          public String getToolTipText(MouseEvent e) {
               Color color = getColorForLocation(e.getX(), e.getY());
               return color.getRed() + ", " + color.getGreen() + ", " + color.getBlue();
          public Color getColorForLocation(int x, int y) {
               int column;
               if ((!this.getComponentOrientation().isLeftToRight()) &&
                    (this instanceof RecentSwatchPanel)) {
                    column = numSwatches.width - x / (swatchSize.width + gap.width) - 1;
               else {
                    column = x / (swatchSize.width + gap.width);
               int row = y / (swatchSize.height + gap.height);
               return getColorForCell(column, row);
          private Color getColorForCell(int column, int row) {
               return colors[(row * numSwatches.width) + column]; // (STEVE) - change data orientation here
     class RecentSwatchPanel extends SwatchPanel {
          protected void initValues() {
               swatchSize = UIManager.getDimension("ColorChooser.swatchesRecentSwatchSize");
               numSwatches = new Dimension(5, 7);
               gap = new Dimension(1, 1);
          public void setColors(Color[] cols) {
               Color defaultRecentColor = UIManager.getColor("ColorChooser.swatchesDefaultRecentColor");
               int numColors = numSwatches.width * numSwatches.height;
               colors = new Color[numColors];
               for (int i = 0; i < numColors ; i++) {
                    Color c;
                    if (i < cols.length)
                         c = cols;
                    else
                         c = defaultRecentColor;
                    colors[i] = c;
               repaint();
          protected void initColors() {
               Color defaultRecentColor = UIManager.getColor("ColorChooser.swatchesDefaultRecentColor");
               int numColors = numSwatches.width * numSwatches.height;
               colors = new Color[numColors];
               for (int i = 0; i < numColors ; i++) {
                    colors[i] = defaultRecentColor;
          public void setMostRecentColor(Color c) {
               System.arraycopy(colors, 0, colors, 1, colors.length - 1);
               colors[0] = c;
               repaint();
     class MainSwatchPanel extends SwatchPanel {
          protected void initValues() {
               swatchSize = UIManager.getDimension("ColorChooser.swatchesSwatchSize");
               numSwatches = new Dimension(31, 9);
               gap = new Dimension(1, 1);
          protected void initColors() {
               int[] rawValues = initRawValues();
               int numColors = rawValues.length / 3;
               colors = new Color[numColors];
               for (int i = 0; i < numColors ; i++) {
                    colors[i] = new Color(rawValues[(i * 3)], rawValues[(i * 3) + 1], rawValues[(i * 3) + 2]);
          private int[] initRawValues() {
               int[] rawValues = {
                    255, 255, 255, // first row.
                    204, 255, 255,
                    204, 204, 255,
                    204, 204, 255,
                    204, 204, 255,
                    204, 204, 255,
                    204, 204, 255,
                    204, 204, 255,
                    204, 204, 255,
                    204, 204, 255,
                    204, 204, 255,
                    255, 204, 255,
                    255, 204, 204,
                    255, 204, 204,
                    255, 204, 204,
                    255, 204, 204,
                    255, 204, 204,
                    255, 204, 204,
                    255, 204, 204,
                    255, 204, 204,
                    255, 204, 204,
                    255, 255, 204,
                    204, 255, 204,
                    204, 255, 204,
                    204, 255, 204,
                    204, 255, 204,
                    204, 255, 204,
                    204, 255, 204,
                    204, 255, 204,
                    204, 255, 204,
                    204, 255, 204,
                    204, 204, 204, // second row.
                    153, 255, 255,
                    153, 204, 255,
                    153, 153, 255,
                    153, 153, 255,
                    153, 153, 255,
                    153, 153, 255,
                    153, 153, 255,
                    153, 153, 255,
                    153, 153, 255,
                    204, 153, 255,
                    255, 153, 255,
                    255, 153, 204,
                    255, 153, 153,
                    255, 153, 153,
                    255, 153, 153,
                    255, 153, 153,
                    255, 153, 153,
                    255, 153, 153,
                    255, 153, 153,
                    255, 204, 153,
                    255, 255, 153,
                    204, 255, 153,
                    153, 255, 153,
                    153, 255, 153,
                    153, 255, 153,
                    153, 255, 153,
                    153, 255, 153,
                    153, 255, 153,
                    153, 255, 153,
                    153, 255, 204,
                    204, 204, 204, // third row
                    102, 255, 255,
                    102, 204, 255,
                    102, 153, 255,
                    102, 102, 255,
                    102, 102, 255,
                    102, 102, 255,
                    102, 102, 255,
                    102, 102, 255,
                    153, 102, 255,
                    204, 102, 255,
                    255, 102, 255,
                    255, 102, 204,
                    255, 102, 153,
                    255, 102, 102,
                    255, 102, 102,
                    255, 102, 102,
                    255, 102, 102,
                    255, 102, 102,
                    255, 153, 102,
                    255, 204, 102,
                    255, 255, 102,
                    204, 255, 102,
                    153, 255, 102,
                    102, 255, 102,
                    102, 255, 102,
                    102, 255, 102,
                    102, 255, 102,
                    102, 255, 102,
                    102, 255, 153,
                    102, 255, 204,
                    153, 153, 153, // fourth row
                    51, 255, 255,
                    51, 204, 255,
                    51, 153, 255,
                    51, 102, 255,
                    51, 51, 255,
                    51, 51, 255,
                    51, 51, 255,
                    102, 51, 255,
                    153, 51, 255,
                    204, 51, 255,
                    255, 51, 255,
                    255, 51, 204,
                    255, 51, 153,
                    255, 51, 102,
                    255, 51, 51,
                    255, 51, 51,
                    255, 51, 51,
                    255, 102, 51,
                    255, 153, 51,
                    255, 204, 51,
                    255, 255, 51,
                    204, 255, 51,
                    153, 255, 51,
                    102, 255, 51,
                    51, 255, 51,
                    51, 255, 51,
                    51, 255, 51,
                    51, 255, 102,
                    51, 255, 153,
                    51, 255, 204,
                    153, 153, 153, // Fifth row
                    0, 255, 255,
                    0, 204, 255,
                    0, 153, 255,
                    0, 102, 255,
                    0, 51, 255,
                    0, 0, 255,
                    51, 0, 255,
                    102, 0, 255,
                    153, 0, 255,
                    204, 0, 255,
                    255, 0, 255,
                    255, 0, 204,
                    255, 0, 153,
                    255, 0, 102,
                    255, 0, 51,
                    255, 0 , 0,
                    255, 51, 0,
                    255, 102, 0,
                    255, 153, 0,
                    255, 204, 0,
                    255, 255, 0,
                    204, 255, 0,
                    153, 255, 0,
                    102, 255, 0,
                    51, 255, 0,
                    0, 255, 0,
                    0, 255, 51,
                    0, 255, 102,
                    0, 255, 153,
                    0, 255, 204,
                    102, 102, 102, // sixth row
                    0, 204, 204,
                    0, 204, 204,
                    0, 153, 204,
                    0, 102, 204,
                    0, 51, 204,
                    0, 0, 204,
                    51, 0, 204,
                    102, 0, 204,
                    153, 0, 204,
                    204, 0, 204,
                    204, 0, 204,
                    204, 0, 204,
                    204, 0, 153,
                    204, 0, 102,
                    204, 0, 51,
                    204, 0, 0,
                    204, 51, 0,
                    204, 102, 0,
                    204, 153, 0,
                    204, 204, 0,
                    204, 204, 0,
                    204, 204, 0,
                    153, 204, 0,
                    102, 204, 0,
                    51, 204, 0,
                    0, 204, 0,
                    0, 204, 51,
                    0, 204, 102,
                    0, 204, 153,
                    0, 204, 204,
                    102, 102, 102, // seventh row
                    0, 153, 153,
                    0, 153, 153,
                    0, 153, 153,
                    0, 102, 153,
                    0, 51, 153,
                    0, 0, 153,
                    51, 0, 153,
                    102, 0, 153,
                    153, 0, 153,
                    153, 0, 153,
                    153, 0, 153,
                    153, 0, 153,
                    153, 0, 153,
                    153, 0, 102,
                    153, 0, 51,
                    153, 0, 0,
                    153, 51, 0,
                    153, 102, 0,
                    153, 153, 0,
                    153, 153, 0,
                    153, 153, 0,
                    153, 153, 0,
                    153, 153, 0,
                    102, 153, 0,
                    51, 153, 0,
                    0, 153, 0,
                    0, 153, 51,
                    0, 153, 102,
                    0, 153, 153,
                    0, 153, 153,
                    51, 51, 51, // eigth row
                    0, 102, 102,
                    0, 102, 102,
                    0, 102, 102,
                    0, 102, 102,
                    0, 51, 102,
                    0, 0, 102,
                    51, 0, 102,
                    102, 0, 102,
                    102, 0, 102,
                    102, 0, 102,
                    102, 0, 102,
                    102, 0, 102,
                    102, 0, 102,
                    102, 0, 102,
                    102, 0, 51,
                    102, 0, 0,
                    102, 51, 0,
                    102, 102, 0,
                    102, 102, 0,
                    102, 102, 0,
                    102, 102, 0,
                    102, 102, 0,
                    102, 102, 0,
                    102, 102, 0,
                    51, 102, 0,
                    0, 102, 0,
                    0, 102, 51,
                    0, 102, 102,
                    0, 102, 102,
                    0, 102, 102,
                    0, 0, 0, // ninth row
                    0, 51, 51,
                    0, 51, 51,
                    0, 51, 51,
                    0, 51, 51,
                    0, 51, 51,
                    0, 0, 51,
                    51, 0, 51,
                    51, 0, 51,
                    51, 0, 51,
                    51, 0, 51,
                    51, 0, 51,
                    51, 0, 51,
                    51, 0, 51,
                    51, 0, 51,
                    51, 0, 51,
                    51, 0, 0,
                    51, 51, 0,
                    51, 51, 0,
                    51, 51, 0,
                    51, 51, 0,
                    51, 51, 0,
                    51, 51, 0,
                    51, 51, 0,
                    51, 51, 0,
                    0, 51, 0,
                    0, 51, 51,
                    0, 51, 51,
                    0, 51, 51,
                    0, 51, 51,
                    51, 51, 51 };
               return rawValues;

Similar Messages

  • Using Mac computer and InDesign CS6, version 8.0, how can I fill a box from swatches?

    Using Mac computer and InDesign CS6, version 8.0, how can I fill a box from swatches?

    Make sure the Fill color proxy (solid square, upper left corner of the swatches panel) is selected and in front, then choose a swatch.

  • How can I display the front panel of the dinamically loaded VI on the cliente computer, the VI dinamically loaded contains files, I want to see the files that the server machine has, in the client machine

    I can successfully view and control a VI remotly. However, the remote VI dinamically loads another VI, this VI loaded dinamically is a VI that allows open others VIs, I want to see the files that contains the server machine, in the client machine, but the front panel of the dinamic VI appears only on the server and not on the client, How can I display the fron panel with the files of the server machine of the dinamically loaded VI on the client computer?
    Attachments:
    micliente.llb ‏183 KB
    miservidor.llb ‏186 KB
    rdsubvis.llb ‏214 KB

    I down loaded your files but could use some instructions on what needs run.
    It seems that you are so close yet so far. You need to get the data on the server machine over to the client. I generally do this by doing a call by reference (on the client machine) of a VI that is served by the server. THe VI that executes on the server should pass the data you want to diplay via one of its output terminals. You can simply wire from this terminal (back on the client again) to an indicator of your choosing.
    Now theorectically, I do not think that there is anything that prevents use from getting the control refnum of the actual indicator (on the server) of the indicator that has the data, and read its "Value" using a property node. I have never tried this idea but it seems t
    hat all of the parts are there. You will need to know the name of the VI that holds the data as well as the indicator's name. You will also have to serve all VI's. This is not a good idea.
    Ben
    Ben Rayner
    I am currently active on.. MainStream Preppers
    Rayner's Ridge is under construction

  • How can I put my recently purchased iTunes movies on to my thumb drive and WD My Passport external hard drive. My Mac keeps saying "can't be copy because it is too large for the volumes format

    How can I put my recently purchased iTunes movies onto my thumb drive and WD my passport external hard drive.My Mac is saying that can't be copied because it is too large for volumes format

    [file] is too large for the volumes format
    That is usually an indication that the Volume was never Erased or Partitioned for GUID partition table and Mac OS, and is still in a Windows format.
    Mac OS X Extended (journaled) has no such file-size limitations

  • How can I delete the recent calls list in FaceTime?

    How can I delete the recent calls list in FaceTime of my Mac?

    Hello muchaim,
    After reviewing your post, it sounds like you want to delete the recent call list. I would recommend that you read this article, it may be able to help the issue.
    FaceTime for Mac (Yosemite): Make and receive FaceTime calls
    FaceTime keeps a list of the most recent calls you made, received, or declined, with the most recent call at the top. To return a call, click the Video button  or the Audio button . To remove a call, select it and press Delete.
    Thanks for using Apple Support Communities.
    Have a nice day,
    Mario

  • How can I turn off Recently Websites when opening new Safari window? After tapping on the two overlapping boxes on the bottom right of Safari, a new blank window appears with Favorites, but now in iOS 8, recently viewed websites are listed.

    How can I turn off Recently Visited Websites when opening new Safari window?
    After tapping on the two overlapping boxes on the bottom right of Safari, a new blank window appears with Favorites, but now in iOS 8, recently viewed websites are listed. How can I turn this function off? I do NOT want my new Safari windows to have history displayed of previous websites I visited. I only want my Favorites (on the top) to be displayed. Please help.
    Thank you for your time, patience, understanding, kindness, and concern.

    Thanks for replying, but that isn't the answer I am looking for.  Also, there is no + sign, UNLESS you do tap the overlapping boxes.
    Let me try to ask my question a little more clearly:
    When I tap the two overlapping boxes on the lower left (the option to Open New Windows), the new Window that appears will show your Bookmarked FAVORITES. But with my new iPhone 6, and the new iOS 8.0.2, when I tap the two boxes to open a New Window, my Bookmark Favorites show (as they always have and should), but below them, there is a dividing line underneath them, and it says Recently Viewed Websites, and has these websites available to tap.
    So my question is, HOW DO I TURN THESE OPTION OFF?
    *UPDATE  (10.13.14): Since I have asked this question, I no longer see these Recently Viewed Websites under my Bookmarked Favorites in my new Window tabs. So I hope that Apple fixed it, or somehow it was a mistake, or somehow I changed an Option on my iPhone 6 that stopped this for reoccurring.
    Thank you for your help bobseufert! I appreciate your concern, kindness, and the time to try to help. I am grateful.
    Have a blessed day.

  • How can I fill a table of objects from cursor with select * bulk collect???

    Hi All, I have a TYPE as OBJECT
    create or replace type dept2_o as object (
    deptno NUMBER(2),
    dname VARCHAR2(14),
    loc VARCHAR2(13));
    I can fill a table of objects from cursor with out select * bulk collect...., row by row
    declare
    TYPE dept2_t IS TABLE of dept2_o;
    dept_o_tab dept2_t:=dept2_t();
    i integer;
    begin
    i:=0;
    dept_o_tab.extend(20);
    for rec in (select * from dept) loop
    i:=i+1;
    dept_o_tab(i):=dept2_o(
    deptno => rec.deptno,
    dname => rec.dname,
    loc =>rec.loc
    end loop;
    for k IN 1..i loop
    dbms_output.put_line(dept_o_tab(k).deptno||' '||dept_o_tab(k).dname||' '||dept_o_tab(k).loc);
    end loop;
    end;
    RESULT
    10 ACCOUNTING NEW YORK
    20 RESEARCH DALLAS
    30 SALES CHICAGO
    40 OPERATIONS BOSTON
    But I can't fill a table of objects from cursor with select * bulk collect construction ...
    declare
    TYPE dept2_t IS TABLE of dept2_o;
    dept_o_tab dept2_t:=dept2_t();
    begin
    dept_o_tab.extend(20);
    select * bulk collect into dept_o_tab from dept;
    end;
    RESULT
    ORA-06550: line 6, column 39;
    PL/SQL: ORA-00947: not enough values ....
    How can I fill a table of objects from cursor with select * bulk collect???

    create or replace type dept_ot as object (
    deptno NUMBER(2),
    dname VARCHAR2(14),
    loc VARCHAR2(13));
    create table dept
    (deptno number
    ,dname varchar2(14)
    ,loc varchar2(13)
    insert into dept values (10, 'x', 'xx');
    insert into dept values (20, 'y', 'yy');
    insert into dept values (30, 'z', 'zz');
    select dept_ot (deptno, dname, loc)
      from dept
    create type dept_nt is table of dept_ot
    declare
       l_depts dept_nt;
    begin
       select dept_ot (deptno, dname, loc)
         bulk collect
         into l_depts
         from dept
       for i in l_depts.first .. l_depts.last
       loop
          dbms_output.put_line (l_depts(i).deptno);
          dbms_output.put_line (l_depts(i).dname);
          dbms_output.put_line (l_depts(i).loc);    
       end loop;
    end;
    /

  • I am trying to fill in a form in adobe exportpdf. How can I fill in numbers and symbols? Parenthesis, dollar sign etc.

    I am trying to fill in a form in adobe exportpdf. How can I fill in numbers and symbols? Parenthesis, dollar sign etc.

    Hi;
    Can you provide a little more detail, maybe a screenshot?  ExportPDF only converts PDFs to other file types, what exactly are you using to try to fill out the form?  The two Adobe form filling tools I would recommend would be:
    1) Adobe Reader - a free download you can install on your computer and can be used to fill out most any form.  For numbers, symbols etc it can depend on the field you are entering data into, some fields have restrictions, but you would use those keys on your keyboard, if nothing is entered then that field probably has restrictions.
    2) Adobe Fill & Sign: https://cloud.acrobat.com/fillsign - using the Fill & Sign tab on the acrobat.com website you can fill out most PDFs.  To enter numbers, symbols, etc you would simply add them using your keyboard.
    Thanks,
    Josh

  • How can I fill a pdf form with Excel?

    I have a pdf form and a set of Excel dates. How can I fill the form with this dates?
    Is there any way to transform excel dates into a fdf-File?
    Thank You for helping
    Hans

    I see. That's possible, in theory, but it requires using a complicated custom-made script.
    I would suggest using that Mail Merge option that's available in some versions of Excel to produce multiple single-page files, then flatten all of them (using an Action), and then merge them to a single file, to achieve the same result with much less effort.

  • How can I fill in a form, save the form such that it cannot be further altered, and email it as it was saved?

    How can I fill in a form, save the form such that it cannot be further altered, and email it as it was saved?  I created a form with 5 fields.  It is a form letter that is intended as a receipt for funds received.  I want to fill in the date, name, amount received, etc., save the form with inserted data fields so they can't be further altered, and be able to email it as a complete unalterable PDF document.  What I'm doing now, is filling in the fields, printing it, scanning it, and emailing it as an unalterable document.  The document was created on a Mac using Adobe Acrobat Pro version 10.1.13.  The document is filled in on a PC that only has Adobe reader on it, printed, scanned and emailed as an attachment. There must be a better way! 

    If you have access to a ASP.net Web Server, then the submission could be FLATTENED with FDFToolkit.net and emailed without client-side email software by only using Adobe Reader.
    For more information check out the following websites:
    http://www.pdfemail.net/examples/
    http://www.fdftoolkit.net/examples/

  • How can I install a recent version of Photoshop Elements and keep the albums set up in the older ver

    How can I install a recent version of Photoshop Elements and keep the albums set up in the older version?

    http://tv.adobe.com/watch/learn-photoshop-elements-11/converting-a-catalog-from-previous-v ersions/

  • How can I stop the recent and favorites from show on the screen of my i-phone and i-pad, this is a new feature of iso 8

    How can I stop the recent and favorites from show on the screen of my i-phone and i-pad, this is a new feature of iso 8

    Hi AppleLove78,
    I'm sorry to hear you are having issues with your new iPhone 6. If you continue to have audio or call quality issues, you may find the information and troubleshooting steps outlined in the following article helpful:
    If you can't hear a person on a call or voicemail or if the sound quality is poor on iPhone - Apple Support
    Regards,
    - Brenden

  • How can I fill a pdf form?

    how can I fill a pdf form?

    With Adobe Reader.  If you have any difficulties, please provide some details.

  • How can I fill mask with pattern?

    Hi
    Would you please help me? How can a add pattern to a mask? I drew a motion mask on video clip and now I want to fill it with pattern that I made in Photoshop and saved as PSD, what should I do? How can I fill mask with specific pattern?
    Thanks for any help

    AE doesn't directly support a pattern-fill like PS, so here's a workaround (as Mylenium suggested):
    Create a PS document and create a layer filled with the pattern required.
    Import the layer/PSD to AE and place in timeline.
    Place a copy of the masked layer above the Pattern layer.
    On the pattern layer, set the Track Matte to Alpha Matte.
    Read more here:
    http://livedocs.adobe.com/en_US/AfterEffects/8.0/WS3878526689cb91655866c1103906c6dea-7cf9. html

  • HT4599 how can I see Icloud Control panel version?

    how can I see Icloud Control panel version?

    Yes, that's possible. Simply don't activate the option for storage and backup or PhotoStream. Just activate the calendar option if that's all you want to use.

Maybe you are looking for

  • How to filter the data in a table UI/

    hi all, I have to put filter  and sort functions in my table UI.can ayone please help me how to do this with a code. regrads, Sharan

  • Why does it take over two hours to download a movie on Apply tv

    Why does it take over two hours to download a  movie on Apple TV Thanks

  • Asset account with foreign currecy fluctuations

    hi gurus any body can you please provide the solution to this issue how will we add foreign currency fluctuation losses to the asset APC value i)what is the impact of that before dep run ii)if we added foreign currency losses after dep run what are t

  • Dynamic layout formatting in Oracle BI Publisher reports

    We are creating a planning report in BI Publisher, where in we have a requirement of dynamic formatting based on the month we are running the report. In the report we have different months as columns which displays the values for different KPIs (disp

  • App store hang-ups

    I've only had my iPad for a week but have already had a couple of problems with the app store. This morning, when I tried to download a couple of apps, the waiting box would just show up on the home screen with a blank loading bar. The same was true