ASP or HTML - how to freeze columns in pivot table

Do you have a question? Post it now! No Registration Necessary.  Now with pictures!

Threaded View
Hello all!

I have created a pivot table using ASP and HTML language. I have based on a
crosstab query created in MS Access 97. My pivot table looks excellent. Is
there any possibility to freeze first three columns which are static,
because the whole report takes a lot of space and I have to scroll right to
see the rest of values, but then I cannot see the static descriptions. My
reports looks like this:

Status  |  Wage  | Target | 200441 | 200442 | 200443 | 200444 | 200445 etc
C01         1            85%     10%        20%      70%       67%
C02         4            85%     12%        32%      17%       71%

I want to freeze three columns: "Status", "Wage" and "Target". How can I
make this? The procedure of generating a pivot table, which I made in ASP is
so I don`t know if it is easy to freeze these columns.

Thank you in advance for your posts
Marcin from Poland

Re: ASP or HTML - how to freeze columns in pivot table

On Thu, 16 Dec 2004 19:47:03 +0100, "Kamyk"

Quoted text here. Click to load it

There are two ways to do this.

One, which is fairly easy, is to use frames. This is an appropriate
time to use frames.  Put the fixed part in one frame, the scroling
part in another, then just let the normal scrolling mechanism take
care of it.

Frames have a problem for you. Your database query is long and
complex, so you don't want to run it twice, once for each frame. So
instead generate it from within the frameset page and store the
results in the session object.  Then your frame pages can use this
stored content to generate their output very simply.  (the rest
requires some ASP knowledge, which you might already have, or you can
ask again).

The second way, perhaps better, is to use your own scrolling, by using
client-side Javascript and switching individual columns on and off
through CSS and the display:none; property.

This is perhaps easier, but it relies on the users having Javascript
enabled. This isn't too bad though, because you can easily make this
default to all columns being visible.

You should also use CSS @media print {} to make all the table columns
displayed for printing.
Smert' spamionam

Site Timeline