Page 1 of 1

GetPropertyValue In VBScript

Posted: Sun Oct 17, 2004 12:37 am
by spike5884
Below is a code sniplet from the script I am trying to run.

Here are my thoughts: A Task sets the CameraToActivate property in the CamActivate Null Device. This value is the same as the name of the Script Device. The Task then starts the Script Device. Basically I am trying to have the one generic script defined in multiple Script Devices.


Code: Select all

Camera = GetPropertyValue("CamActivate.CameraToActivate")
Outpath = GetPropertyValue(Trim(Camera) & ".OutputPath")


Is this possible?? Right now I am getting a syntax error during the compile. I am hoping it is just that I don't have the right syntax.



Thanks,

Scott J.

Posted: Sun Oct 17, 2004 9:46 am
by ScottBot
Scott,



I'm not sure what GetPropertyValue(Trim(Camera) & ".OutputPath") is trying to do. I don't think you want to append ".OutputPath" to the name of the Property Value you are trying to get. Maybe GetPropertyValue(Trim(Camera) ) & ".OutputPath" is what you want? I'm not sure why you want to append the ".OutputPath" string either.

Posted: Sun Oct 17, 2004 11:19 am
by spike5884
Never mind.. :oops: My bad. I was looking at the syntax error wrong. Fixed that and all is well again. :P



Thanks,

Scott J