The FileWritev function writes the specified attribute on the item into the specified file on the MVSP Server.


Namespace: rocketsoftware.MVSP
Assembly: RocketMVSP (in RocketMVSP.dll)

Syntax

Visual Basic (Declaration)
Public Function FileWritev( _ 
   ByVal filePath As String,  _ 
   ByVal itemId As String,  _ 
   ByVal attributeBody As String,  _ 
   ByVal attribute As Integer _ 
) As Boolean
C#
public bool FileWritev(
   string filePath,
   string itemId,
   string attributeBody,
   int attribute
)
C++
public:
 bool FileWritev(
   String filePath,
   String itemId,
   String attributeBody,
   int attribute
) sealed 
J#
public bool FileWritev(
   string filePath,
   string itemId,
   string attributeBody,
   int attribute
)
JScript
public  function FileWritev(
   filePath : String,
   itemId : String,
   attributeBody : String,
   attribute : int
) : bool

Parameters

filePath
is the name of the file that you wish to write the item to
itemId
is the Itemid that you wish to write
attributeBody
is the item data
attribute
is the attribute number to update

Return Value

True

Remarks

If the item could not be written then statuscode and statusmessage properties will be set with the correct error message number and text

Example connects and writes a record 100 to the CUSTOMERS file

 Copy Code
 Dim returncode as boolean
 Dim mvsp as new rocketsoftware.MVSP.Pick
 Dim params as string = ""
 Dim itemid as string = ""
 Dim attbody as string = ""
 Dim am as string = chr(254)
 returncode = mvsp.Connect("localhost",9000,"dm","")
 If returncode = True then
    returncode = mvsp.Logto("MVDEMO","")
    If returncode = True then
       itemid = "100" ' Itemid
       attbody = "New York"
       returncode = mvsp.FileWritev("CUSTOMERS", itemid, attbody,3)       
    End if
 End if
 returncode = mvsp.CloseConnection()
 

See Also