Warning: file_get_contents(/data/phpspider/zhask/data//catemap/5/objective-c/22.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/perl/11.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Ios 如何设置DDPageControl的特定位置?_Ios_Objective C_Iphone - Fatal编程技术网

Ios 如何设置DDPageControl的特定位置?

Ios 如何设置DDPageControl的特定位置?,ios,objective-c,iphone,Ios,Objective C,Iphone,我在我的项目中使用DDPageControl,但我无法将DDPageControl放置在UIView中的特定位置,我尝试使用initWithFrame方法初始化它,但它仍然没有显示在我的主UIView中的预期位置,因此如何将其设置在任何指定位置。提前谢谢。试试这个 [pageControl setCenter: CGPointMake(self.view.center.x, self.view.bounds.size.height-30.0f)] ; 你能详细解释一下吗?我是新来的!设置中心方

我在我的项目中使用DDPageControl,但我无法将DDPageControl放置在UIView中的特定位置,我尝试使用initWithFrame方法初始化它,但它仍然没有显示在我的主UIView中的预期位置,因此如何将其设置在任何指定位置。提前谢谢。

试试这个

[pageControl setCenter: CGPointMake(self.view.center.x, self.view.bounds.size.height-30.0f)] ;

你能详细解释一下吗?我是新来的!设置中心方法用于设置页面控件在视图中的位置。所以只需设置x点和y点。好的,谢谢Gaurav Parmar