Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

187
Vistas
I want to implement select and scroll the window without touching scroll bar using javascript

Suppose an user wants to select all the content from a webpage, he/she selects and start dragging the pointer to the bottom edge of the window. Now who can we make the webpage scroll down.

about 4 years ago · Juan Pablo Isaza
1 Respuestas
Responde la pregunta

0

If someone starts scrolling the page by selecting some text then it's the responsibility of the window to scroll down. If you want to make some scrolling events then you might have to use window.scrollTo method.

function scrollWin() {
  window.scrollTo(200, 0);
}
<!DOCTYPE html>
<html>
<style>
body {
  width: 5000px;
}
</style>

<body>
<h1>The Window Object</h1>
<h2>The scrollTo() Method</h2>

<p>Click to scroll the document.</p>

<button onclick="scrollWin()" style="position:fixed">Scroll to 200 horizontally!</button><br><br>


</body>
</html>

about 4 years ago · Juan Pablo Isaza Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda