Posted 17 June 2005 - 01:55 AM
I am a new programmer and wonder if anybody could tell me what I am doing wrong. I want to set the SourceDoc property for an OLE object at runtime and am using the following code: OLE1.SourceDoc = C:\ etc. being the path followed by a backslash and the file name. I have tried it with and without quotes around everything after the =. If I have set the SourceDoc property at design time, it's fine and if I include the above code, it does something because the OLE box becomes blank. It just doesn't do what I want it to. What I am trying to accomplish is enable the user to select a particular file for the OLE box at runtime with a file box which I would pass to the property with a variable. Anyway, any help with this would be appreciated.