Prev: Slider - random numbers missed out
Next: mclmainFcn
From: Tassie on 20 Mar 2010 20:08 Hello, I am trying to do the same thing as Matthew and downloaded officedoc, however, when I try to open the file (using: [file,status,errMsg] = officedoc('testfile.xls', 'open', 'mode','append'); ) I get the following error messages: ??? officedoc: Undefined function or method 'actxserver' for input arguments of type 'char'. Error in ==> /Users/njhajal/Documents/MATLAB/officedoc.p>processAction at 595 Error in ==> /Users/njhajal/Documents/MATLAB/officedoc.p>officedoc at 363 Do you have any idea of what this might be? I do have a Mac, and i know that the program was not written for Macs, so was wondering if you think that this might be the problem. Thanks, Tassie "Yair Altman" <altmanyDEL(a)gmailDEL.comDEL> wrote in message <h5bb8d$gfk$1(a)fred.mathworks.com>... > "Matthew " <mml5059(a)psu.edu> wrote in message <h59sg4$66d$1(a)fred.mathworks.com>... > > > > > Yes - use officedoc on the File Exchange (http://www.mathworks.com/matlabcentral/fileexchange/15192 ) - it does this automatically in 'append' mode. > > > > > > Yair Altman > > > http://ymasoftware.com > > > > > > > Im having problems using the program, i unzipped and put all the files into my matlab folder and added > > [file,status,errMsg] = officedoc('NoseMeasure.xls', 'open', 'mode','append'); > > to my code when i want the excel file to open but i am getting an error saying the function is unrecognized > > You probably placed the officedoc files somewhere which is not in your Matlab path. Type "path" at the matlab prompt to check this, then try "which officedoc". If you still get an error after fixing this, post the error here. > > Yair
From: Yair Altman on 21 Mar 2010 02:50 "Tassie " <njh159(a)psu.edu> wrote in message <ho3o13$4h3$1(a)fred.mathworks.com>... > Hello, > > I am trying to do the same thing as Matthew and downloaded officedoc, however, when I try to open the file (using: [file,status,errMsg] = officedoc('testfile.xls', 'open', 'mode','append'); ) I get the following error messages: > > ??? officedoc: Undefined function or method 'actxserver' for input arguments of type 'char'. > > Error in ==> /Users/njhajal/Documents/MATLAB/officedoc.p>processAction at 595 > > > Error in ==> /Users/njhajal/Documents/MATLAB/officedoc.p>officedoc at 363 > > Do you have any idea of what this might be? I do have a Mac, and i know that the program was not written for Macs, so was wondering if you think that this might be the problem. Yes it is - OfficeDoc only works on Windows. Yair
From: Tassie on 21 Mar 2010 12:58 I see, thank you. Do you know of any way to do this on a Mac? Thanks, Tassie "Yair Altman" <altmanyDEL(a)gmailDEL.comDEL> wrote in message <ho4fjb$khm$1(a)fred.mathworks.com>... > "Tassie " <njh159(a)psu.edu> wrote in message <ho3o13$4h3$1(a)fred.mathworks.com>... > > Hello, > > > > I am trying to do the same thing as Matthew and downloaded officedoc, however, when I try to open the file (using: [file,status,errMsg] = officedoc('testfile.xls', 'open', 'mode','append'); ) I get the following error messages: > > > > ??? officedoc: Undefined function or method 'actxserver' for input arguments of type 'char'. > > > > Error in ==> /Users/njhajal/Documents/MATLAB/officedoc.p>processAction at 595 > > > > > > Error in ==> /Users/njhajal/Documents/MATLAB/officedoc.p>officedoc at 363 > > > > Do you have any idea of what this might be? I do have a Mac, and i know that the program was not written for Macs, so was wondering if you think that this might be the problem. > > > Yes it is - OfficeDoc only works on Windows. > Yair
From: Tassie on 24 Mar 2010 19:50 OK, I got a hold of MATLAB on a computer with Windows, and am able to get my data to write to an Excel file, but it doesn't seem to be writing to the next empty cell--instead, it keeps writing over the very first cell in the spreadsheet. Here is the code I am using: fprintf('\nvariable1=%g\n',variable1(joy_count)) variable1=variable1(joy_count) [file,status,errMsg] = officedoc('testwrite1.xls', 'open', 'mode','append'); status = officedoc(file, 'write', 'data',{variable1}); officedoc(file, 'display'); for index = 1 : 10 data = 'variable1'; status = officedoc(file, 'write', 'data', variable1); end fprintf('\nvariable2=%g\n',variable2(joy_count)) variable2=variable2(joy_count) [file,status,errMsg] = officedoc('testwrite1.xls', 'open', 'mode','append'); status = officedoc(file, 'write', 'data',{variable2}); officedoc(file, 'display'); for index = 1 : 10 data = 'variable2'; status = officedoc(file, 'write', 'data', variable2); end This code is embedded w/in another loop that is calculating these variables for different groups of data w/in a column. For example, in the data 0 0 0 1 1 0 0 0 1 1 1 1 both variables 1 and 2 would each be calculated first for the 1st group of 1's, and then for the 2nd group of 1s. Right now the "fprintf" commands give me separate values for each group of 1s in MATLAB, but I would like all of the values to be exported to an Excel file. I was thinking that Officedoc would probably be able to do this, but I seem to be missing a step... Any idea what the problem might be? Thanks so much, Tassie "Yair Altman" <altmanyDEL(a)gmailDEL.comDEL> wrote in message <ho4fjb$khm$1(a)fred.mathworks.com>... > "Tassie " <njh159(a)psu.edu> wrote in message <ho3o13$4h3$1(a)fred.mathworks.com>... > > Hello, > > > > I am trying to do the same thing as Matthew and downloaded officedoc, however, when I try to open the file (using: [file,status,errMsg] = officedoc('testfile.xls', 'open', 'mode','append'); ) I get the following error messages: > > > > ??? officedoc: Undefined function or method 'actxserver' for input arguments of type 'char'. > > > > Error in ==> /Users/njhajal/Documents/MATLAB/officedoc.p>processAction at 595 > > > > > > Error in ==> /Users/njhajal/Documents/MATLAB/officedoc.p>officedoc at 363 > > > > Do you have any idea of what this might be? I do have a Mac, and i know that the program was not written for Macs, so was wondering if you think that this might be the problem. > > > Yes it is - OfficeDoc only works on Windows. > Yair
|
Pages: 1 Prev: Slider - random numbers missed out Next: mclmainFcn |