Quantcast
Channel: Adobe Community: Message List - Photoshop Scripting
Viewing all articles
Browse latest Browse all 27456

Help, cannot set references to Photoshop.Application in VBA

$
0
0

Hello,

 

I have used CS5 in the past and have had a well-functioning VBA program (running within Access 2010) that ran fine, opens 32-bit Photoshop, and controlled photoshop CS5 normally, allowing me to manipulate photos, read metadata, etc.  (It was my understanding that at least for CS5, scripting programs including VBA needed to run the 32 bit version of Photoshop, not the 64 bit version.)

 

I installed CS6 about 6 months ago and the VBA program continued to work just fine, provided it still opened the 32 bit version. (I had to be sure I was not running 64 bit Photoshop when I started the VBA program).  CS5 was still installed but not being used.

 

I just uninstalled CS5, leaving CS6 installed.  For some reason, this left the VBA program disrupted in that the References (which you set in the VBA code window with Tools > References) no longer appear to be valid.  I am unable to set a new Reference to Photoshop.Application and the program has become unusable.  That is, the "Available References" no longer list Adobe Photoshop CS6 Type Library or Adobe Photoshop CS6 Object Library.  I browsed to the the file C:\Program Files\Adobe\Adobe Photoshop CS6 (64 Bit)\TypeLibrary.tlb to add this reference manually.  The programs still does not compile (i.e., Dim appRef As New Photoshop.Application  causes an error "User Defined Type not defined").  I get the same failure to compile if I browse to and install a reference to the 32-bit version, C:\Program Files (x86)\Adobe\Adobe Photoshop CS6\TypeLibrary.tlb.  In the past, I also had a reference to the "Adobe Photoshop CS6 Object Library".  I have tried to manually set this to C:\Program Files (x86)\Adobe\Adobe Photoshop CS6\Photoshop.exe or to the 64 bit version of Photoshop.exe, but these files are not accepted and I do not otherwise know the file location of the Object Library. 

 

I very much need help from someone who knows how to fix this problem in transitioning from CS5 to CS6 for using VBA.

 

Thank you,

 

EGibbon


Viewing all articles
Browse latest Browse all 27456


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>