Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Opening Files on other User's Desktops
I may have made an error in judgment by asking this question again, but
having played around with it, I can state the concern properly... I have created a worksheet which has to run on various user's PC's. It takes two Do Not Call List area code files, joins them, reformats the data and then determines if any if the data is also found in data from a reverse telephone directory, and creates a list of numbers that can be called. The three data files used are downloaded from the Internet, onto the user's Desktop. My Excel spreadsheet needs to open the files. The users typically have Windows 7 or Vista. I've been told that I can access these files with Workbooks.Open Filename:="..\Desktop\XXX.csv" This works on Windows 7 machines, but not on Vista - the only difference in the software used. Is there a simple way to fix this? Jim Berglund |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Opening Files on other User's Desktops
use environ("userprofile") to determine the location.
in the vb editor. do a control g to enable the immediate window paste the following and hit enter ?Environ("UserProfile") & "\Desktop\" it should give you the desktop location on any pc. then, just add the filenames, i have no idea if they're hard coded, in cells or what. -- Gary Keramidas Excel 2003 "Jim Berglund" wrote in message ... I may have made an error in judgment by asking this question again, but having played around with it, I can state the concern properly... I have created a worksheet which has to run on various user's PC's. It takes two Do Not Call List area code files, joins them, reformats the data and then determines if any if the data is also found in data from a reverse telephone directory, and creates a list of numbers that can be called. The three data files used are downloaded from the Internet, onto the user's Desktop. My Excel spreadsheet needs to open the files. The users typically have Windows 7 or Vista. I've been told that I can access these files with Workbooks.Open Filename:="..\Desktop\XXX.csv" This works on Windows 7 machines, but not on Vista - the only difference in the software used. Is there a simple way to fix this? Jim Berglund |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Opening Files on other User's Desktops
use environ("userprofile") to determine the location.
in the vb editor. do a control g to enable the immediate window paste the following and hit enter ?Environ("UserProfile") & "\Desktop\" it should give you the desktop location on any pc. then, just add the filenames, i have no idea if they're hard coded, in cells or what. "Jim Berglund" wrote: I may have made an error in judgment by asking this question again, but having played around with it, I can state the concern properly... I have created a worksheet which has to run on various user's PC's. It takes two Do Not Call List area code files, joins them, reformats the data and then determines if any if the data is also found in data from a reverse telephone directory, and creates a list of numbers that can be called. The three data files used are downloaded from the Internet, onto the user's Desktop. My Excel spreadsheet needs to open the files. The users typically have Windows 7 or Vista. I've been told that I can access these files with Workbooks.Open Filename:="..\Desktop\XXX.csv" This works on Windows 7 machines, but not on Vista - the only difference in the software used. Is there a simple way to fix this? Jim Berglund . |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Opening Files on other User's Desktops
I tried this and got the string for the UserName. Thanks,
My users won't be able to do this - in fact, I don't want them touching the code. Is there any way I can make this work in a generic way? I've tried all the suggestions so far, without success. Jim "Gary Keramidas" wrote in message ... use environ("userprofile") to determine the location. in the vb editor. do a control g to enable the immediate window paste the following and hit enter ?Environ("UserProfile") & "\Desktop\" it should give you the desktop location on any pc. then, just add the filenames, i have no idea if they're hard coded, in cells or what. -- Gary Keramidas Excel 2003 "Jim Berglund" wrote in message ... I may have made an error in judgment by asking this question again, but having played around with it, I can state the concern properly... I have created a worksheet which has to run on various user's PC's. It takes two Do Not Call List area code files, joins them, reformats the data and then determines if any if the data is also found in data from a reverse telephone directory, and creates a list of numbers that can be called. The three data files used are downloaded from the Internet, onto the user's Desktop. My Excel spreadsheet needs to open the files. The users typically have Windows 7 or Vista. I've been told that I can access these files with Workbooks.Open Filename:="..\Desktop\XXX.csv" This works on Windows 7 machines, but not on Vista - the only difference in the software used. Is there a simple way to fix this? Jim Berglund |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
Opening Files on other User's Desktops
you need to provide more information. we have no idea what code is needed
because we don't know what you're trying to do. tell us where you get the filename from. is there going to be a button the click to open the file? with more info, somebody here can provide you a code solution to do what you want, it's not that difficult, as long as we get the information. -- Gary Keramidas Excel 2003 "Jim Berglund" wrote in message ... I tried this and got the string for the UserName. Thanks, My users won't be able to do this - in fact, I don't want them touching the code. Is there any way I can make this work in a generic way? I've tried all the suggestions so far, without success. Jim "Gary Keramidas" wrote in message ... use environ("userprofile") to determine the location. in the vb editor. do a control g to enable the immediate window paste the following and hit enter ?Environ("UserProfile") & "\Desktop\" it should give you the desktop location on any pc. then, just add the filenames, i have no idea if they're hard coded, in cells or what. -- Gary Keramidas Excel 2003 "Jim Berglund" wrote in message ... I may have made an error in judgment by asking this question again, but having played around with it, I can state the concern properly... I have created a worksheet which has to run on various user's PC's. It takes two Do Not Call List area code files, joins them, reformats the data and then determines if any if the data is also found in data from a reverse telephone directory, and creates a list of numbers that can be called. The three data files used are downloaded from the Internet, onto the user's Desktop. My Excel spreadsheet needs to open the files. The users typically have Windows 7 or Vista. I've been told that I can access these files with Workbooks.Open Filename:="..\Desktop\XXX.csv" This works on Windows 7 machines, but not on Vista - the only difference in the software used. Is there a simple way to fix this? Jim Berglund |
#6
Posted to microsoft.public.excel.programming
|
|||
|
|||
Opening Files on other User's Desktops
this code will open the 430.csv file on anybody's desktop, as long as they
haven't modified their user profile: Workbooks.Open Filename:=environ("Userprofile") & "\Desktop\403.csv" -- Gary Keramidas Excel 2003 "Jim Berglund" wrote in message ... I tried this and got the string for the UserName. Thanks, My users won't be able to do this - in fact, I don't want them touching the code. Is there any way I can make this work in a generic way? I've tried all the suggestions so far, without success. Jim "Gary Keramidas" wrote in message ... use environ("userprofile") to determine the location. in the vb editor. do a control g to enable the immediate window paste the following and hit enter ?Environ("UserProfile") & "\Desktop\" it should give you the desktop location on any pc. then, just add the filenames, i have no idea if they're hard coded, in cells or what. -- Gary Keramidas Excel 2003 "Jim Berglund" wrote in message ... I may have made an error in judgment by asking this question again, but having played around with it, I can state the concern properly... I have created a worksheet which has to run on various user's PC's. It takes two Do Not Call List area code files, joins them, reformats the data and then determines if any if the data is also found in data from a reverse telephone directory, and creates a list of numbers that can be called. The three data files used are downloaded from the Internet, onto the user's Desktop. My Excel spreadsheet needs to open the files. The users typically have Windows 7 or Vista. I've been told that I can access these files with Workbooks.Open Filename:="..\Desktop\XXX.csv" This works on Windows 7 machines, but not on Vista - the only difference in the software used. Is there a simple way to fix this? Jim Berglund |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Opening Quattro Pro for Windows files (*.WB1 Files) using Excel 20 | Excel Discussion (Misc queries) | |||
Excel 2002 on TWO desktops? | Excel Discussion (Misc queries) | |||
How do i set up my workbooks in different desktops? | Excel Discussion (Misc queries) | |||
How can I view files chronologically when opening multiple files | Excel Discussion (Misc queries) | |||
Locating a user's Program Files | Excel Programming |