Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Paste in Adobe photoshop
#5
Hi,

find below the text of the macro and function which is called inside.

Cheers Luisa

--------------------------------

Macro:

int i=1
int N=100
str s
str file_name
str file_name2

------- Clean directories -----------------
del- "C:\WINDOWS\Desktop\overseas 100\files to convert\*.*"
del- "C:\WINDOWS\Desktop\overseas 100\files converted bmp\*.*"
---------- copy files in files to convert and open in adobe---------

cop "C:\WINDOWS\Desktop\overseas 100\OVERSEAS BRAND REF.psd" "C:\WINDOWS\Desktop\overseas 100\files to convert\OVERSEAS BRAND REF.psd"

--------- Input Excell file name -------------------
mes- "Excell File Name"
out "Excell file name"
inp file_name
out file_name
file_name+".xls"
file_name2=file_name
file_name2-"Microsoft Excel - "
out file_name2
file_name-"C:\WINDOWS\Desktop\overseas 100\"
out file_name

---------- Open Adobe and Excell --------
run "C:\WINDOWS\Desktop\overseas 100\files to convert\OVERSEAS BRAND REF.psd"
10
out "adobe "

run file_name
5
out "Excell"

int w1=act(win(file_name2 "XLMAIN"))
act w1
1
move_in_excell(file_name2 "C2")
3
int w3=act(win("" "PSFloatC"))

---------------- Activate Adobe -----------
g1
act w3
2
lef 69 99 w3
2
out i
dou 69 99 w3
2
act win("Adobe Photoshop" "Photoshop")
'Cv
10
out i
act w3
lef+ 69 99 w3
lef- 70 99 w3
2
out i
s=i
out s
men 33 "Adobe Photoshop"
int w4=act(win("Save As" "#32770"))
outp s
lef 374 213 w4

if(i=N)
act w1
clo w1
int w2=act(win("Microsoft Excel" "#32770"))
lef 205 90 w2
act win("Adobe Photoshop" "Photoshop")
int w5=act(win("Adobe Photoshop" "Photoshop"))
2
lef 405 91 w5
2
'Cw
4
end
else out "continuo"

------------------ Copy from Excell ----------
i=i+1
out "before jump"
out "i value="; out i
out "N/2+1"; out N/2+1
if(i=N/2+1) goto g2; else goto g3

g2
move_in_excell(file_name2 "G2")
out "going on 2nd column"
out i
goto g4


g3
out "still in first column"
act w1
2
'Y
2
dou 511 79 w1
'Cc
2
g4
out "jumped to g4"
goto g1




FUNCTION

/
function lpstr's1 str'cell
out s1
int w1=act(win(s1 "XLMAIN"))
2
'Y
1
'Cg
5
int w3=act(win("Go To" "bosa_sdm_XL9"))
outp cell
lef 136 249 w3

dou 402 82 w1
1
'Cc
2
ret


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)