Thread Rating:
  • 351 Vote(s) - 2.8 Average
  • 1
  • 2
  • 3
  • 4
  • 5
vboxのデータ追加について
10-18-2012, 02:51 PM,
#4
RE: vboxのデータ追加について
先试试看吧.看有没有回答用中文提出的问题.
事实上我是在读[Curlプログラミングバイブル]这本书里面发现的一段代码.

{define-enum public ColorList
red = "brick",
white = "off",
green = "forest",
black = "night",
yellow = "sun",
blue = "true",
orange = "fruit",
purple = "royal"
}

{let box:HBox = {HBox background = "silver"}}
{for color in ColorList do
{box.add {text color = color.name, {value color.value}}}
}
{value box}

得到的结果是这样

brick
off
forest
night
sun
true
fruit
royal

当我再追加一个字段Sad完整代码如下)

{define-enum public ColorList
red = "brick",
white = "off",
green = "forest",
black = "night",
yellow = "sun",
blue = "true",
orange = "fruit",
purple = "royal"
}

{let box:VBox = {VBox background = "silver"}}
{for color in ColorList do
{box.add {text color = color.name, {value color.value}}}
}

{box.add "true"}
{value box}

的时候,显示如下:

pink
brick
off
forest
night
sun
true
fruit
royal

我如果想让[pink]这个字段在最下面显示,应该如何写?



Reply


Messages In This Thread
vboxのデータ追加について - by jianghu52 - 10-16-2012, 10:41 AM
RE: vboxのデータ追加について - by jianghu52 - 10-18-2012, 02:51 PM
RE: vboxのデータ追加について - by tdeng - 10-18-2012, 04:05 PM
RE: vboxのデータ追加について - by tdeng - 10-18-2012, 04:21 PM
RE: vboxのデータ追加について - by tdeng - 10-19-2012, 09:25 AM
Forum Jump:


Users browsing this thread:
1 Guest(s)

MyBB SQL Error

MyBB has experienced an internal SQL error and cannot continue.

SQL Error:
1017 - Can't find file: 'mybb_threadviews' (errno: 2)
Query:
INSERT INTO mybb_threadviews (tid) VALUES('641')