在UIScrollView中进行分页是一个很棒的功能,我需要的是将分页设置为较小的距离,例如我希望我的UIScrollView页面的大小小于UIScrollView的帧宽.谢谢
我推ViewController它含有不太多的意见,UIScrollView这里面包含10次,我有一个单身ViewController,没有再次释放和分配一次又一次地推ViewController,所以所有的事情,我在做viewDidLoad(),和viewWillAppear(),但动画是缓慢的,波涛汹涌,它可能是什么?
我想从我的应用程序中撰写一条消息,我可以添加一张照片,例如:我在iPhone中输入了我的相册并打开了一张照片,我可以点击选项,然后在彩信标签上,照片将添加到一条消息中我可以把它发送给我想要的任何联系人.我想要的是,当我点击我的应用程序上的按钮时,将打开一个消息窗口,其中包含来自我在XCode中的资源的照片,我该怎么做?
当我在键盘外触摸时,我没有想出隐藏键盘的方法,如果我在键盘外面点击,是否有任何可能隐藏键盘的事件.谢谢
我正在尝试向UIKeyboadnumpad添加一个"完成"按钮,但没有成功.我的代码有什么问题?
键盘没有完成按钮
@implementation DemoViewController
- (void)loadView {
self.view = [[UIView alloc] initWithFrame:[UIScreen mainScreen].applicationFrame];
self.view.backgroundColor = [UIColor groupTableViewBackgroundColor];
textField = [[UITextField alloc] initWithFrame:CGRectMake(10, 200, 300, 26)];
textField.borderStyle = UITextBorderStyleRoundedRect;
textField.keyboardType = UIKeyboardTypeNumberPad;
textField.returnKeyType = UIReturnKeyDone;
textField.textAlignment = UITextAlignmentLeft;
textField.text = @"12345";
[self.view addSubview:textField];
[[NSNotificationCenter defaultCenter] addObserver:self
selector:@selector(keyboardWillShow:)
name:UIKeyboardWillShowNotification
object:nil];
}
- (void)keyboardWillShow:(NSNotification *)note {
// create custom button
UIButton *doneButton = [UIButton buttonWithType:UIButtonTypeCustom];
doneButton.frame = CGRectMake(0, 163, 106, 53);
doneButton.adjustsImageWhenHighlighted = NO;
[doneButton setImage:[UIImage imageNamed:@"DoneUp.png"] forState:UIControlStateNormal];
[doneButton setImage:[UIImage imageNamed:@"DoneDown.png"] forState:UIControlStateHighlighted];
[doneButton …Run Code Online (Sandbox Code Playgroud) 我正在使用我的[[UIDevice currentDevice] uniqueIdentifier]所有应用程序,Apple不再允许使用它uniqueIdentifier.我需要一些东西来代替uniqueIdentifier我用来识别用户的东西,即使用户删除了应用程序并再次安装它,(并且还得到苹果批准我的应用程序).
谢谢
我想改变image of的buttons的UIActionSheet,我有images每个button了,我希望每个button显示image我想要的.我在网上搜索了我找到了很多答案,但是他们没有用.
这是初始化的 UIActionSheet
-(IBAction)showActionSheet:(id)sender {
UIActionSheet *popupQuery = [[UIActionSheet alloc] initWithTitle:@"title" delegate:self cancelButtonTitle:@"Cancel Button" destructiveButtonTitle:nil otherButtonTitles:@"Other Button 1", @"Other Button 2", nil];
popupQuery.actionSheetStyle = UIActionSheetStyleDefault;
[popupQuery showInView:self.view];
[popupQuery release];
}
Run Code Online (Sandbox Code Playgroud) Reachability *r = [Reachability reachabilityWithHostName:@"www.google.com"];
这条线在设备上工作正常,但在模拟器上我崩溃了:
*由于未捕获的异常'NSInvalidArgumentException'终止应用程序,原因:'+ [Reachability reachabilityWithHostName:]:无法识别的选择器发送到类
有谁知道为什么?
我在网上搜索了很多但是我没有通过图表api在朋友墙上发帖的方法.
我想通过应用程序在朋友墙上发布消息.
UIScrollView *scrl = [[UIScrollView alloc] initWithFrame:CGRectMake(0, 0, 768,1024)];
scrl.contentSize = CGSizeMake(768 * 8, 1024);
Run Code Online (Sandbox Code Playgroud)
这是我的定义UIScrollView,我有一个填充滚动的8个图像,每个图像是一个768*1024,我怎样才能制作UIScrollView幻灯片,每个图像停留2秒并滑动到下一个图像,我该怎么做?
objective-c ×8
iphone ×7
ios ×4
ipad ×4
xcode ×4
mms ×1
reachability ×1
uikeyboard ×1
uiscrollview ×1