![]() |
|
|
Thread Tools | Display Modes |
#35
|
|||
|
|||
![]()
This is giving me some error-messages, but I have noticed that you changed the backslash in
{SKIPIF{MERGEFIELD Anz}= "0"}{QUOTE{INCLUDETEXT "{FILENAME \p}\..\sb{MERGEFIELD Anz}.docx"}} to a double normal slash "//..//sb" and after I changed that in the word doc, the old excel code is running perfectly. ![]() ![]() ![]() ![]() ![]() The only problem remaining is that Excel replaces "." with "_" can I somehow stop that? I have the following .bat-file to change parts of names in a file. How can I change the path to the path of the folder that the .bat file is in (so that everyone can use this on his computer)? And can I integrate this in the excel vba code? And here is what i wrote in the .bat-file: Code:
@echo off Setlocal enabledelayedexpansion Set "Pattern=_" Set "Replace=." For %%# in ("C:\Users\AZEM\Work Folders\Desktop\Verteidigungsanzeigen\*.docx") Do ( Set "File=%%~nx#" Ren "%%#" "!File:%Pattern%=%Replace%!" ) Pause&Exit |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
![]() |
stevenel | Excel Programming | 8 | 08-14-2018 03:05 PM |
![]() |
richardst | Excel | 4 | 06-21-2016 06:03 PM |
Marking specific cells depending on start and end time entered | ellebb85 | Excel Programming | 0 | 01-17-2016 02:50 AM |
![]() |
danw | Word | 6 | 04-08-2015 06:24 AM |
Merge Word documents using a mailmerge field | Concertina | Mail Merge | 3 | 02-18-2013 04:12 AM |