• Libraries
  • Shop
  • Doc
  • Free Modbus
  • Support
  • Login
FieldTalk Modbus Master Library for .NET
FieldTalk Modbus Master Library for .NET
Namespaces
FieldTalk.Modbus.Master
MbusMasterFunctions Class
MbusMasterFunctions Methods
writeFileRecord Method
writeFileRecord Method (Int32, MbusMasterFunctions.FileSubRequest[])
writeFileRecord Method (Int32, Int32, Int32, Int32, Int16[])
Click or drag to resizeClick or drag to resize

MbusMasterFunctionswriteFileRecord Method (Int32, Int32, Int32, Int32, Int16)

Modbus function 21, Write File Record.

Namespace:  FieldTalk.Modbus.Master
Assembly:  FieldTalk.Modbus.Master (in FieldTalk.Modbus.Master.dll) Version: 2.15.2-eval+3d8362b4bb861c05760d48b11d303e954bb8597c
Syntax
C#
VB
C++
Copy
public int writeFileRecord(
	int slaveAddr,
	int refType,
	int fileNo,
	int recordNo,
	short[] recordArr
)
Public Function writeFileRecord ( 
	slaveAddr As Integer,
	refType As Integer,
	fileNo As Integer,
	recordNo As Integer,
	recordArr As Short()
) As Integer
public:
int writeFileRecord(
	int slaveAddr, 
	int refType, 
	int fileNo, 
	int recordNo, 
	array<short>^ recordArr
)

Parameters

slaveAddr
Type: SystemInt32
Modbus address of slave device or unit identifier (Range: 0 - 255)
refType
Type: SystemInt32
Reference type (Must be specified as 6).
fileNo
Type: SystemInt32
File number (Range 1-65535). 3 is the input registers file, 4 is the holding registers file.
recordNo
Type: SystemInt32
Record Number (Range: 0 - 65535). The first record to write to, 0-based numbering.
recordArr
Type: SystemInt16
Buffer with the data to be sent. (Range 1-122)

Return Value

Type: Int32
BusProtocolErrors.FTALK_SUCCESS on success or error code. See BusProtocolErrors for possible error codes.
Remarks
Performs a file record write for a single subrequest.
Note Note
No broadcast supported
See Also

Reference

MbusMasterFunctions Class
writeFileRecord Overload
FieldTalk.Modbus.Master Namespace
FieldTalk Modbus Master Library for .NET
Library version 2.15.2
Speak to the Experts
Modbus Organization Member logo

We are member of the Modbus Organization, Inc.

Buy with Confidence
30-day money back guarantee All our FieldTalk web sales are backed by a 30-day Money Back Guarantee.
We Accept
Bank VISA MasterCard PayPal
Customer Info
  • Info & Contact
  • Customer Login
  • Terms of Service
  • Terms of Sale
  • Privacy Policy
© 2005-2025 proconX Pty Ltd. All rights reserved. proconX and FieldTalk are trademarks of proconX Pty Ltd.
All other trademarks and registered trademarks appearing on www.modbusdriver.com are the property of their respective owners.