Column size and number of chars

I have fixed Jtables column header size.
when I put a large text in this colums ,half of text is hidden. I know this problem is solved with setAutoResizeMode, bat I don't wont to use it.
I wont to know how many chars can I put in this column(with fixed size),
How can I return number Of chars or length or text which can be possible tu put fixed columean size?

Well, you can do something like (untested)
TableColumnModel tcm = table.getColumnModel();
TableColumn col = tcm.getColumn( n );
int cw = col.getMaxWidth();
String st = col.getHeaderValue().toString();
JTableHeader header = table.getTableHeader();
FontMetrics fm = header.getFontMetrics( header.getFont() );
for( int sw = fm.stringWidth( st ); sw > cw; ) {
     st = st.substring( 0, st.length()-1 );
     sw = fm.stringWidth( st );
col.setHeaderValue( st );That should at least give you some ideas.

Similar Messages

  • Documents, storage size and number of members (in Workspaces)

    Greetings!
    Is there any limit on the number of documents, storage size and number of members?
    If positive, how can I expand this?
    Thanks in advance.

    There is no limit to the number of documents or the number of members.
    At this time, we are providing 5 GB of storage, but there is no way to purchase additional space.

  • How u will set the external parameters like packet size and number

    How u will set the external parameters like packet size and number of parallel process.

    Dear Karthik,
    <b>ALE:</b>    
    Use Transaction UPSC02         -      ALE Distribution Unit: Packet Types.
    Performance Optimization for <b>ODS</b> Objects:
    To ensure a good ODS object loading performance, take the following into account:
           1.      Creating SIDs
    The creation of SIDs takes a long time and can be avoided in the following cases by:
           Not setting the indicator for BEx Reporting if you are using the ODS object only as a data store. If you do set this indicator, SIDs are created for all new characteristic values.
           If you use line items (for example, document number or time stamp) as characteristics in the ODS object, in the characteristic maintenance, indicate these as Attribute Only.
    SIDs are created in parallel if <b>parallel activation</b> is switched on (see last point). They are then created with the same number of parallel processes as created for the activation.
    However, if you specify a server group or a special server in customizing, these specifications are not only valid for the activation, but also for the SID creation. The creation of SIDs runs on the application server on which the batch job also runs.
           2.      DB partitioning in active data tables (technical A table)
    By partitioning by database level, you can delete data from the ODS object much more quickly. As a partitioning criterion, choose the characteristic by which you want to delete.  For more information on partitioning database tables, see the database documentation (DBMS-CD). Partitioning is supported by the following databases: Oracle, DB2/390, Informix.
           3.      Indexing
    Use selection criteria for queries for ODS objects. If the key fields are specified, the existing primary index is used. The more frequently accessed characteristic should appear on the left-hand side.
    If you did not specify the key fields completely in the selection criteria (visible in the SQL trace), you improve the run time of the query by creating additional indexes. You can create these secondary indexes in the ODS object maintenance.
           4.      Activation of data in an ODS object
    To improve system performance when activating data in the ODS object, you can make the following entries in Customizing under SAP Customizing Implementation Guide -> SAP NetWeaver -> Business Information Warehouse -> General BW Settings ->  ODS Object Settings:
           the maximum number of parallel processes when activating data in the ODS object as when moving SIDs
           the minimum number of data records for each data package when activating data in the ODS object, meaning you define the size of the data packages that are activated
           the maximum wait time in seconds when activating data in the ODS object. This is the time when the main process (batch process) waits for the dialog process that is split before it classifies it as having failed.
           the server group that needs to be used when activating the data in ODS objects in parallel You have to create the server groups beforehand using the following path: Tools -> Administration -> Network -> RFC Destination, RFC -> RFC Groups. If you do not specify anything here, then the activation runs on the server on which the batch process was started for activation. If a server from the server group is not active, then the activation is cancelled.
           5.      Loading unique data records
    If you only load unique data records (meaning data records with nonrecurring key combinations) into the ODS object, then the loading performance is improved when you set the indicator Unique Data Records in the ODS object maintenance.
    The records are then updated more quickly because the system no longer needs to check whether the record already exists. You do have to be sure that there duplicate records are definitely not being loaded, because this will lead to termination.
    Regards,
    Naveen.

  • What is the size and number of documents we can upload to a document library at one time

    HI
    what is the size and number of documents we can upload to a document library at one time.
    like we have scenario , we developed a custom solution to scan and upload documents to sharepoint sites doc library.
    here we face issues when user try to upload 100 documents with the size of each doc 2-3 MB, at one time.
    adil

    Hi Adil,
    The maximum number and size of documents to upload in a document library is determined by a setting in Central administration. You can go to Central administration -> Application Management -> Manage Web Applications -> Select the Web Application
    -> Click on General Settings in the ribbon. Scroll down and you will see "Maximum Upload Size" section. The maximum value that can be set is 2047 MB. 
    Blog | SharePoint Learnings CodePlex Tools |
    Export Version History To Excel |
    Autocomplete Lookup Field

  • Excessive LOBSEGMENT size and number of extents

    I am running a procedure to load a large number of records ( >1million). The records that I am loading has only a few columns including an XMLTYPE column containing the data from an XML file of size 10k. After reaching the 1 million mark, the size of the LOBSEGMENT associated with the XMLTYPE column is nearing 20GB and has nearly 600 extents! I understand that "auto" segment mgmt is the cause for the number of extents, but why is the LOBSEGMENT SO LARGE???
    Thanks in advance for any suggestions or ideas...
    Below are the tablespace settings:
    BLOCK_SIZE : 8192
    INITIAL_EXTENT : 65536
    NEXT_EXTENT :
    MIN_EXTENTS : 1
    MAX_EXTENTS : 2147483645
    PCT_INCREASE :
    MIN_EXTLEN : 65536
    STATUS : ONLINE
    CONTENTS : PERMANENT
    LOGGING : NOLOGGING
    FORCE_LOGGING : NO
    EXTENT_MANAGEMENT : LOCAL
    ALLOCATION_TYPE : SYSTEM
    PLUGGED_IN : NO
    SEGMENT_SPACE_MANAGEMENT : AUTO
    DEF_TAB_COMPRESSION : DISABLED
    RETENTION : NOT APPLY
    BIGFILE : NO

    Yay, we're almost done :)
    TEST.SQL>create table yjam.tablename (a number);
    Table created.
    TEST.SQL>create table cds.tablename (a number);
    Table created.
    TEST.SQL>SELECT EXTENTS, (bytes/1024/1024) MB FROM user_segments u
      2  WHERE segment_type = 'TABLE'
      3  AND u.segment_name = 'TABLENAME'
      4  /
    no rows selected
    TEST.SQL>l1
      1* SELECT EXTENTS, (bytes/1024/1024) MB FROM user_segments u
    TEST.SQL>c:user:dba
      1* SELECT EXTENTS, (bytes/1024/1024) MB FROM dba_segments u
    TEST.SQL>/
       EXTENTS         MB
             1         ,5
             1          5Yoann, in a kidding mood.

  • Size and number of extent

    Hi,
    how to see the size (in Mbyte) and the number of the extents of a table ?
    many thanks.

    Yay, we're almost done :)
    TEST.SQL>create table yjam.tablename (a number);
    Table created.
    TEST.SQL>create table cds.tablename (a number);
    Table created.
    TEST.SQL>SELECT EXTENTS, (bytes/1024/1024) MB FROM user_segments u
      2  WHERE segment_type = 'TABLE'
      3  AND u.segment_name = 'TABLENAME'
      4  /
    no rows selected
    TEST.SQL>l1
      1* SELECT EXTENTS, (bytes/1024/1024) MB FROM user_segments u
    TEST.SQL>c:user:dba
      1* SELECT EXTENTS, (bytes/1024/1024) MB FROM dba_segments u
    TEST.SQL>/
       EXTENTS         MB
             1         ,5
             1          5Yoann, in a kidding mood.

  • How can we set the column size and height dynamically

    Hi All,
    I have a requirement where i am designing rtf for excel output.Here i have a column where the height of that particular column must get reset dynamically according to the data that's getting populated.
    Thankq in advance.

    I had the same problem and I finally found that you can't set a form bean.
    There is no methods to do this.
    The only way is to make it a dynamic form bean, but i haven't investigated it.
    Now I use normal beans to move data between pages.
    Sorry if it's not what you want. If you have another solution let me know.

  • How to calculate the size and number of nodes in the btree?

    I need to determine the size of the btree nodes in the log file and the how many internal and leaf nodes in the btree. For example if I have 2.88M records approximately how much disk space is used up by the JE's internal structures? This info will help me determine the best size of the data records.

    Chad,
    Keys are stored in order in the btree. They are ordered by the custom comparator if one is used, otherwise by the default (unsigned byte) comparator.
    Key prefixing (when it is available -- remember that we're talking about a future feature here) reduces memory and disk space for the adjacent keys in a Btree node when the initial bytes of those keys are in common.
    If your keys that are adjacent (according to your custom comparator) don't have common bytes at the front, then key prefixing won't have any advantage.
    --mark                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

  • VMX20 - Limit virtual machine log file size and number

    Hi all,
    Here is parameter file
    log.rotateSize=1000000
    log.keepOld=10
    that I have apply on virtual machine VMX. After I run the compliance checker again and it still showing fail.
    I also have try restart the virtual machine machine few time but the log file keep increase.
    For my understanding if we apply this parameter setting once the virtual machine log file over 1,000kb or 10 log file the new log file will replace the old one, correct me if Ii wrong.
    Here is my question
    1. Did the parameter file have restrict on any version of VMware?
    2. If the log file less than 1,000kb and it already have 10 log file, so the new log file will still replace the old log file?
    Thk.
    Best regards.
    Wong Pak Lian

    Hi a_nut_in,
    The problem have been solved in VMware vsphere version 5 with compliance checker for vsphere 5.0.
    But under VMware vsphere version 4 I have found out the parameter is ok and workable but the results is still showing fail, will this is software bug?
    Thk.
    Best regards.
    Wong Pak Lian

  • How to know  columns and table name  whose column size are modified

    Hi guys
    I want to know which all columns in the tables are modify
    i.e. list of columns and table name whose column size are modified
    Step1 :
    CREATE TABLE employees
    ( employee_number number(5) ,
    employee_name varchar2(50) ,
    department_id number(10)
    CREATE TABLE Supplier
    ( Supplier_number number(5) ,
    Supplier_name varchar2(50) ,
    CREATE TABLE customers
    ( customer_id number(10) not null,
    customer_name varchar2(50),
    address varchar2(50),
    city varchar2(50),
    state varchar2(25),
    zip_code varchar2(10),
    Step2 :
    Alter table employees
    MODIFY employee_number number(10)
    ALTER TABLE supplier
    MODIFY supplier_name varchar2(100)
    step3
    query to dispaly
    columnname table name
    employee_number employees
    supplier_name supplier
    How to know columns and table name whose column size are modified
    could you please provide query
    Thanks in Advance

    09:35:50 SQL> desc dba_objects
    Name                            Null?    Type
    OWNER                                  VARCHAR2(30)
    OBJECT_NAME                             VARCHAR2(128)
    SUBOBJECT_NAME                         VARCHAR2(30)
    OBJECT_ID                             NUMBER
    DATA_OBJECT_ID                         NUMBER
    OBJECT_TYPE                             VARCHAR2(19)
    CREATED                             DATE
    LAST_DDL_TIME                             DATE
    TIMESTAMP                             VARCHAR2(19)
    STATUS                              VARCHAR2(7)
    TEMPORARY                             VARCHAR2(1)
    GENERATED                             VARCHAR2(1)
    SECONDARY                             VARCHAR2(1)
    NAMESPACE                             NUMBER
    EDITION_NAME                             VARCHAR2(30)LAST_DDL_TIME can be utilized

  • Exception:"Decrease the number of char between the beginning of the document and its root element"

    I'm now using a javabean in my jsp page to parse xml;when my xml file's size is
    about 10k,it just work fine;when my xml file's size became 50k,it throws the followng
    Exception:
    Failed to open xml document,Failed to retrieve Public id or system id from the
    document. Decrease the number of char between the beginning of the document and
    its root element. But when I run this javabean in JBuild ,it works fine no matter
    how big the xml file becomes;
    Why? the error message is in the attachment.

    The prologue must be included at the top of the document, followed by the root
              element.
              joden2000 wrote:
              > what does this exception mean:decrease the number of char between the beginning
              > of the document and its root element? When my xml file is about 10k,it works
              > just fine,when it becomes 50k ,the exception show.How can I deal with this?
              

  • Set maximum matrix row and column size

    I hope someone can help me with this. Is there any way to set the row and column size of a matrix control? I have not been able to find a solution. The only way I've been able to set the size is by resetting matrix to its previous state if the user inputs a value outside of the bounds I would like to set. This is done in the 'value changed' event case.
    The matrix is large and therefore I cannot increase the size of the control to be the maximum size and then hide the row and column index controls. These have to be displayed.
    Any suggestions or help would be greatly appreciated. Thanks in advance.

    Here's a quick and dirty way.
    Simply hide the index controls and replace them with some fake numeric controls and set the data range accoding to your requirements.
    In the attached example (LV8.0), the fake index controls are limited to 0..2, the array size is 5x5 and the displayed array portion is 3x3. Seems to work fine.
    (Of course you could add a bit more code to set the limits automatically based on the various sizes.)
    You could also make it more fancy and turn the entire thing into an Xcontrol.
    Message Edited by altenbach on 06-06-2007 05:32 PM
    LabVIEW Champion . Do more with less code and in less time .
    Attachments:
    LimitArrayControl.vi ‏18 KB

  • In the new iOS-7 Safari, has the "reader" function been changed to eliminate the option to modify font size (and hence to modify the number of words per line), or is it just that I can't find how to do that?

    In the new iOS-7 Safari, has the "reader" function been changed to eliminate the option to modify font size (and hence to modify the number of words per line), or is it just that I can't find how to do that?

    iOS 7
    Seperate text size modification is no longer available in Safari Reafer.
    Use Settings.
    Settings >General > Text Size

  • How to Increase the Rows and Columns Size of Bex Query in Enterprise Portal  of SAP  7.3

    Dear All,
    Please let me know the process how to Increase the Rows and Columns  Size of Bex Query in Enterprise Portal  of SAP  7.3 .
    Currently I am getting Only  4 columns and 10 rows in One Page .And I am getting 1,2 etc tabs for both row and column. So i want to increase the column length more than 100  and row length more than 10000.
    Please suggest me a suitable solution to over come this issue.
    Please find the Below screen shot.
    Thanks
    Regards,
    Sai

    Dear All,
    Please find the attached screen shot.
    The report be open with 4 or 5 columns and 5 or 6 rows.
    So, please  let me know how to increase the length of the table.
    Do the needful for me to over come this issue.
    Thanks
    Regards,
    Sai.

  • Many report columns (70+) and ORA-06502 (Small char buffer)

    Hello!
    I have a big problem with my few tables and Oracle APEX. I have 2 big tables with 75 and 108 columns and If i try to translate a column headings in report (tabular form) that appear a ORA-06502 Error (Small char buffer). If i don't change column order and headings that all ok.
    I thought that it beacuse of incorrect columns datatype but if i set column heading in report to "None" or if i set to null part of column heading (30-40%) that all be ok with report.
    This problem not appear with other more small tables
    This is message from debug mode:     
    Debug Screenshot

    TexasApexDeveloper wrote:
    You are running into an issue of having too many columns on a report.. Is there any way to reduce the # of columns you are trying to report on/display?
    Thank you,
    Tony Miller
    Ruckersville, VAYes, i can split my big tables to 2 parts, but it not best way for our application...
    There is no other problem solution?
    Thank you for fast reply.

Maybe you are looking for

  • Nokia Lumia 928 Texting Problem

    Just upgraded to the Lumia 928 (white) yesterday. A few hours after getting home with the device I realized I was not receiving text messages. I began to troubleshoot to the best of my knowledge. I can send/receive calls, send/receive picture message

  • 9i installatin on w2k URGENT HELP PLEASE!!!!!!

    Hi all. My computer runs win2k sp3 on 512 mb ram. I have tried hundred times but I cant create database on oracle 9i. Installation seems ok but whenever it starts to create a database, it gives an error on 41% then gives another on 46% says: TNS ORA

  • USB Power Line adaptor question

    Hello. I'm looking for a USB PowerLine adaptor. Has anyone experience with using them? Any recommendations on what to buy? The idea is have my Epson AIO connected to my MacMini, then share it out so my MacBook Pro and 2 other macs can print/scan wire

  • Assign field from Extended Structure

    Hi, friends I'm tryin to Assign the field GPARN (Partner Number) from PO Screen, but is occuring a Short Dump. I saw that WRF02K is a extended structure. How can I assign a filed value from a Extended structure ? I'm using the code bellow.         DA

  • (Wi-Fi) Keychain System: Interesting Info on the "System" Pane..?

    I have used keychain for years, but I never bothered to learn enough what it can help me with some parts. I am mainly looking into about part line about the "Where:" section for it which I have attached which I have found through google to help my qu