我正在创建我的第一个应用程序,并对Ad Hoc配置文件和开发配置文件有一些混淆.我知道在此之前会问这个问题,但需要一些澄清和确认.
查看stackoverflow上的先前答案,我假设存在以下差异:
可以在没有iTunes的情况下安装即席版本,而必须从iTunes安装开发版本(.ipa)
在开发构建具有调试器时,调试器无法附加到Ad hoc构建
设备令牌是不同的,因为APNS使用两种模式沙箱,生产环境取决于构建是Ad hoc或开发
我有以下问题
在许多论坛上写道,Ad hoc版本上有100个用户,但没有提到如果开发版本有这样的限制.此外,每个开发人员资料或每个应用程序的限制为100个用户?
另外,只有Ad hoc构建需要在其上安装设备的UDID吗?发展构建怎么样?
请看看我是否有正确的差异,这是否会遗漏任何重要的差异,任何有关问题的信息都会有很大的帮助
我有一个包含两个UIButtons的UIview.
-(void)ViewDidLoad
{
geopointView = [[UIView alloc] initWithFrame:CGRectMake(0, 350, 120, 80)];
geopointView.backgroundColor = [UIColor greenColor];
UIButton *showGeoPointButton = [[UIButton buttonWithType:UIButtonTypeRoundedRect] retain];
showGeoPointButton.frame = CGRectMake(0, 0, 120, 40);
showGeoPointButton.titleLabel.font = [UIFont systemFontOfSize:13.0];
[showGeoPointButton setTitleColor:[UIColor blackColor] forState:UIControlStateNormal];
[showGeoPointButton addTarget:self action:@selector(showPlaces:) forControlEvents:UIControlEventTouchUpInside];
UIButton *SaveButton = [[UIButton buttonWithType:UIButtonTypeRoundedRect] retain]
SaveButton.frame = CGRectMake(0, 40, 120, 40);
SaveButton.titleLabel.font = [UIFont systemFontOfSize: 15.0];
[SaveButton setTitleColor:[UIColor blackColor] forState:UIControlStateNormal];
[SaveButton addTarget:self action:@selector(savePlacePopUp) forControlEvents:UIControlEventTouchUpInside];
[geopointView addSubview:showGeoPointButton];
[geopointView addSubview:SaveButton];
}
Run Code Online (Sandbox Code Playgroud)
我想在调用以下方法时为UIview中的幻灯片设置动画.
-(void) showAnimation
Run Code Online (Sandbox Code Playgroud)
我试着通过以下方式来做,但我看不到动画.我该怎么做?
-(void) showAnimation{
[UIView animateWithDuration:10.0 animations:^{
[self.view addSubview:geopointView]; …Run Code Online (Sandbox Code Playgroud) 我想创建具有矩形形状的Custom UIButton.为此,我使用矩形视图作为UIButton的背景,并使UI按钮背景颜色为clearcolor.但UI按钮的边界仍然存在.关于如何使边界消失的任何建议?在此先感谢您的帮助..
我有一个名为"myLocation"的CLLocation管理器.
myLocation = [[CLLocationManager alloc] init];
myLocation.desiredAccuracy = kCLLocationAccuracyBestForNavigation ;
myLocation.distanceFilter = 10 ;
myLocation.delegate=self;
locationEnabledBool = [CLLocationManager locationServicesEnabled];
if (locationEnabledBool ==NO || ( [CLLocationManager authorizationStatus] == kCLAuthorizationStatusDenied)) {
// LocationText.text = @"Location Service Disabled ";
UIAlertView *locationAlert = [[UIAlertView alloc] initWithTitle:@"Location Service Disabled"
message:@"To re-enable, please go to Settings and turn on Location Service for this app."
delegate:nil
cancelButtonTitle:@"OK"
otherButtonTitles:nil];
[locationAlert show];
[locationAlert release];
}
[myLocation startUpdatingLocation];
Run Code Online (Sandbox Code Playgroud)
和位置更新功能是
- (void)locationManager:(CLLocationManager *)manager
didUpdateToLocation:(CLLocation *)newLocation
fromLocation:(CLLocation *)oldLocation
{
NSLog(@"old location is …Run Code Online (Sandbox Code Playgroud) 直到最近我才认为只有三个选项可以设置为MKMapView mapType.
[mapView setMapType:MKMapTypeStandard];
[mapView setMapType:MKMapTypeHybrid];
[mapView setMapType:MKMapTypeSatellite];
Run Code Online (Sandbox Code Playgroud)
但正如在这个链接中所提到的,如何在iphone中的地形视图中加载Google地图,还可以通过设置获得"地形类型(未在文档中提及)"
[mapView setMapType:3];
Run Code Online (Sandbox Code Playgroud)
有趣的是地形模式允许的最大放大率与其他native模式不同.而不是上面的3我尝试整数<3但这不起作用(MapView Standard只显示类型).有谁知道是否有更多的选项设置为类型MKMapView?
提前致谢.
location = [[CLLocationManager alloc] init];
location.desiredAccuracy = kCLLocationAccuracyBestForNavigation ;
location.distanceFilter = 10 ;
location.delegate=self;
locationEnabledBool = [CLLocationManager locationServicesEnabled];
if (locationEnabledBool ==NO) {
UIAlertView *locationAlert = [[UIAlertView alloc] initWithTitle:@"Location Service Disabled"
message:@"To re-enable, please go to Settings and turn on Location Service for this app."
delegate:nil
cancelButtonTitle:@"OK"
otherButtonTitles:nil];
[locationAlert show];
[locationAlert release];
}
else
[location startUpdatingLocation];
Run Code Online (Sandbox Code Playgroud)
locationEnabledBool始终是值YES,与是否启用位置服务无关.任何身体都能帮忙吗?
我想隐藏或显示UIButton天气用户的当前位置在地图上可见.在测试代码xcode时,"User location view is NOT visible but should be. Showing...."如果用户位置在地图上不可见,我可以在"didUpdateLocation"方法中看到控制台上的meassage.如何在我的案例中使用此消息生成事件以隐藏或显示UIButton?在此先感谢您的帮助.
我有一个叫做geopointView的UIView.我想在按下按钮(myButton)时在主视图框架上为此UIview中的幻灯片设置动画.如果再次按下myButton,UIview应该滑出框架.myButton调用以下方法"optionsCalled"
-(void) optionsCalled
{
if (![[self.view subviews] containsObject:geopointView] &&checkForGeopointViewAnimation ==0) {
[self.view addSubview:geopointView];
geopointView.frame = CGRectMake(0,430,320,30);
[UIView animateWithDuration:0.3f
animations:^{
geopointView.frame = CGRectMake(0, 350, 100, 80);
}
completion:^(BOOL finished){
checkForGeopointViewAnimation = 1 ;
}];
}
if ([[self.view subviews] containsObject:geopointView] && checkForGeopointViewAnimation ==1)
{
geopointView.frame = CGRectMake(0, 350, 100, 80);
[UIView animateWithDuration:0.3f
animations:^{
geopointView.frame = CGRectMake(0,430,320,30);
}
completion:^(BOOL finished){
checkForGeopointViewAnimation = 0 ;
}];
[geopointView removeFromSuperview];
}
}
Run Code Online (Sandbox Code Playgroud)
这里checkForGeopointViewAnimation是一个全局变量,定义为确保一次不调用滑入和滑出.
此代码的问题在于UIview以动画方式滑动,但它不会为幻灯片操作设置动画.它只是从主框架消失.我是否需要在这里使用任何时间,以便延迟调用添加和删除UIview功能?
在此先感谢您的帮助
在matlab代码中,我在当前工作目录中名为"results"的文件中的特定迭代之后生成文件.当我想下次运行代码时,先前运行的文件也会出现在结果文件夹中.CI会这样做
(void) system("rm -rf results/*");
Run Code Online (Sandbox Code Playgroud)
每次代码开始执行时,如何删除文件夹"结果"的内容?谢谢.
我正在使用以下网址来获取两个地点之间的行车路线.
NSString* apiUrlStr = [NSString stringWithFormat:@"http://maps.google.com/maps?output=dragdir&saddr=%@&daddr=%@", saddr, daddr];
Run Code Online (Sandbox Code Playgroud)
在上述查询中需要做哪些更改才能获得自行车,步行或公共交通的方向以及相应的距离,两地之间所需的时间?
在此先感谢您的帮助.
我有一个UILabel应该有透明度(alpha)=.6但是UILable的Text应该有alpha = 1.这可能吗?感谢提前的任何建议......
我有几个数据文件顺序命名为'1.dat','2.dat'...,'100.dat'.我想为Gnuplot中的每个数据文件创建一个png(或任何其他类型)图像.我的终极主题是从这样生成的图像中创建一部电影,但我发现这些令人困惑的软件包,并且更愿意一步一步地完成.如何编写用于从数据文件中创建图像的脚本?谢谢.