Solved

Regarding Scrolling

Posted on 1998-10-28
3
201 Views
Last Modified: 2013-11-20
Hai,
I have two window one is Main window ( nothing but CScrollView) and the other is Outputwindow which is nothing but CListbox ( Note: same as VC ide).
Main Window has lot of rect objects. ie I am drawing
a chart which has connected rect objects.

When I there is any error present in the outputwindow,I have to go to that particular rect object which has the error.
RectObject has logical points.

CScrollView has also Zoom facility.

I am unable to go to that particular rect ( because of normal as well zoom view).

Whether there is any function which gives the current scroll position?

Eagerly waiting for the reply.

Rajah J
0
Comment
Question by:rajahj
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 

Expert Comment

by:rakeshkalra
ID: 1323964
use GetScrollPos
0
 

Author Comment

by:rajahj
ID: 1323965
GetScrollPos doesn't return properly.
Even when my view doesn't have horizontal scroll it returns the value.
So I don't think so this function is suitable to me.

When my zoom value is less than 100( there is no horizontal and vertical scroll) then also getscrollpos returns the value.

Thanks for the eagerly reply and awaiting for more.

0
 

Accepted Solution

by:
gatkinso earned 50 total points
ID: 1323966
CPOint CScrollView::GetScrollPosition
return the horizontal and vertical positions (in logical units) of the scroll boxes as a CPoint object. Call GetScrollPosition when you need the current horizontal and vertical positions of the scroll boxes in the scroll bars. This coordinate pair corresponds to the location in the document to which the upper-left corner of the view has been scrolled.

GetScrollPosition returns values in logical units. If you want device units, use GetDeviceScrollPosition instead.

This IS the answer you are looking for (even if you don't like it).

0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
function returning CString in a regular win32 DLL 8 216
Pressing cancel button with C# UI Automation 3 104
Hibernate methods 2 88
matchUp  challenge 6 82
Introduction: Load and Save to file, Document-View interaction inside the SDI. Continuing from the second article about sudoku.   Open the project in visual studio. From the class view select CSudokuDoc and double click to open the header …
If you use Adobe Reader X it is possible you can't open OLE PDF documents in the standard. The reason is the 'save box mode' in adobe reader X. Many people think the protected Mode of adobe reader x is only to stop the write access. But this fe…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

751 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question