473,396 Members | 1,864 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

scrollTo(x,y), layer NOT window, possible?

This is my second post, so please continue to be gentle.

Is it possible to somehow scroll to a position in a layer?

Something like
Expand|Select|Wrap|Line Numbers
  1. document.getElementById('div').scrollTo(x,y)
?

I have two layers (left navigation and right content) I want to scroll the content.
Aug 28 '07 #1
3 1383
acoder
16,027 Expert Mod 8TB
Try using the scrollLeft and scrollTop properties.
Aug 28 '07 #2
Try using the scrollLeft and scrollTop properties.
LOL, yes, it seems that I have to make use of it, I found that method in many function on the web, but they all use it to retrieve the values for the scrolls, and then use scrollTo to set them.

I just found out that you can use them to set the scroll also. Right under my noise...

Thanks!

*cough* This thread is now resolved...
Aug 28 '07 #3
acoder
16,027 Expert Mod 8TB
I just found out that you can use them to set the scroll also. Right under my noise...
Yes, sorry, I forgot to mention that.
*cough* This thread is now resolved...
LOL! You can put your own nice big stamp on it.
Aug 29 '07 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: Ethan | last post by:
I have a form that contains sets of checkboxes. Each set has links above it marked "Check all" and "Uncheck all". The links call JavaScript functions. Here's the problem. When you click "Check...
2
by: Ethan | last post by:
This is a clarification of a previous message, which was not expressed very well. I have a set of checkboxes near the bottom of the page and a function that checks or unchecks all of them. But when...
4
by: anna | last post by:
How to tell if a horizontal scrollbar is present? I only want to use scrollTo if horizontal scrollbar is present. window.scrollbars.visibility doesn't specify which scrollbar is present, so it...
4
by: Steve | last post by:
Hi, I'm opening a small window with window.open. I have a textarea there, and I want it to expand to fit the window as it's resized. How is this possible? Thanks, Steve
19
by: Darren | last post by:
I have a page that opens a popup window and within the window, some databse info is submitted and the window closes. It then refreshes the original window using window.opener.location.reload(). ...
5
by: junk419 | last post by:
Hi all. First of all I know pretty much nothing about Javascript :) It's just that I found a program/script that will refresh a webpage (not mine) every so often. It's called AllStock's...
1
by: heken | last post by:
I have this code embedded in a Firefox bookmark: javascript:Qr=document.getSelection();if(!Qr){void(Qr=prompt('Translate to...
18
by: ManWithNoName | last post by:
This is my first post, so be gentle. This: <body onload="window.scrollTo(x,y)"> Works fine. This:
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.