% Usage : mat2xceldde(A)
function mat2xceldde(A)
channel = ddeinit('excel','sheet1');
if channel == 0,
  error('error intiating conversation');
end
Asize=size(A);
worksheet=sprintf('r1c1:r%dc%d',Asize);
rc = ddepoke(channel,worksheet,A);
if rc == 0,
  error('error poking data');
end
ddeterm(channel);
