小编You*_*uri的帖子

每个例外都有必要的试用吗?

一个简单的问题,我找不到答案.Java中的每个异常都需要使用try-catch吗?或者仅适用于FileNotFoundException?

很多异常(IndexOutOfBoundException,ArithmeticException,IlligalArgumentException,NullPointerException)都表示他们不需要Exception,但是FileNotFoundException会这样做...而且我找不到答案,哪些不需要try-catch .

java exception try-catch

15
推荐指数
1
解决办法
2万
查看次数

DIV到页面的右侧

我将'导航'div(在5个按钮内)放在'#header'div中的页面右侧时出现问题."导航"div仍然位于"徽标"div旁边.

有人可以帮我把它放到页面的右侧吗?

CSS代码:

body {
background-color: #000000;
margin:0;
padding:0;
}

#header {
width: 100%;
height: 100px;
background-color: 222423;
margin-bottom: 5px
}

#logo {
float: left;
}

#navigation {
display: inline-block;
vertical-align: middle;
}

#content {
height: auto;
}

.knop {
margin-right: 7px;
margin-left: 20px;
vertical-align: middle
}

.plaatje {
position: fixed;
width: 628px;
height: 300px;
margin: -150px auto auto -319px;
top: 50%;
left: 50%;
text-align: center;

}

.DivHelper {
display: inline-block;
vertical-align: middle;
height:100%;
}
Run Code Online (Sandbox Code Playgroud)

HTML代码:

<html>
<head>
    <link typte="text/css" …
Run Code Online (Sandbox Code Playgroud)

html css

1
推荐指数
1
解决办法
6万
查看次数

标签 统计

css ×1

exception ×1

html ×1

java ×1

try-catch ×1