With wb.AddInputGroup("form1", "ipg11", "内容")
With wb.AddButtonGroup("", "ipg12", False)
.Class = "btnht"
.Attribute = "style='padding:10px;'" .Add("btn1", "50", "button").Attribute = """
.Add("btn1", "100", "button").Attribute = """
End With
End With
生成的网页<div class="fox_h_button_group btnht">
为什么在分组上面设置这个Attribute属性就失效,没反应,Class属性没问题
Class和Attribute
所谓通过WeUI自动生成的网页,其实就是自动生成各种HTML元素。
各种HTML元素可定义的属性是很多的,但是Foxtable通过WeUI组件提供的可直接设置的属性却不多。
不过Foxtable为所有WeUI组件都提供了Class和Attribute属性,前者用于设置HTML元素的Class属性,后者用于设置HTML元素除Class之外的所有属性。
Select
Case
e.Path
Case
"test.htm"
Dim
wb
As
New
weui
wb.AddForm("","form1","test.htm")
With
wb.AddButtonGroup("form1","btngrp1")
With .Add("btn1","单击我","button")
.Class = "btnClass"
.Attribute = "style='font-style:italic;font-weight:900;'
"
End
With
End
With
e.WriteString(wb.Build)
End
Select