我想通过创建新文件夹将文件从临时文件夹复制到我的 C 盘中
I want to copy files from temporary folder to in my c drive by creating new folder
if FileCopy(ExpandConstant('{tmp}\SPECTRUMJOBS_Data.MDF'),
ExpandConstant('C:\Program Files\Microsoft SQL Server\MSSQL11.LOGISTICS\MSSQL\DATA\SPECTRUMJOBS_Data.MDF'),
False) then
我尝试了上面的方法,但我无法复制,因为该位置没有名为 DATA 的文件夹。
所以请帮我复制DATA文件夹和文件
你自己回答了。如果 MSSQL 文件夹下没有 DATA 文件夹,则必须先创建该文件夹。
并且...如果文件夹 MSSQL11.LOGISTICS 中没有文件夹 MSSQL,则必须首先创建该文件夹。
等等...
现在把上面的句子倒序读一遍,大功告成。
强制创建您可以使用的目录(文本来自 InnoSetup 帮助):
Prototype:
function ForceDirectories(Dir: string): Boolean;
Description:
Creates all the directories along the specified directory
path all at once. If the first directories in the path do exist, but
the latter ones don't, ForceDirectories creates just the ones that
don't exist. Returns True if successful, False otherwise.
InnoSetup 文档位于 ishelp
if FileCopy(ExpandConstant('{tmp}\SPECTRUMJOBS_Data.MDF'),
ExpandConstant('C:\Program Files\Microsoft SQL Server\MSSQL11.LOGISTICS\MSSQL\DATA\SPECTRUMJOBS_Data.MDF'),
False) then
我尝试了上面的方法,但我无法复制,因为该位置没有名为 DATA 的文件夹。
所以请帮我复制DATA文件夹和文件
你自己回答了。如果 MSSQL 文件夹下没有 DATA 文件夹,则必须先创建该文件夹。 并且...如果文件夹 MSSQL11.LOGISTICS 中没有文件夹 MSSQL,则必须首先创建该文件夹。 等等... 现在把上面的句子倒序读一遍,大功告成。
强制创建您可以使用的目录(文本来自 InnoSetup 帮助):
Prototype:
function ForceDirectories(Dir: string): Boolean;
Description:
Creates all the directories along the specified directory path all at once. If the first directories in the path do exist, but the latter ones don't, ForceDirectories creates just the ones that don't exist. Returns True if successful, False otherwise.
InnoSetup 文档位于 ishelp