-2

私はios開発の初心者です。必要なのは、出発点を現在の場所として設定することですか?

- (void)loadView {
    UIView *contentView = [[UIView alloc] initWithFrame:CGRectMake(0.0f, 0.0f, 320.0f,   372.0f)];
    self.view = contentView;


    routeMapView = [[MKMapView alloc] initWithFrame:contentView.frame];
    routeMapView.delegate = self;
    routeMapView.showsUserLocation = YES;
    [contentView addSubview:routeMapView];



    routeOverlayView = [[UICRouteOverlayMapView alloc] initWithMapView:routeMapView];

    diretions = [UICGDirections sharedDirections];
    diretions.delegate = self;

}

- (void)viewDidLoad 
{
    [super viewDidLoad];

    CLLocationCoordinate2D sOri,sDest;



    startPoint=@"";
    endPoint= @"34 Jalan Yew, 55100 Kuala Lumpur, Wilayah Persekutuan Kuala Lumpur, Malaysia";

}
4

1 に答える 1

0

MKMapView のドキュメントはこちらにあります。 マップ部分の可視部分を操作することが、あなたが探しているものです。

于 2012-11-21T02:47:48.900 に答える