Link to home
Start Free TrialLog in
Avatar of jmar6729
jmar6729

asked on

Set Value Macro Problem in Form - Setting Hyperlink field

I have a form that combines a [path], [item name] and [picture number].  From this field I want to set the value of a hyperlink field, which will open the picture.  I get an error code 2766, Object doesn't contain the Automation Object.."  I think it might be better to use VBA than the macro.

I would like to do two things with VBA.
1) Set the Value of the LinkText field to the Hyperlilnk field.
2) Change the name of a picture to the LinkText (minus the [path] value.
ASKER CERTIFIED SOLUTION
Avatar of MINDSUPERB
MINDSUPERB
Flag of Kuwait image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of jmar6729
jmar6729

ASKER

Thanks, Ed.  That works great for the hyperlink.  Any idea how to use VBA to change the file name in the photo directory?  I have found and changed file names years ago but forget how to do that. (rst comes to mind :)

I will enter a [photonumber] into the form record.  Once I do that, the number is concatentated into the [photoname]. Then I need to rename the photo in the photo directory, so the hyperlink will work.

Thanks