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

Object Functions

home/Knowledge Base/Technical Support/API/Client API's/VTL/VTL Client Scripts/Object Functions/ObjectSet

ObjectSet

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

Syntax

Public Function ObjectSet(chart_id As Long, name As String, prop_Id As Integer, prop_Value As Variant)As Boolean

Description

This function is used to change the values of the specified object property by a given the property id and it’s value.

Parameters

Key Description
chart_ID Chart identifier, 0 mean the current chart, the value of type Long.
Name Object key, the value of type String.
prop_Id The property that want to change its value it can beENUM_OBJECT_PROPERTY.
prop_Value The new value for a property, the value of type Variant.


Return value

Return true if successful.Otherwise, it returns false.To get the detailed error information call GetLastError() function.

Sample 1

Public Sub main()   Dim objID   objID="Text1"   AddObject Clng(0), CSTR(objID), OBJ_TEXT, Cint(0), "16/03/2013 00:00:00", 3.49672   ObjectSetText Clng(0), Cstr(objID), Cint(18), RGBcolor(0,255,0)   Text= " poivet"   Objectset Clng(0),Cstr(objID), 2 ,Cstr(Text)End Sub


Sample 2

 To update the levels of Fibonacci objects using local VTLPublic Sub main()   AddObject 0,"Fibo",7,0,GetTime(0,bars(0)-10),GetHigh(0,bars(0)-10),GetTime(0,bars(0)),GetHigh(0,bars(0))   ObjectSet 0,"Fibo",8,False   ObjectSet 0,"Fibo",7,0   ObjectSet 0,"Fibo",7,0.001   ObjectSet 0,"Fibo",7,0.010   ObjectSet 0,"Fibo",7,0.220   ObjectSet 0,"Fibo",7,0.430   ObjectSet 0,"Fibo",7,0.67   ObjectSet 0,"Fibo",7,0.88   ObjectSet 0,"Fibo",7,0.99   ObjectSet 0,"Fibo",7,1.5   ObjectSet 0,"Fibo",7,2.0   ObjectSet 0,"Fibo",9,trueEnd Sub

See Also

  • Objectget
  • ObjectGetPointByValue
  • AddObject


Back to VTL Client Script Index

Was this helpful?

Yes  No
Leave A Comment Cancel reply

  ObjectGetValueByPoint

Objectget  

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.