if i kept my progress bar out side of UIScrollView i am getting some x & y axis (like (110,250)), if i kept that progress bar in my UIScrollView i am getting different x & y axises (like (9,100)).
my requirement is i have to put my progress bar in UIScrollView but i want to know the x & y axis of progress bar outside the UIScrollview.
i.e my progress bar origins has to calculate with respect to UIView not respect to Scrollview
give me the solution please.
UIView can convert rects from one coordinate space to another so long as they have a common parent view (even the window). So, for example:
There are several methods that will convert points or rects from or to another view:
Note that the rect can be anything (doesn’t need to be a particular view’s frame). All the method does is convert from one coordinate space to another.
Also, to find the coordinate of a view on the screen (or the main window) you can set the “toView:” to nil: