Hello everyone,
I'm trying to write code to import certain worksheets from an excel workbook, but I can't quite get it to work properly. Here's the code I have written for it so far:
cd "$pathin\Bank Spreadsheets\XLS spreadsheets"
foreach sheet in "Ex 1" "Ex 2" "Ex 3" "Ex 5" "Ex 6" "Ex 8" "Ex 9" "EX 10" "EX 11" "EX 12" {
import excel using "$pathin\Bank Spreadsheets\XLS spreadsheets\Caliber Home Loans-30992_FUP Findings Exhibits.xls", sheet("`sheet'") cellrange(A5) firstrow clear
save file_`sheet', replace
}
Unfortunately the syntax error that keeps popping up says "invalid '1'. I've tried checking the spacing and the naming of the sheets, but nothing seems to work. Any help would be great, thanks!
Related Posts with Import Excel Loop issues
Chi square goodness of fit I have performed chi square goodness of fit test as shown below. Now, I want to test which catego…
how to represent estimates for covariates using MataI have a regression model using discrete time hazard regression. And I wanted to study the effect of…
Panel table, initial value as regressorDear all, I would like to examine the effect of initial leverage ratio on leverage ratio. I've got a…
Overlay two lowess-functions?Hello, everyone, is there a method to display (overlay) two lowess-functions at the same time in one…
Please can someone helpHi, having to use STATA as an Economics Undergrad for Economics to write my dissertation and keep c…
Subscribe to:
Post Comments (Atom)
0 Response to Import Excel Loop issues
Post a Comment