How can i Auto Size the Column width in RDLC Report
Hi Friend's,
I have created Windows application with RDLC Report. I am binding(Generating) dynamic columns and data's in RDLC Report Using Matrix control, I need to make Auto size of Column width for each Column in
Matrix of RDLC report. So Can any one suggest me to make the Auto Size of Column Width in RDLC.
Thanks in Advance,
Mohan G
Hi Mohan,
In Reporting Services, the column width/height is hard-coded, hence, we cannot set the column width/height dynamically or based on an expression. So is the report size.
In addition, since it is a RDLC report, we need a ReportViewer control to display this report within a custom application. If you need to change the size of the whole report, we can set the AsyncRendering property of the ReportViewer control to false, and
set the SizeToReportContent property to true.
Regards,
Mike Yin
TechNet Community Support
Similar Messages
-
How can I display all the columns on the screen without scrolling from side to side?
My clinic software has many columns. How can I display all the columns without having to scroll from left to right all the time?
If the software you are using doesn't offer the ability to increase or decrease document size, as many do, then the only way is to increase your screen resolution. If that's not possible, maybe you can decrease your font size? If you can't do any of these, I think you're out of luck!
-
How to extract the column width in ALv report if its executed in background
I am executing an ALV report in background , in front end i am getting data properly, in back end for some columns some of the digits are missing.For example if PO no is of 10 digits it will display only 8 becos column size is like that , how to extract coulmns in back ground.
I have executed in background and checked the spool and for some of the columns width is not sufficient to display comeplete data so please suggest how to extract the columns sizes if executed inj background for an ALVHi Deepthi,
you can try with the above mentioned suggestions ,if its worked its fine ,
If not use Docking container instead of custom container, For ALV in back ground jobs, its suggest to use docking container instead of custom container , below you can find the declaration for docking container and code to use docking and custom container in your program for fore and back ground.
or you can use docking container alone for both operations.
Data : G_DOCK1 TYPE REF TO CL_GUI_DOCKING_CONTAINER,
IF CCON IS INITIAL. (ccon is container name )
*Check whether the program is run in batch or foreground
IF CL_GUI_ALV_GRID=>OFFLINE( ) IS INITIAL.
*Run in foreground
CREATE OBJECT CCON
EXPORTING
CONTAINER_NAME = 'CON1'.
CREATE OBJECT GRID1
EXPORTING
I_PARENT = parent_1.
ELSE.
*Run in background
CREATE OBJECT GRID1
EXPORTING
I_PARENT = G_DOCK1.
ENDIF.
ENDIF.
B&R,
Saravana.S -
How can I set JTable's columns width?
Please, can anyone give me a hint.
It seems I miss something important.
I can't set the table columns to an appropriate width.
Please, help !!!In JTable you can get a TableColumn object by supplying the name of the column to the method getColumn in JTable.
JTable myTable;
TableColumn tableColumn;
// Initialise table
tableColumn = myTable.getColumn("COLUMN NAME");There are methods for the TableColumn such as
tableColumn.setPreferredWidth(int);
tableColumn.setMaxWidth(int);
tableColumn.setMinWidth(int);
which all deal with setting up the width of the column in terms of pixel width.
You can look up more info about them in the API -
I'm using RoboHelp 8 and have a WebHelp project in which I'd like the output to auto-hide the TOC, allowing the user to click to open it if needed. There doesn't appear to be an option for that. Instead, the user can currently choose to close it, but it defaults to Open. Any ideas on how I might accomplish this?
Thanks in advance for your help!Hi there
You might also check out my Skinny on Skins file. (freely available at the link below)
Click here to view
There are some ways outlined in it.
Cheers... Rick
Helpful and Handy Links
RoboHelp Wish Form/Bug Reporting Form
Begin learning RoboHelp HTML 7, 8 or 9 within the day!
Adobe Certified RoboHelp HTML Training
SorcerStone Blog
RoboHelp eBooks -
How can I iterate over the columns of a REF CURSOR?
I have the following situation:
DECLARE
text VARCHAR2 (100) := '';
TYPE gen_cursor is ref cursor;
c_gen gen_cursor;
CURSOR c_tmp
IS
SELECT *
FROM CROSS_TBL
ORDER BY sn;
BEGIN
FOR tmp IN c_tmp
LOOP
text := 'select * from ' || tmp.table_name || ' where seqnum = ' || tmp.sn;
OPEN c_gen FOR text;
-- here I want to iterate over the columns of c_gen
-- c_gen will have different number of columns every time,
-- because we select from a different table
-- I have more than 500 tables, so I cannot define strong REF CURSOR types!
-- I need something like
l := c_gen.columns.length;
for c in c_gen.columns[1]..c_gen.columns[l]
LOOP
-- do something with the column value
END LOOP;
END LOOP;
END;As you can see from the comments in the code, I couln'd find any examples on the internet with weak REF CURSORS and selecting from many tables.
What I found was:
CREATE PACKAGE admin_data AS
TYPE gencurtyp IS REF CURSOR;
PROCEDURE open_cv (generic_cv IN OUT gencurtyp, choice INT);
END admin_data;
CREATE PACKAGE BODY admin_data AS
PROCEDURE open_cv (generic_cv IN OUT gencurtyp, choice INT) IS
BEGIN
IF choice = 1 THEN
OPEN generic_cv FOR SELECT * FROM employees;
ELSIF choice = 2 THEN
OPEN generic_cv FOR SELECT * FROM departments;
ELSIF choice = 3 THEN
OPEN generic_cv FOR SELECT * FROM jobs;
END IF;
END;
END admin_data;
/But they have only 3 tables here and I have like 500. What can I do here?
Thanks in advance for any help!The issue here is that you don't know your columns at design time (which is generally considered bad design practice anyway).
In 10g or before, you would have to use the DBMS_SQL package to be able to iterate over each of the columns that are parsed from the query... e.g.
CREATE OR REPLACE PROCEDURE run_query(p_sql IN VARCHAR2) IS
v_v_val VARCHAR2(4000);
v_n_val NUMBER;
v_d_val DATE;
v_ret NUMBER;
c NUMBER;
d NUMBER;
col_cnt INTEGER;
f BOOLEAN;
rec_tab DBMS_SQL.DESC_TAB;
col_num NUMBER;
v_rowcount NUMBER := 0;
BEGIN
-- create a cursor
c := DBMS_SQL.OPEN_CURSOR;
-- parse the SQL statement into the cursor
DBMS_SQL.PARSE(c, p_sql, DBMS_SQL.NATIVE);
-- execute the cursor
d := DBMS_SQL.EXECUTE(c);
-- Describe the columns returned by the SQL statement
DBMS_SQL.DESCRIBE_COLUMNS(c, col_cnt, rec_tab);
-- Bind local return variables to the various columns based on their types
FOR j in 1..col_cnt
LOOP
CASE rec_tab(j).col_type
WHEN 1 THEN DBMS_SQL.DEFINE_COLUMN(c,j,v_v_val,2000); -- Varchar2
WHEN 2 THEN DBMS_SQL.DEFINE_COLUMN(c,j,v_n_val); -- Number
WHEN 12 THEN DBMS_SQL.DEFINE_COLUMN(c,j,v_d_val); -- Date
ELSE
DBMS_SQL.DEFINE_COLUMN(c,j,v_v_val,2000); -- Any other type return as varchar2
END CASE;
END LOOP;
-- Display what columns are being returned...
DBMS_OUTPUT.PUT_LINE('-- Columns --');
FOR j in 1..col_cnt
LOOP
DBMS_OUTPUT.PUT_LINE(rec_tab(j).col_name||' - '||case rec_tab(j).col_type when 1 then 'VARCHAR2'
when 2 then 'NUMBER'
when 12 then 'DATE'
else 'Other' end);
END LOOP;
DBMS_OUTPUT.PUT_LINE('-------------');
-- This part outputs the DATA
LOOP
-- Fetch a row of data through the cursor
v_ret := DBMS_SQL.FETCH_ROWS(c);
-- Exit when no more rows
EXIT WHEN v_ret = 0;
v_rowcount := v_rowcount + 1;
DBMS_OUTPUT.PUT_LINE('Row: '||v_rowcount);
DBMS_OUTPUT.PUT_LINE('--------------');
-- Fetch the value of each column from the row
FOR j in 1..col_cnt
LOOP
-- Fetch each column into the correct data type based on the description of the column
CASE rec_tab(j).col_type
WHEN 1 THEN DBMS_SQL.COLUMN_VALUE(c,j,v_v_val);
DBMS_OUTPUT.PUT_LINE(rec_tab(j).col_name||' : '||v_v_val);
WHEN 2 THEN DBMS_SQL.COLUMN_VALUE(c,j,v_n_val);
DBMS_OUTPUT.PUT_LINE(rec_tab(j).col_name||' : '||v_n_val);
WHEN 12 THEN DBMS_SQL.COLUMN_VALUE(c,j,v_d_val);
DBMS_OUTPUT.PUT_LINE(rec_tab(j).col_name||' : '||to_char(v_d_val,'DD/MM/YYYY HH24:MI:SS'));
ELSE
DBMS_SQL.COLUMN_VALUE(c,j,v_v_val);
DBMS_OUTPUT.PUT_LINE(rec_tab(j).col_name||' : '||v_v_val);
END CASE;
END LOOP;
DBMS_OUTPUT.PUT_LINE('--------------');
END LOOP;
-- Close the cursor now we have finished with it
DBMS_SQL.CLOSE_CURSOR(c);
END;
SQL> exec run_query('select empno, ename, deptno, sal from emp where deptno = 10');
-- Columns --
EMPNO - NUMBER
ENAME - VARCHAR2
DEPTNO - NUMBER
SAL - NUMBER
Row: 1
EMPNO : 7782
ENAME : CLARK
DEPTNO : 10
SAL : 2450
Row: 2
EMPNO : 7839
ENAME : KING
DEPTNO : 10
SAL : 5000
Row: 3
EMPNO : 7934
ENAME : MILLER
DEPTNO : 10
SAL : 1300
PL/SQL procedure successfully completed.
SQL> exec run_query('select * from emp where deptno = 10');
-- Columns --
EMPNO - NUMBER
ENAME - VARCHAR2
JOB - VARCHAR2
MGR - NUMBER
HIREDATE - DATE
SAL - NUMBER
COMM - NUMBER
DEPTNO - NUMBER
Row: 1
EMPNO : 7782
ENAME : CLARK
JOB : MANAGER
MGR : 7839
HIREDATE : 09/06/1981 00:00:00
SAL : 2450
COMM :
DEPTNO : 10
Row: 2
EMPNO : 7839
ENAME : KING
JOB : PRESIDENT
MGR :
HIREDATE : 17/11/1981 00:00:00
SAL : 5000
COMM :
DEPTNO : 10
Row: 3
EMPNO : 7934
ENAME : MILLER
JOB : CLERK
MGR : 7782
HIREDATE : 23/01/1982 00:00:00
SAL : 1300
COMM :
DEPTNO : 10
PL/SQL procedure successfully completed.
SQL> exec run_query('select * from dept where deptno = 10');
-- Columns --
DEPTNO - NUMBER
DNAME - VARCHAR2
LOC - VARCHAR2
Row: 1
DEPTNO : 10
DNAME : ACCOUNTING
LOC : NEW YORK
PL/SQL procedure successfully completed.
SQL>From 11g onwards, you can create your query as a REF_CURSOR, but then you would still have to use the DBMS_SQL package with it's new functions to turn the refcursor into a dbms_sql cursor so that you can then describe the columns in the same way.
http://technology.amis.nl/blog/2332/oracle-11g-describing-a-refcursor
Welcome to the issues that are common when you start to attempt to create dynamic code. If your design isn't specific then your code can't be either and you end up creating more work in the coding whilst reducing the work in the design. ;) -
How can I list all the column names of a table by programming?
Hi,
Now I want to write an function which has the following features:
Firstly, The function was given a parameter as table name.
Then, it will lists all the columns names of the table.
e.g
table: person
---firstName------lastName----+
Michale Jackson
We can get the columns 'firstname' and 'lastName' by calling the function with table name 'person'.
And I also wonder that where I can get reference book or any other materials?
Thanks.
Edited by: wenjing wang on Feb 15, 2008 6:42 AM
Edited by: wenjing wang on Feb 15, 2008 6:57 AMhi,
hope the below code helps u. Just take the headee which contains the field name and split it like below and compare it with the field name u want here 'last name'.
here,
'First name' will be in wt_filedata1 and remaining field names in wt_filedata2, so 'do' continues.
c_tab must be the separator, either , or + or tab etc..
CODE:
read table person into wl_header index 1.
do.
split wl_header at c_tab into: wt_filedata1 wt_filedata2.
if wt_filedata1 <> 'lastname'.
cnt1 = cnt1 + 1.
wl_header = wt_filedata2.
else.
exit.
endif.
enddo.
Please reward if it is useful.
regards,
sri -
How could i listen to the column width changed event of a tableview
I really want to do some painting when the column is resized manually.
but it seems that there's not a column reszie event in javafx, is there?TableColumn dateCol = new TableColumn("Date");
dateCol.setCellValueFactory(new PropertyValueFactory("longrowid"));
dateCol.widthProperty().addListener(new ChangeListener(){
@Override public void changed(ObservableValue o,Object oldVal,
Object newVal){
System.out.println("Width property has changed!");
}); -
How can I turn off the variable width font when writing a message?
I have set up my email message file to use Arial 14 font. When starting a message (either original or reply) it defaults to this font. However, if at any time I move the curser with the mouse, mouse pad, the end key or an arrow key to a location to the right or below the text already typed, it automatically changes to the "variable width" font.
This requires me to manually change the font back to Arial, or backspace back to the last text typed with Arial Very, very annoying.Firefox doesn't do email, it's a web browser.
If you are using Firefox to access your mail, you are using "web-mail". You need to seek support from your service provider or a forum for that service.
If your problem is with Mozilla Thunderbird, see this forum for support.
[http://www.mozillamessaging.com/en-US/support/] <br />
or this one <br />
[http://forums.mozillazine.org/viewforum.php?f=39] -
How can we update after the list displays in ALV report.
HI all sap gurus,
I have one ALV report, after executing the report list will displays there i need to update the data. please give me answer without oops concept.
thanks,
reddyYOu need to make some fields editable in order to update the data.
for that you should set the EDIT = 'X' in the field catalog for that column.
Regards,
Ravi -
How to wrap a Column (Increase/Decrease column width) in Interactive Report
Hi,
I have a Interactive Report and I want to wrap the column values.
Also want to increase/decrease width of the columns..
I have 2 columns say.. Description and List
List - aaaaaaa, bbbbbbb, hhhhhhh, nnnnnnn, 222222, 55555555, 77777777, ..... // list of values are seperated by ,
// 1. want to wrap the values ..I mean to decrease the width
Descriptiopn - sdgssdjkllkkkkkkkk // -- here I want to increase the width of column
dgdggdfgdfgdgg
dfgdfgdfdfggfdg
dgdgdgdgdgdf2ndly for the List Column, can I put the sepearte values in each Line (values are seperated by , here) - ROW will only one.
For each ROW, I want to display List column as shown below.
List - aaaaaaa
bbbbbbb
hhhhhhh
nnnnnnn
222222
IS this possible in Interactive Report??
Thanks,
Deepak
Edited by: Deepak_J on Feb 23, 2010 4:14 PMActually, I want to increase/decrease the column width in Interactive Report.
As shown the in the example of Description field...it's coming in 4-5 lines.
I want to increase the width of Description column..so that it should come only in 2 lines..
thanks,
deepak
Edited by: Deepak_J on Feb 23, 2010 4:32 PM -
Hi,
I am setting the column width of main report and that column is bounded with the sub report which contain some data.
But if width is exceeded other than sub report data that width is showing as white space block.
It should be showing as normal header in gray shade.
Please provide the solution for this. see the screen attached.
ThanksHi Raj,
According to your description, you want to show the sub report without any white space in the textbox. Right?
In Reporting Services, when we display a sub report in a textbox, this textbox will always show the whole sub report area. If the textbox is smaller than the report area, this textbox will extend automatically to fit the size of the sub report. Otherwise,
it will has white space inside of the textbox. And if you have white space in your sub report, it will also be displayed in the textbox. So you may need to adjust the sub report size to make it fitted in main report.
Reference:
Subreports (Report Builder and SSRS)
If you have any feedback on our support, please click
here.
Best Regards,
Simon Hou (Pactera) -
Can't figure out how to maximize the space on the page by increasing the column width
Trouble with pages app:
can't figure out how to maximize the space on the page by increasing the column width
I have 3 columns and they have spaces btw them that I cannot close the gap on.Whatever the version, you can click on the gutter figure and edit it.
Click once on the column and a second time on the Gutter measurement.
Peter -
How can I reduce the column width in a spreadsheet according to the text?
Hi,
I added a spreadsheet to a pages document and now I want to reduce the column width so that it fits the content (text).
I tried it the other way around: I added very small columns and then chose the adjust-automatically-option in informations. This worked, the columns became broader and matched the text.
Now I got a lot of spreadsheets which columns are too broad. When choosing adjust-automatically just nothing happens. What can I do?
Sorry if this sounds a little weird, I'm using English seldom at time and don't know which words to choose to describe my problem properly. Hope someone can help me nevertheless?
SarahHi Sarah,
In Pages, the table Autosize feature pertains to Row Height, not Column Width. Numbers has more Table sizing options than Pages does, so you might want to consider looking into doing your work in Numbers.
In Pages, there are slight differences in how tables behave depending on whether they are Inline or Floating. You might want to experiment with that. Long tables, however, must be Inline.
Jerry -
How can i set the column width in the jtable?
how can i set the column width in the jtable?
can anybody send me a simple example??TableColumn column = table.getColumnModel().getColumn( columnIndex );
column.setWidth( desiredColumnWidth);
column.setMinWidth( desiredMinColumnWidth);
column.setMaxWidth( desiredMaxColumnWidth);
Maybe you are looking for
-
I can not play the sequence in preview mode. How do I fix this issue?
Each frame loads in the preview window when highlighted, but I can not play the sequence.
-
Please help me: Failed 8310 OS update to OS 4.5 via Desktop Manager
Hello BB Community, As of this morning, I can't use my Blackberry curve 8310......for anything. My problems started just as I was about to do a routine USB cable sync between my BB and Outlook. I was informed by Desktop Manager v 4.7 that OS 4.5 is a
-
OS Version: Microsoft Windows 7 Home Premium, Service Pack 1, 64 bit Processor: AMD A8-3820 APU with Radeon(tm) HD Graphics, AMD64 Family 18 Model 1 Stepping 0 Processor Count: 4 RAM: 5844 Mb Graphics Card: AMD Radeon HD 6550D, 256 Mb Hard Drives: C:
-
How make a sql query for chart dynamically [I got it solved]
Hi , I' m in search of a method to go from a tabular form (click on a item in the record) to a chart page where the from <table> sql of the chart is varying from the item select. eg I click on emp and navigate to a page displaying the chart with a sq
-
When I purchase using iPhone iTunes, can the music be placed in my mac?
When I purchase using iPhone iTunes, can the music be placed in my mac's iTunes library. I can't drag and drop music bought using the phone from the iPhone into the computer. Any ideas? thanks t