objective-c - ioscrash 追蹤
PHP中文网
PHP中文网 2017-05-02 09:30:32
0
1
407

crash 訊息

SEGV_ACCERR
cardloan -[HomeMoneyView refreshView] (HomeMoneyView.m:)

cardloan    -[HomeMoneyView refreshView] (HomeMoneyView.m:89)
5 cardloan    -[HomeMoneyTextFiedTablieViewCell initWithStyle:reuseIdentifier:] (HomeMoneyTextFiedTablieViewCell.m:61)
@try {
        
        // 刷新每期费用
        CGFloat monthMoney = [[MoneyLoan sharedInstance] getPeriodsFeeWithMoney:[_moneyTextField.text floatValue] periods:_periods];;
        
        NSString *approvedAmountStr = [NSString stringWithFormat:@"%@元", [NSString moneyToStrings:monthMoney]];
        NSMutableAttributedString *attrStr = [[NSMutableAttributedString alloc] initWithString:approvedAmountStr];
        [attrStr setAttributes:@{
                                 NSFontAttributeName:kFont(15.)
                                 }
                         range:NSMakeRange(attrStr.length - 3, 3)];
        _monthMoneyLabel.attributedText = attrStr;
        
        _circleLayer.progress = [_moneyTextField.text floatValue] / _moneyTextField.moneyRange.max;
        
    } @catch (NSException *exception) {
        
    } @finally {
        
    }

89行是這句, 不知道為啥會崩潰

[attrStr setAttributes:@{
                                 NSFontAttributeName:kFont(15.)
                                 }
                         range:NSMakeRange(attrStr.length - 3, 3)];
PHP中文网
PHP中文网

认证高级PHP讲师

全部回覆(1)
巴扎黑

attrStr.length

熱門教學
更多>
最新下載
更多>
網站特效
網站源碼
網站素材
前端模板
關於我們 免責聲明 Sitemap
PHP中文網:公益線上PHP培訓,幫助PHP學習者快速成長!