Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
How do I update an object dynamical from a variable. In this case i want to move a text object regarding the value in the variable "TX06TopStart".
But how should I do to put the variable in "pos.Top"
sub MoveObject
set sh = ActiveDocument.ActiveSheet
set obj = sh.SheetObjects("TX06")
set v = ActiveDocument.GetVariable("TX06TopStart")
pos = obj.GetRect
pos.Top = 185
pos.Left = 40
obj.SetRect pos
end sub
Your variable holds the value you would like for pos.Top?
If so, then you need something like:
pos.Top = CInt(v.GetContent.String)
Your variable holds the value you would like for pos.Top?
If so, then you need something like:
pos.Top = CInt(v.GetContent.String)
Hi, thanks for quick answer. It´s working as you said.