/    Sign up×
Community /Pin to ProfileBookmark

Activewidgets style datagrid…

Hi. Please check out the data grid @ [url]http://www.activewidgets.com/grid/[/url]
Download the free trial version from [url]http://www.activewidgets.com/download/activewidgets-2.0.0-trial.zip[/url]. It’s easier to work with.

Alright now, I’ve been going crazy trying to figure out how they’ve done the scrolling bit, with the fixed headers & column. If you look at the DOM, you’ll notice that it’s somewhat like this…

[CODE]
span (class “aw-grid-box”)
|
–> span (class “aw-scroll-bars”)
|
–> span (class “aw-bars-box”)
| |
| –> span (class “aw-bars-spacer”)
|
–> span (class “aw-bars-content”)
[/CODE]

Looking at the CSS stylesheet…

[code]
.aw-bars-content {display:block;position:absolute;overflow:hidden;top:0px;left:0px;bottom:20px;right:20px}
[/code]

^ the bottom & left: 20px explains how the content portion doesn’t overlap with the scrollbars. But if you notice, the overflow is hidden.

Now, looking at the style for aw-bars-box…

[code]
.aw-bars-box {display:block;position:absolute;overflow:scroll;top:0px;left:0px;width:100%;height:100%}
[/code]

This is the box with the scrollbars which, when scrolled, scrolls the aw-bars-content span (I think)…. for the life of me, I cannot figure out how they have done this. Obviously, there’s some real clever trickery involved. Can anyone shed more light on this? The aw-bars-spacer dynamically resizes itself whenever you resize any column.

Also, it would be nice if someone can figure out how they’ve implemented the resizable columns. :p

I’m going freakin’ mad…. somebody PLEASE help me out here. Cheers!

to post a comment
CSS

2 Comments(s)

Copy linkTweet thisAlerts:
@ax0rzauthorMar 26.2006 — *bump*

nobody knows how this can be achieved??? ?
Copy linkTweet thisAlerts:
@ray326Mar 26.2006 — Prolly no other users here of that widget. The great thing about using components is you don't have to know how they work as long as they work correctly. Is there a problem with this one or are you just trying to reverse engineer it?
×

Success!

Help @ax0rz spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.15,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...