---
title: 定义字符串填充类型
description: "定义字符串的填充类型。"
url: https://www.hikunpeng.com/document/detail/zh/kunpenghpcs/hpckit/devg/userg_hyperio_0130.html
sourcePath: /source/zh/kunpenghpcs/hpckit/devg/userg_hyperio_0130.html
indexId: 2741cf7725f00da210886448c842468a00d082e402072fbec3a90c3cccaf75b858
---
# 定义字符串填充类型

#### 函数定义

定义字符串的填充类型。

herr_t H5Tset_strpad(hid_t datatype, H5T_str_t strpad )


#### 参数

| 参数名 | 描述 | 取值范围 | 输入/输出 |
| --- | --- | --- | --- |
| datatype | 要修改的数据类型的标识符。 | 整数 | 输入 |
| strpad | 字符串填充类型。 | 非空 | 输入 |


#### 返回值

- 成功：返回非负值。
- 失败：返回负值。
