PDA

View Full Version : Corel and Visual Basic


Smokey Joe
08-03-2003, 03:44 AM
Does anyone have an example of a visual basic script for ANY Corel
application (if you have a choice then Photo Paint v10) that you could send
me as I'm getting a little upset at my inability to get one to work. I think
if I could see an example of one already done I would be able to work it
out. I have a shed load of photos and all I want to do is run a macro to
reduce them in size but I can't get the first bit of the command that I
need.

please email to newsforsmokey@hotmail.com

Here's what I've wrote so far

Sub redu()
Dim x As Integer
Dim openname As String
Dim savename As String
For x = 2 To 9
Let openname = ("110-100" & x & "_IMG.jpg")
Let savename = ("Venice" & x & ".jpg")
'activate relevant window
CorelPHOTOPAINT.FileOpen.openname
'resample
ActiveDocument.ImageResample 320, 240, 72, 72, True
'save file as
CorelPHOTOPAINT.FileSave.savename , 774, 0
ActiveDocument.Close
Next
For x = 10 To 99
Let openname = ("110-100" & x & "_IMG.jpg")
Let savename = ("Venice" & x & ".jpg")
'activate relevant window
CorelPHOTOPAINT.FileOpen.openname
'resample
CorelPHOTOPAINT.ActiveDocument.ImageResample 320, 240, 72, 72, True
'save file as
CorelPHOTOPAINT.FileSave.savename , 774, 0
ActiveDocument.Close
Next
End Sub


MyLounge.com Site Map
Forum: Cars, Cell Phone, Database, Games, Home Improvement, IT, Music, School, Sports, Web Design, Web Server, Weight Loss

The MyLounge.com forum is intended for informational use only and should not be relied upon and is not a substitute for any advice. The information contained on MyLounge.com are opinions and suggestions of members and is not a representation of the opinions of MyLounge.com. MyLounge.com does not warrant or vouch for the accuracy, completeness or usefulness of any postings or the qualifications of any person responding. Please consult a expert or seek the services of an attorney in your area for more accuracy on your specific situation. Please note that our forums also serve as mirrors to Usenet newsgroups. Many posts you see on our forums are made by newsgroup users who may not be members of MyLounge.com Term of Service