答案 0 :(得分:0)
请检查here。该链接有不同的方法来解决问题。 但是下面的代码帮助了我。
<cfloop index="i" from="0" to="#totalsegment-1#">
<cfloop query="flowQy" startrow="1" endrow="#totalsegment-1#">
<cfset newarray =ArrayNew(1)>
<cfset depthinput=structNew()>
<cfset depthinput[i] = "depthinput" & i>
<cfset arrayAppend(newarray, depthinput)>
<cfinput name="depthinput#i#" tabindex="#((i+1)*2)-1#" type="text" onfocus="this.value='';findTotal();" size="10" onblur="findTotal();" value='#depthinput[i]#' id="depthinput#i#"></cfinput></br>
</cfloop>
</cfloop>
答案 1 :(得分:0)
您可以按如下方式设置
-(void)layoutSubviews{
[super layoutSubviews];
CGRect rectStatus = [[UIApplication sharedApplication] statusBarFrame];
if (rectStatus.size.height==44.f) {
}else{
if (@available(iOS 11.0, *)) {
for ( UIView*aView in self.subviews) {
if ([NSStringFromClass(aView.classForCoder) isEqualToString:@"_UINavigationBarContentView"]) {
aView.frame = CGRectMake( 0,20,aView.frame.size.width,44);
}
else if ([NSStringFromClass(aView.classForCoder) isEqualToString:@"_UIBarBackground"]) {
aView.frame = CGRectMake(0,0,aView.frame.size.width, 64);
}
}
}
}
}