Margin-Top Attribute | Internet Development Index |
Specifies the top edge of the shape's containing rectangle relative to the shape anchor. Read/write String.
Applies To
Tag Syntax
<v:element margin-top="expression">
Script Syntax
element.margin-top="expression"
expression=element.margin-top
Remarks
The Margin-Top attribute is similar to the standard HTML Margin-Top attribute used with style sheets.
Note that margintop is used instead of margin-top for scripting. Also note that if the position is absolute, the margin will not appear to change.
This property is used instead of Top for shapes in Microsoft Word and Microsoft Excel that are floating in a position relative to an anchor point.
Values include:
| Value | Description |
| Auto | Default position of an element in the flow of the page. |
| units | Default. A number with an absolute units designator (cm, mm, in, pt, pc, or px) or a relative units designator (em or ex). If no units are given, pixels (px) is assumed. The default value is 0. |
| percentage | Value expressed as a percentage of the parent object's height. |
VML Standard Attribute
See Also
Example
The top margin is set to 25 pixels.
<v:rect id=myrect fillcolor="red" style="position:relative;top:1;left:1;width:20;height:20;margin-top:25px"> </v:rect>
Margin-Top Attribute Example. (Requires Microsoft Internet Explorer 5 or greater.)
香格里拉县| 湘乡市| 库伦旗| 博乐市| 蒲江县| 芜湖市| 楚雄市| 沙田区| 瓦房店市| 理塘县| 闻喜县| 广德县| 华阴市| 东平县| 将乐县| 蕲春县| 南雄市| 革吉县| 静宁县| 乌拉特后旗| 黄大仙区| 通河县| 海盐县| 安福县| 会昌县| 宿松县| 阳信县| 临海市| 东乡| 城固县| 上蔡县| 阳信县| 荃湾区| 梁平县| 从化市| 静乐县| 梅州市| 瓦房店市| 吴旗县| 阿拉善盟| 浦县|