Login
Try VertexFX
  • Home
  • Knowledgebase
  • Blog
  • Home
  • Knowledgebase
  • Blog

File Functions

home/Knowledge Base/Technical Support/API/Client API's/VTL/VTL Client Scripts/File Functions/OpenFile

OpenFile

9 views 0 Updated on December 16, 2021 hybrid-solutions

Syntax

 Public Function OpenFile(ByRef FileName As Variant, openType As ENUM_FILE_MODE) As String

Description

This function is used to open specifica file to be processed according to open type value.

Parameters

Key Description
FileName Path and name of the file to be opened, value of type String
openType Processed mode , value of typeENUM_FILE_MODE.

Return value

Returns empty string if the file has been opened else it will return the “File already open” in case the file is already open and the OpenType was FILE_OUTPUT/ FILE_APPEND , in case the OpenType was FILE_INPUT and file dose not exist it will return “File not found”

Sample

 Public Sub main() ' Open or Create File and write  Data  , finally Close it   Dim fileName  Dim fileMode  fileMode = FILE_APPEND  fileName = "C:VertexWorld.txt"   OpenFile fileName, CInt(fileMode)  FileWrite "Welcome TO VertexFx World"  CloseFile End Sub

See Also

  • NumberOfLinesInFile
  • FileExists
  • DeleteLine


Back to VTL Client Script Index

Was this helpful?

Yes  No
Leave A Comment Cancel reply

NumberOfLinesInFile  

About
VertexFX Trader has a closed-loop trading structure with Backoffice dealing desk, Client Terminals, Dedicated Hosting, White Labelling and Bridging Capabilities. Through VertexFX Risk Management Bridge...
Categories
  • Release Notes
  • Technical Support
  • VertexFX Pro Setup
  • Mobile Trader
  • Lite VertexFX Mobile Trader
Community
  • Blog
  • Media Center
Need Support?
If you need any further help, don't hesitate to send a support request to our support team.
Contact Support
  • Privacy Policy
  • Brokers Terms
  • Traders EULA
  • ISV Terms
  • Plugins EULA
  • Copyright 2023 hybridsolutions.com. All Rights Reserved.