Павел Запивахин Пользователь Сообщений: 126 |
#1 17.06.2013 07:50:04 Здравствуйте! Прошу помочь в решении возникшей проблемы. Рядом с файлом лежит папка «Бланки», в ней находятся папки с файлами (в прилагаемых макросах – «Старое имя папки» и «Файл с данными»). Необходимо на основании данных из файлов сформировать имена (Link) и присвоить их родительским папкам («Старое имя папки» заменить на Link). Первый макрос, где я конкретно прописываю FilePath, работает. Во втором макросе я пытаюсь взять путь к файлу из диалога GetOpenFilename, VBA на строке переименования выдает ошибку: Run-time error ‘75’: Path/file access error. Подскажите, пожалуйста, что делаю не так?
Макрос, который не работает:
|
||||
KuklP Пользователь Сообщений: 14868 E-mail и реквизиты в профиле. |
М-да. Понял в чем вопрос. Оказывается файловые диалоги блокируют путь к папке. Изменено: KuklP — 17.06.2013 09:03:30 Я сам — дурнее всякого примера! … |
KuklP Пользователь Сообщений: 14868 E-mail и реквизиты в профиле. |
#3 17.06.2013 09:17:40 Можно перебить другим диалогом в нем ничего не выбирая. Так работает:
Я сам — дурнее всякого примера! … |
||
KuklP Пользователь Сообщений: 14868 E-mail и реквизиты в профиле. |
#4 17.06.2013 09:21:43 И так работает:
Я сам — дурнее всякого примера! … |
||
Павел Запивахин Пользователь Сообщений: 126 |
#5 17.06.2013 09:45:29 Уважаемый KukIP, сделал так:
Но все-равно на строке Name FolderPath As ThisWorkbook.Path & «Бланки» & link выдает ошибку: Run-time error ‘75’: Path/file access error. |
||
KuklP Пользователь Сообщений: 14868 E-mail и реквизиты в профиле. |
#6 17.06.2013 13:29:23 Павел Запивахин, Вы пропустили в моем посте весьма важную деталь. А именно:
после диалога выбора файла! ChDir получается, перехватывает у диалога занятость папки и освобождает ее для дальнейших манипуляций. Изменено: KuklP — 17.06.2013 13:30:06 Я сам — дурнее всякого примера! … |
||
Получилось! KukIP, большое спасибо за помощь! |
|
KuklP Пользователь Сообщений: 14868 E-mail и реквизиты в профиле. |
#8 17.06.2013 14:09:20 Заходите. Мы всегда рады тем, кто сам чего-то делает Я сам — дурнее всякого примера! … |
- Remove From My Forums
-
Question
-
Dears,
pleas i need help as i faced Path/File Access Error when opening the file, when the debug popup window is appeared the hit debug
another crash window popped up
as per the glitch massage, i can’t identify the problem with which Code, this workbook have more than one code plus have about 4 forms. as shown i use office 2013.
if the workbook is required to preview i can upload
Gratefully,
-
Moved by
George123345
Friday, February 20, 2015 2:05 AM
-
Moved by
All replies
-
Hi,
This is the forum to discuss questions and feedback for Microsoft Excel, this issue is related to debug code, I’ll move your question to the MSDN forum for Excel
http://social.msdn.microsoft.com/Forums/en-US/home?forum=exceldev&filter=alltypes&sort=lastpostdesc
The reason why we recommend posting appropriately is you will get the most qualified pool of respondents, and other partners who read the forums regularly can either share their knowledge or learn from your interaction with us. Thank you for your understanding.
George Zhao
TechNet Community Support
It’s recommended to download and install
Configuration Analyzer Tool (OffCAT), which is developed by Microsoft Support teams. Once the tool is installed, you can run it at any time to scan for hundreds of known issues in Office
programs. -
Hi Ahmed MAbdel Kader,
To determin whether the issue was caused by the code in VBA, I susggest that you try to open the workbook in safe mode.
Then you can remove the code to wether the issue was fixed. If yes, we can comment the code line by line to see which line of code to cause this issue.
Regards & Fei
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click
HERE to participate the survey. -
Hello Fie,
I did what you commented then i opened the workbook in safe mode. the error went away, and the sheet work as well, when opened it in another machine both with office 2010 or 2013, nothing go wrong, this error occurs with my machine only, while this workbook
was work perfectly without any glitch before, neither new add-ins nor software had been installed before crash for this bug, but creating Lync account only,any suggestions for treating these trouble, is repairing or re-install office can correct the matter?, appreciate any additional suggestions
Gratefully,
-
Edited by
Ahmed M Abdel Kader
Sunday, February 22, 2015 8:52 PM
-
Edited by
-
Hi Ahmed,
Can you post the VBA code snippet that caused this problem?
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click
HERE to participate the survey. -
Hello Caillen,
as i clarified before the workbook have a lot of codes related of filter data in listbox, filter data by userform, replace data from sheet to another one, code for outlook notification with a specific action «when replace data»
i uploaded the zipped workbook, the Codes is commented as much as i can to be easy somehow, if there are some needed info, i’ll provide you.
the workbook
Gratefully,
-
Hello Fie,
as you clarified may be this issue only occur on the specific machine, i’ll take a look to the mentioned
URLs perhaps get it solved,Thanks a lot,
Forum Rules |
|