情報のブロックを含むスクロールビューがあります。私が探している関数の例はです。..ボタンAボタンBボタンCScrollView-高さ3000、幅320(iOSのポートレートレイアウト)
ボタンA私はcgPointMakeを設定します[scrollViewSettingssetContentOffset:CGPointMake(0,0)];
ボタンB私はcgPointMakeを設定します[scrollViewSettingssetContentOffset:CGPointMake(0,1000)];
ボタンC私はcgPointMakeを設定します[scrollViewSettingssetContentOffset:CGPointMake(0,2000)];
スクロール制限またはスクロール範囲の設定に関して、これを超えるコードはありません。私が必要なのは
ボタンAのスクロール高さの範囲はy=0からy=1000であるため、ユーザーはスクロールしてボタンBまたはCがデータを取得する場所のデータを表示できません。
ボタンBのスクロール高さの範囲はy=1000からy=2000であるため、ユーザーは上下にスクロールして、ボタンAまたはCがデータを取得するデータを表示できません。
ボタンCのスクロール高さの範囲はy=1000からy=2000であるため、ユーザーは上にスクロールしてボタンAまたはBがデータを取得するデータを表示できません。
これが理にかなっていることを願っています。
前もって感謝します。
これが私が各スクロールビューに使用したコードです
scrollViewMain.frame = CGRectMake(0, 54, 320,426); /*set the viewable frame of the scroll view*/
[scrollViewMain setContentSize:CGSizeMake(320,1708)]; /*set the content size of the scroll view*/
scrollViewSettings.frame = CGRectMake(0, 0, 320,426); /*set the viewable frame of the scroll view*/
[scrollViewSettings setContentSize:CGSizeMake(320,650)]; /*set the content size of the scroll view*/
scrollViewBMI.frame = CGRectMake(0, 426, 320,426); /*set the viewable frame of the scroll view*/
[scrollViewBMI setContentSize:CGSizeMake(320,570)]; /*set the content size of the scroll view*/
scrollViewBFC.frame = CGRectMake(0, 1278, 320,426); /*set the viewable frame of the scroll view*/
[scrollViewBFC setContentSize:CGSizeMake(320,568)]; /*set the content size of the scroll view*/
ViewBMR.frame = CGRectMake(0, 852, 320,426); /*set the viewable frame of the view*/