增加字符串列表项
<h1>功能</h1>
<p>在已有的字符串列表中增加新的项。</p>
<h1>输入</h1>
<table>
<thead>
<tr>
<th>名称</th>
<th>说明</th>
<th>示例</th>
</tr>
</thead>
<tbody>
<tr>
<td>列表</td>
<td>【TList<string>】已存在的字符串列表。</td>
<td>列表(传入变量)</td>
</tr>
<tr>
<td>值</td>
<td>【字符串】要增加的字符串列表项。</td>
<td>‘55’</td>
</tr>
</tbody>
</table>
<h1>输出</h1>
<table>
<thead>
<tr>
<th>名称</th>
<th>说明</th>
<th>示例</th>
</tr>
</thead>
<tbody>
<tr>
<td>索引</td>
<td>【整型】返回要增加的字符串列表项的索引,索引从0开始。</td>
<td>索引(创建变量)</td>
</tr>
</tbody>
</table>
<h1>注意/说明</h1>
<p>1.【增加字符串列表项】函数中,要增加的字符串列表项只能在列表末尾新增字符串列表项,无法在指定的位置(索引)增加字符串列表项。
2.该函数需与【构建字符串列表】函数、【遍历循环】函数搭配使用,将构建好的字符串列表传入【增加字符串列表项】函数中,再将要增加的项插入构建好的字符串列表中,最后用【遍历循环】函数遍历出来。
3.第一个【日志消息】函数返回的是新增加的字符串列表项的索引;第二个【日志消息】函数返回的是新增字符串列表项后,所有字符串列表项的索引;第三个【日志消息】函数返回的是新增字符串列表项后,所有字符串列表项的内容。
<img src="https://www.showdoc.com.cn/server/api/attachment/visitfile/sign/6bc16fac136002a5c126dc521c716441" alt="" />
<img src="https://www.showdoc.com.cn/server/api/attachment/visitfile/sign/e6ef6a06b38f3f7b39e6838620b1db2b" alt="" />
<img src="https://www.showdoc.com.cn/server/api/attachment/visitfile/sign/a8196efa31a06535a8801297526fd45c" alt="" />
<img src="https://www.showdoc.com.cn/server/api/attachment/visitfile/sign/a9bde4861539a4703b5b74e5f9a051b0" alt="" />
<img src="https://www.showdoc.com.cn/server/api/attachment/visitfile/sign/8df956f05bdbf0e0b29ba90f7a0e79ce" alt="" /></p>
<h1>相关函数</h1>
<p>【构建字符串列表】函数、【遍历循环】函数</p>
<h1>示例/演示</h1>
<p><img src="https://www.showdoc.com.cn/server/api/attachment/visitfile/sign/c38c582768c71ca2dadbedc80927f6fa" alt="" /></p>
<h1>示例附件</h1>
<p><a href="https://www.showdoc.com.cn/server/api/attachment/visitfile/sign/61657b9ff4850769ebc5f317e2bb2cf8" title="[组件[增加字符串列表项]_20210420.db">组件[增加字符串列表项]_20210420.db</a></p>