Solved

Regarding Scrolling

Posted on 1998-10-28
3
186 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
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

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
Need to retreive data from .TFS file exported by DVR 8 166
if loop error 4 77
twoTwo  challenge 35 87
sumHeights  challenge 17 61
Introduction: The undo support, implementing a stack. Continuing from the eigth article about sudoku.   We need a mechanism to keep track of the digits entered so as to implement an undo mechanism.  This should be a ‘Last In First Out’ collec…
Introduction: Dialogs (1) modal - maintaining the database. Continuing from the ninth article about sudoku.   You might have heard of modal and modeless dialogs.  Here with this Sudoku application will we use one of each type: a modal dialog …
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.
This tutorial demonstrates a quick way of adding group price to multiple Magento products.

743 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

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now