How to add padding to s:Scroller?

I have used scroller for my custom component:
<s:Scroller top="0" width="100%" verticalScrollPolicy="auto" height="100%" >
     <components:propertyDetails  left="20" right="20" id="propDetails"  />
</s:Scroller>
My custom component is a group:
<s:Group xmlns:fx="http://ns.adobe.com/mxml/2009"
           xmlns:s="library://ns.adobe.com/flex/spark"
           xmlns:mx="library://ns.adobe.com/flex/mx" height="100%" width="100%" xmlns:components="components.*">
     <s:layout>
          <s:VerticalLayout gap="0" paddingRight="10" paddingTop="5" paddingBottom="5" paddingLeft="0" />
     </s:layout>
     <!--  Some code here -->
</s:group>
I want paddingRight to be 10 only if scrollbar appears on page, otherwise padding should be 0.
In simple words i need a gap of 10 pixels in scrollbar and component if scrollbar is visible, otherwise component should use that space.
Is this possible to achieve?
Best Regards,
Alok Jain

Hi,
I was just trying to do the same thing. And I thought this would be simple...
Ok so minViewportInset doesn't work. my v scroll bar is about 20 px width and If I set this property to 50px the viewport gets smaller by 50 px from all sides when there is no scroller visible. And when it is visible it's located on the same spot where it would be if you had minViewportInset="1";
So this is like a permanent not depending on the scroller visibility condition.
What I need is simply as the guy who posted this post. When there is no scroller - full size viewport, when there is I want 10px padding for my text.
Shongrunder could you tell if there is some developement on this matter, I see this topic is from long time ago. If no then what should I do:
1) scrollerLayout or 2) individual VScrollBar. I need the easiest solution
Also if the guy who posted this question found a good work around this, please share it
Thanks!

Similar Messages

  • How to add padding

    I'm working on this code:
    // Dialog opened when "About" button is pressed
        public void aboutDialogPanel()
            final Stage aboutDialog = new Stage();
            aboutDialog.initModality(Modality.WINDOW_MODAL);
            GridPane grid = new GridPane();
            grid.setAlignment(Pos.CENTER);
            grid.setHgap(0);
            grid.setVgap(3);
            grid.setPadding(new Insets(50, 50, 50, 50));
            // Product name
            Text productName = new Text("Product Name");
            productName.setFont(Font.font("Verdana", 12));
            grid.add(productName, 0, 0);
            // Product version
            Text productVersion = new Text("Version");
            productVersion.setFont(Font.font("Verdana", 12));
            grid.add(productVersion, 0, 2);
            // Close Button
            Button closeButton = new Button("Close");
            closeButton.setOnAction(new EventHandler<ActionEvent>()
                @Override
                public void handle(ActionEvent arg0)
                    // Close the dialog when "Close" button is pressed
                    aboutDialog.close();
            grid.add(closeButton, 0, 3);
            // Configure dialog size and background color
            Scene aboutDialogScene = new Scene(grid, 600, 500, Color.WHITE);
            aboutDialog.setScene(aboutDialogScene);
            aboutDialog.show();
    I'm getting this result:
    [IMG]http://i40.tinypic.com/2pt1m44.png[/IMG]
    I want to center the text and display it equally distributed on the stage. Now the rows are very close to each other. How I can set equally distributed padding around the text?       

    Hi,
    I was just trying to do the same thing. And I thought this would be simple...
    Ok so minViewportInset doesn't work. my v scroll bar is about 20 px width and If I set this property to 50px the viewport gets smaller by 50 px from all sides when there is no scroller visible. And when it is visible it's located on the same spot where it would be if you had minViewportInset="1";
    So this is like a permanent not depending on the scroller visibility condition.
    What I need is simply as the guy who posted this post. When there is no scroller - full size viewport, when there is I want 10px padding for my text.
    Shongrunder could you tell if there is some developement on this matter, I see this topic is from long time ago. If no then what should I do:
    1) scrollerLayout or 2) individual VScrollBar. I need the easiest solution
    Also if the guy who posted this question found a good work around this, please share it
    Thanks!

  • How to add a scrolling text in portrait with iMovie

    how to add a scrolling text in portrait with iMovie

    This is how i was able to do it. Edit html source.
    <div align="center"><marquee id='scroll_news4' bgcolor=#ff9966 "><font color="#000000" size="+1" ><strong>Outlook is down! IT is working on it! </strong></font></marquee></div>
    <input type='Button' value='Stop' id ='b1' onClick='button_click()';>
    <SCRIPT LANGUAGE="JavaScript">
    <!-- Begin
    function button_click()
    if(document.getElementById('b1').value=="Start"){
    document.getElementById('b1').value="Stop";
    document.getElementById('scroll_news4').start();
    }else{
    document.getElementById('b1').value="Start";
    document.getElementById('scroll_news4').stop();
    // End -->
    </script>

  • How to add a scroll bar within a view window ?I want to display x and y axis outside the scoll window and keep those axis static and move the graph within scroll area

    how to add a scroll bar within a view window ?I want to display x and y axis outside the scoll window and keep those axis static and move the graph within scroll area
    ananya

    Hey Ananya,
    I believe what you want to do is possible, but it will not be
    easy.  If you want to add a scroll bar that will scroll the graph
    back and forth but keep the axis set, you would want to add a
    horizontal or vertical scrollbar.  Then you would create an event
    handler for the scroll event.  You would have to manually plot
    different data within this scroll event.  Unfortunately, there is
    not really a built in way to do this with the Measurement Studio plot
    control.
    Thanks,
    Pat P.
    Software Engineer
    National Instruments

  • How to add the scroll bar in the vertical photo gallery?

    like this, how to add the scroll bar? http://www.flashvault.net/tutorial.asp?ID=288 Thanks,

    I want to know how to add a vertical scroll bar in the photo gallery which I copied from the tutorial. And add the event to catch MouseEvent.CLICK for each photo. Please advise. Thanks,

  • How to add scroll bars to a panel

    Hi
    Can anyone plz tell me how to add a scroll bar to a panel created within a JFrame
    Regards
    ats

    import javax.swing.*;
    import java.awt.*;
    class Testing extends JFrame
      public Testing()
        setLocation(300,200);
        setDefaultCloseOperation(EXIT_ON_CLOSE);
        JPanel jp = new JPanel();
        jp.add(new JLabel("Label on a panel"));
        jp.setPreferredSize(new Dimension(200,300));
        JScrollPane sp = new JScrollPane(jp);
        sp.setPreferredSize(new Dimension(200,200));
        getContentPane().add(sp);
        pack();
      public static void main(String args[]){new Testing().setVisible(true);}
    }

  • How to add scroll bar to JDesktopPane?

    Hi All,
         After download the "InternalFrameDemo.java" from the swing tutorial, I want to add scrollbars to JDesktopPane so that whenever a internal frame moves off the desktop view port, a scrollbar will display. I have tried many ways to implement this but no success.
    Do you know how to add scrollbars to JDesktopPane?
    Thanks
    Anson

    You can't get there from here! Assuming that wou want is to make the desktop scrollable that is.
    The trick to make somthing scrollable is to make JScrollPane CONTAIN the component to be scrolled. If you could ask the desktop to return the component it contains, you might have a chance but no luck, the desktop pane actually inherits a layered pane which is most likey is what you would like JScrollPane to contain.
    Now here's another angle to this story... the desktop is complex enough without scrollbars, why would you want to complicate things by adding a scroll bar anyway? Say one of its window is maximized and has a scrollbar of its own AND the desktop has one.... that makes TWO scroll bars side by side. Talk about confusing.
    I believe the desktop was designed so scroll bars can't be added for a very good reason: good UI practises.

  • How to add scroll bar in child form ( vb6.0 )

    look at this picture link (i think you will understand the issue)
    http://tinypic.com/r/25k232u/8
    These information(class1,class2 ……) are loaded from database and this time the information is too much and it moves down to the appearing part of the window and unable to view these items
    How to add scroll bar in visual basic child form so that the data items can be viewed by scroll in case it go beyond the screen.

    Hi,
    Welcome to MSDN.
    I am afraid that these forums donot support VB6 any more, you could refer to this thread:
    Where to post your VB 6 questions
    You could consider posting this issue in these forums below:
    These forums do not support Visual Basic 6, however there are many third-party support sites that do. If you have a VB6-related question please visit these popular forums:
    VB Forums
    VB City
    Thanks for your understanding.
    Regards.
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • How to add scroll function in  the applet launched by  Java Web Start?

    I have Java Web Start installed in order for the applet to launch.The applet size: width:700 height:1000
    my compuer resolution:800*600
    the applet launched by Java Web Start can only be seen partly,especially height.How to add scroll function in the applet launched by Java Web Start?
    Thanks for help.
    email:[email protected]

    You can very easily add a JScrollPane manually between the Applet and your content. Perhaps it would be beter if javaws did this automatically. In the browser, an applet can be any size. In Java Web Start an applet is directly contained within a JFrame, so it cannot be smaller than the minimum size of a JFrame, or Larger than the max.

  • HT3500 how to add Hp printer to i pad hp 5510

    how to add hp printer 5510 series to i pad 2

    Some printers require a firmware update from the manufacturer to enable the AirPrint feature. Check with HP for available updates for your printer model.
    You might also want to post in the iPad Community Support area....as this is not a question for the AirPort Extreme, AirPort Express or Time Capsule.
    Click Here:
    Using iPad

  • I need to learn how to add a page at the end of my video to put credits?

    I am editing for the first time EVER and need to know how to add credits to the end of a video

    There are different ways to add credits. Did you have anything particular in mind?
    You may find some ideas here:
    How to Create Scrolling Movie Credits in Adobe Premiere Pro - YouTube
    https://helpx.adobe.com/premiere-pro/using/rolling-crawling-titles.html
    Creating and Editing Titles

  • How to add a loader to an image gallery loading content using only actionscript

    hi i am loading all thumbs and  images in a container on a single frame using action script..but the  size of the swf becomes 1.2 mb so i want to add a loader to it...the  loader i am trying to add counts the frames but my file has just one  frame so the loader doesnot show up..
    here is the script of my  gallery..and the timeline has just one frame...
    import mx.transitions.Tween;
    import  mx.transitions.easing.*;
    this.createEmptyMovieClip("container",1);
    var  imagesNumber:Number = 18;
    var scrolling:Boolean = true;
    for (i=1;  i<=imagesNumber; i++) {
    container.attachMovie("thumb"+i,"thumb"+i+"_mc",i);
    myThumb_mc  = container["thumb"+i+"_mc"];
    if (i==1)
        myThumb_mc._x =  (0.0)*myThumb_mc._width;
    else
        myThumb_mc._x =  ((1.2*i)-1.2)*myThumb_mc._width;
    myThumb_mc._y =  (Stage.height-myThumb_mc._height)/2;
    myThumb_mc._alpha = 100;
    myThumb_mc.largerImage  = i;
    myThumb_mc.onRollOver = function() {
    this._alpha = 60;
    myThumb_mc.onRollOut  = function() {
    this._alpha = 100;
    myThumb_mc.onRelease =  function() {
    this._alpha=100;
    for (i=1; i<=imagesNumber; i++) {
    var  myClip = container["thumb"+i+"_mc"];
    myClip.enabled = false;
    scrolling  = false;
    _root.attachMovie("image"+this.largerImage,"large_mc",2);
    large_mc._x  = (Stage.width-large_mc._width)/2;
    large_mc._y =  (Stage.height-large_mc._height)/2;
    new Tween(large_mc, "_alpha",  Strong.easeOut, 0, 100, 0.5, true);
    new  Tween(container,"_alpha",Strong.easeOut,100,50,0.5,true);
    large_mc.onRelease  = function() {
    scrolling = true;
    var myFadeOut = new  Tween(large_mc, "_alpha", Strong.easeOut, 100, 0, 0.5, true);
    new  Tween(container,"_alpha",Strong.easeOut,50,100,0.5,true);
    myFadeOut.onMotionFinished  = function() {
    for (i=1; i<=imagesNumber; i++) {
    var myClip =  container["thumb"+i+"_mc"];
    myClip.enabled = true;
    large_mc.removeMovieClip();
    container.onEnterFrame  = function() {
    if (scrolling){
    this._x +=  Math.cos((-_root._xmouse/Stage.width)*Math.PI)*20;
    if (this._x>0) {
    this._x  = 0;
    if (-this._x>(this._width-Stage.width)) {
    this._x =  -(this._width-Stage.width);
    anyone knows how to add a loadre to this...?
    thanks..

    Check these links for tutorials on loading images
    http://www.kirupa.com/developer/flashcs3/loading_image_as3_pg1.htm
    http://tutorials.flashmymind.com/2009/02/loading-multiple-images/

  • How to add a table(from TableRenderDemo) to a JFrame again

    Hello again:
    Thanks for stephen andrews's adivice, I follow your adivice to add code (it is in
    EventHandeler of DrawCalendar class, and they indicated by ???????????), but it still not work, please check for me why, Thanks.
    My problem
    Please run my coding first, and get some view from my coding.
    At the movement, I got a problem, I have not idea how to add a table(it is from TableRenderDemo) to JFrame when I click on the button(from DrawCalendar) of the numer 20, and I want the table disply under the buttons(from DrawCalendar).
    Please help me to solve this problem, thanks.
    *This program for add some buttons and a table on JFrame
    import java.awt.*;
    import javax.swing.*;public class TestMain extends JFrame{
    private static TableRenderDemo tRD;
    private static TestMain tM;
    protected static Container c;
    private static DrawCalendar dC;
    public static void main(String[] args){
    tM = new TestMain();
    tM.setVisible(true);
         public TestMain(){
         super(" Test");
         setSize(800,600);
    //set up layoutManager
    c=getContentPane();
    c.setLayout ( new GridLayout(3,1));
    tRD=new TableRenderDemo();
    dC=new DrawCalendar();
    addItems();//add Buttons to JFrame
    private void addItems(){
         c.add(dC); //add Buttons to JFrame
         //c.add(tRD); //add Table to JFrame     
    *This program for add some buttons to JPanel
    *and add listeners to each button
    *I want to display myTable under the buttons,
    *when I click on number 20, but why it doesn't
    *work, The coding for these part are indicated by ??????????????
    [import javax.swing.*;
    import java.awt.*;
    import java.awt.event.*;
    import java.awt.GridLayout;
    public class DrawCalendar extends JPanel {
         private static DrawCalendar dC;
         private static TestMain tM;
         private static TableRenderDemo myTable;
         private static GridLayout gL;
         private static final int nlen = 35;
        private static String names[] = new String[nlen];
    private static JButton buttons[] = new JButton[nlen];
         public DrawCalendar(){
              gL=new GridLayout(5,7,0,0);
              setLayout(gL);
              assignValues();
              addJButton();
              registerListener();
    //assign values to each button
         private void assignValues(){
              names = new String[35];
         for(int i = 0; i < names.length; i++)
         names[i] = Integer.toString(i + 1);
    //create buttons and add them to Jpanel
    private void addJButton(){
         buttons=new JButton[names.length];
         for (int i=0; i<names.length; i++){
         buttons=new JButton(names[i]);
         buttons[i].setBorder(null);
         buttons[i].setBackground(Color.white);
         buttons[i].setFont(new Font ("Palatino", 0,8));
    add(buttons[i]);
    //add listeners to each button
    private void registerListener(){
         for(int i=0; i<35; i++)
              buttons[i].addActionListener(new EventHandler());          
    //I want to display myTable under the buttons,
    //when I click on number 20, but why it doesn't
    //work
    private class EventHandler implements ActionListener{
         public void actionPerformed(ActionEvent e){
         for(int i=0; i<35; i++){
         if(i==20){                  //????????????????????
              tM=new TestMain(); //I want to display myTable under the buttons,
              tM.c.removeAll(); //when I click on number 20, but why it doesn't
              tM.c.add(dC); //work
              tM.c.add(myTable); //???????????????????????????????????????
              tM.validate();
         if(e.getSource()==buttons[i]){
         System.out.println("testing " + names[i]);
         break;
    *This program create a table with some data
    [import javax.swing.table.AbstractTableModel;
    import javax.swing.table.TableColumn;
    import javax.swing.DefaultCellEditor;
    import javax.swing.table.TableCellRenderer;
    import javax.swing.table.DefaultTableCellRenderer;
    import javax.swing.*;
    import java.awt.*;
    import java.awt.event.*;
    public class TableRenderDemo extends JScrollPane {
        private boolean DEBUG = true;
        public TableRenderDemo() {
          //  super("TableRenderDemo");
            MyTableModel myModel = new MyTableModel();
            JTable table = new JTable(myModel);
            table.setPreferredScrollableViewportSize(new Dimension(700, 70));//500,70
             //Create the scroll pane and add the table to it.
             setViewportView(table);
            //Set up column sizes.
            initColumnSizes(table, myModel);
            //Fiddle with the Sport column's cell editors/renderers.
            setUpSportColumn(table.getColumnModel().getColumn(2));
    * This method picks good column sizes.
    * If all column heads are wider than the column's cells'
    * contents, then you can just use column.sizeWidthToFit().
    private void initColumnSizes(JTable table, MyTableModel model) {
    TableColumn column = null;
    Component comp = null;
    int headerWidth = 0;
    int cellWidth = 0;
    Object[] longValues = model.longValues;
    for (int i = 0; i < 5; i++) {
    column = table.getColumnModel().getColumn(i);
    try {
    comp = column.getHeaderRenderer().
    getTableCellRendererComponent(
    null, column.getHeaderValue(),
    false, false, 0, 0);
    headerWidth = comp.getPreferredSize().width;
    } catch (NullPointerException e) {
    System.err.println("Null pointer exception!");
    System.err.println(" getHeaderRenderer returns null in 1.3.");
    System.err.println(" The replacement is getDefaultRenderer.");
    comp = table.getDefaultRenderer(model.getColumnClass(i)).
    getTableCellRendererComponent(
    table, longValues[i],
    false, false, 0, i);
    cellWidth = comp.getPreferredSize().width;
    if (DEBUG) {
    System.out.println("Initializing width of column "
    + i + ". "
    + "headerWidth = " + headerWidth
    + "; cellWidth = " + cellWidth);
    //XXX: Before Swing 1.1 Beta 2, use setMinWidth instead.
    column.setPreferredWidth(Math.max(headerWidth, cellWidth));
    public void setUpSportColumn(TableColumn sportColumn) {
    //Set up the editor for the sport cells.
    JComboBox comboBox = new JComboBox();
    comboBox.addItem("Snowboarding");
    comboBox.addItem("Rowing");
    comboBox.addItem("Chasing toddlers");
    comboBox.addItem("Speed reading");
    comboBox.addItem("Teaching high school");
    comboBox.addItem("None");
    sportColumn.setCellEditor(new DefaultCellEditor(comboBox));
    //Set up tool tips for the sport cells.
    DefaultTableCellRenderer renderer =
    new DefaultTableCellRenderer();
    renderer.setToolTipText("Click for combo box");
    sportColumn.setCellRenderer(renderer);
    //Set up tool tip for the sport column header.
    TableCellRenderer headerRenderer = sportColumn.getHeaderRenderer();
    if (headerRenderer instanceof DefaultTableCellRenderer) {
    ((DefaultTableCellRenderer)headerRenderer).setToolTipText(
    "Click the sport to see a list of choices");
    class MyTableModel extends AbstractTableModel {
    final String[] columnNames = {"First Name",
    "Last Name",
    "Sport",
    "# of Years",
    "Vegetarian"};
    final Object[][] data = {
    {"Mary ", "Campione",
    "Snowboarding", new Integer(5), new Boolean(false)},
    {"Alison", "Huml",
    "Rowing", new Integer(3), new Boolean(true)},
    {"Kathy", "Walrath",
    "Chasing toddlers", new Integer(2), new Boolean(false)},
    {"Sharon", "Zakhour",
    "Speed reading", new Integer(20), new Boolean(true)},
    {"Angela", "Lih",
    "Teaching high school", new Integer(4), new Boolean(false)}
    public final Object[] longValues = {"Angela", "Andrews",
    "Teaching high school",
    new Integer(20), Boolean.TRUE};
    public int getColumnCount() {
    return columnNames.length;
    public int getRowCount() {
    return data.length;
    public String getColumnName(int col) {
    return columnNames[col];
    public Object getValueAt(int row, int col) {
    return data[row][col];
    * JTable uses this method to determine the default renderer/
    * editor for each cell. If we didn't implement this method,
    * then the last column would contain text ("true"/"false"),
    * rather than a check box.
    public Class getColumnClass(int c) {
    return getValueAt(0, c).getClass();
    * Don't need to implement this method unless your table's
    * editable.
    public boolean isCellEditable(int row, int col) {
    //Note that the data/cell address is constant,
    //no matter where the cell appears onscreen.
    if (col < 2) {
    return false;
    } else {
    return true;
    * Don't need to implement this method unless your table's
    * data can change.
    public void setValueAt(Object value, int row, int col) {
    if (DEBUG) {
    System.out.println("Setting value at " + row + "," + col
    + " to " + value
    + " (an instance of "
    + value.getClass() + ")");
    if (data[0][col] instanceof Integer
    && !(value instanceof Integer)) {
    //With JFC/Swing 1.1 and JDK 1.2, we need to create
    //an Integer from the value; otherwise, the column
    //switches to contain Strings. Starting with v 1.3,
    //the table automatically converts value to an Integer,
    //so you only need the code in the 'else' part of this
    //'if' block.
    try {
    data[row][col] = new Integer(value.toString());
    fireTableCellUpdated(row, col);
    } catch (NumberFormatException e) {
    JOptionPane.showMessageDialog(TableRenderDemo.this,
    "The \"" + getColumnName(col)
    + "\" column accepts only integer values.");
    } else {
    data[row][col] = value;
    fireTableCellUpdated(row, col);
    if (DEBUG) {
    System.out.println("New value of data:");
    printDebugData();
    private void printDebugData() {
    int numRows = getRowCount();
    int numCols = getColumnCount();
    for (int i=0; i < numRows; i++) {
    System.out.print(" row " + i + ":");
    for (int j=0; j < numCols; j++) {
    System.out.print(" " + data[i][j]);
    System.out.println();
    System.out.println("--------------------------");

    http://forum.java.sun.com/faq.jsp#format

  • How to add a graphic watermark that is bigger than the photo?

    How to add a graphic watermark that is bigger than the photo?
         Basically I want to add a watermark that is a border, like "outside stroke" so that it doesn't clip the photo.
         Upper, left and right side are 10px and on the bottom is my signature that is 40px high. I know how to do this in Photoshop, but can't figgure it out in Lightroom.
         The inset function with negative numbers doesn't work, because it only export to the size of the exported image, instead it should resize the image with those 10px up, left and right and 40px on      the bottom.
    My bordes look like this either one of the two can be used, and if you scroll down you will se how the end result should look like.
    And below is what it should look like, so that Lightroom doesn't clip the photo.

    Are you sure the focus of your piano roll is on the right track? Are you zoomed in/out enough?

  • How to add contents of an arrayList to a JList

    Hi,
    I am trying to figure out how to add the contents of an arraylist to a Jlist.
    Basically I have 3 classes which are as follow:
    1. AuctionItems(String name, int bid) which represents an item in auction
    2. AuctionItemsFactory which creates AuctionItems and adds them to an arraylist called stock
    3. AuctionBidsGui1 which is the interface where the user can see the items in the auction and select them from a JList.
    But I dont know how to read the contents of the stock(arraylist) into the JList which is in AuctionBidsGui1. Below are the 3 classes mentioned above
    public class AuctionItems {
         String name;
         int bid;
         public AuctionItems(){
              name = null;
              bid = 0;
         public AuctionItems(String name, int bid){
              this.name = name;
              this.bid = bid;
         public String getName(){
              return name;
         public int getBid() {
              return bid;
    public class AuctionItemsFactory {
         private ArrayList<AuctionItems> stock;
         int size;
         public AuctionItemsFactory() {
              stock = new ArrayList<AuctionItems>();
         public void addItems(AuctionItems item) {
              stock.add(item);
    //removes last element of the arrayList
         public void removeItems() {
              int n = stock.size() - 1;
              stock.remove(n);
         public void printNumOfItems() {
              int n = stock.size();
              System.out.println(n);
         public int numberOfItems(){
              return stock.size();
         public void printItems(){
              for (AuctionItems item : stock) System.out.println(item);
    and this one is a small part of the AuctionBidsGui1 class which represents the JList where the list of the items will go.
    public void addItemListWidgets() {
              itemsList = new JList();
              itemsList.setSelectionMode(ListSelectionModel.MULTIPLE_INTERVAL_SELECTION);
              itemsList.setLayoutOrientation(JList.VERTICAL);
              itemsList.setVisibleRowCount(10);
              itemsList.setSelectedIndex(0);
              JScrollPane itemsListScroller = new JScrollPane(itemsList); // put the list in the scroller
              itemsListScroller.setVerticalScrollBarPolicy(ScrollPaneConstants.VERTICAL_SCROLLBAR_ALWAYS);
              itemsListScroller.setHorizontalScrollBarPolicy(ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER);
              itemsListPanel.add(itemsListScroller);
         }

    I know that I have to use the toArray() but i dont know what type of method to use for this because i will need to implement a method in my AuctionItemsFactory class which will copy the contents of the arraylist into an array so then i can call this methos from my AuctionBidGui1 class.
    I would appreciate if you could give me a bit more hints.

Maybe you are looking for