473,387 Members | 1,516 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

Deploying access using .cmd

40
Hello.

I'm referring to the method used in this post, proposed by Jforbes:
http://bytes.com/topic/access/answer...end-accdb-file

My .cmd reads like this:

Expand|Select|Wrap|Line Numbers
  1. @ECHO OFF
  2. IF NOT EXIST %userprofile%\Documents\DBUser\WKFMS2015.accdb MKDIR %userprofile%\Documents\DBUser
  3. COPY "\\F:\COURT\B. Shem Kalafa\DBase\DBDeployment\WKFMS2015.accdb" %userprofile%\Documents\DBUser\WKFMS2015.accdb /Y
  4. START /I "MSAccess.exe" %userprofile%\Documents\DBUser\WKFMS2015.accdb
When I try to execute it, however, the following message is displayed:
The file name, directory name, or volume label syntax is incorrect.
0 file(s) copied
Could there be something I'm doing wrong, or configuration settings vary for DOS depending on the OS used?
May 26 '15 #1

✓ answered by jforbes

I didn't see it earlier, but on Line 3, the line that performs the copy, has both \\ and F: at the beginning of the path. It should be one or the other, either from a mapped drive or a URL. My guess is you need to remove the beginning \\

5 1370
jforbes
1,107 Expert 1GB
I didn't see it earlier, but on Line 3, the line that performs the copy, has both \\ and F: at the beginning of the path. It should be one or the other, either from a mapped drive or a URL. My guess is you need to remove the beginning \\
May 26 '15 #2
NeoPa
32,556 Expert Mod 16PB
That's a good point.

I would also suggest that both file name parameters are enclosed in spaces as you don't know if %UserProfile% will result in a value with spaces embedded in it.

So, line #3 would be :
Expand|Select|Wrap|Line Numbers
  1. COPY "F:\COURT\B. Shem Kalafa\DBase\DBDeployment\WKFMS2015.accdb" "%userprofile%\Documents\DBUser\WKFMS2015.accdb" /Y
May 26 '15 #3
jforbes
1,107 Expert 1GB
Oh, Good catch NeoPa.
May 26 '15 #4
Shem K
40
Jforbes, NeoPa, both actually work remarkably well. Thank you so much!
I tested it out on another workstation running Windows 7, and it deployed perfectly. As Google and Outlook do not allow attachment of executable files, I had to send a file path link via email. Apparently, I would need to send directions of using that link on my email too, lol.

Thanks very much!

Wish there were provisions for two best answers, though :-)
May 27 '15 #5
NeoPa
32,556 Expert Mod 16PB
Shem:
Wish there were provisions for two best answers, though :-)
That's very generous of you. I'm afraid I'd have had to reset one in that case anyway. Mine was simply a clarification comment. The fundamental point was caught by JForbes and that's what matters.

Always gratifying to see a happy customer though :-)
May 27 '15 #6

Sign in to post your reply or Sign up for a free account.

Similar topics

1
hariharanmca
by: hariharanmca | last post by:
How to Shift or Copy Data from Sqlserver to MS Access using Stored procedure I am passing the clint MS Access file path in that i want to insert or update data in that MS Access file using...
8
by: fniles | last post by:
Can I change the connection time out in VB.Net 2003 and MS Access (using OLEDbConnection) ? When I use Connect Timeout = 60 in the connectionstring, I get an error "Multiple-step OLE DB operation...
3
by: ofilha | last post by:
I need to format a column in excel but would like to do it from Access using VB. I have hacked around and found a few ways to get to the workbook but have a problem getting to the sheet i want. But,...
2
by: ublow56 | last post by:
I am trying to create an ASP application using javascript. I found may ways to connect to Ms Access using VBScript, but I can't find any for the Javascript... Can someone help me??? I just need...
18
by: hotflash | last post by:
Hi Mark et All, I understand that you created a very professional document and a similar issue forum out there regarding to Inserting the checkbox value into MS Access using ASP however; I am so...
2
by: shivapadma | last post by:
is it possible to access MS ACCESS using c++? if yes,then how can i access? is it similar to java language? i.e, 1.loading 2.connecting 3.using
4
by: macca | last post by:
hi, Does anybody know if it's possible to log into Outlook Web Access using PHP? I mean, if I have the username, password and email address I need to have a link that opens directly into...
6
by: =?Utf-8?B?QmVu?= | last post by:
Hi all, Is there any good resource online that you can share with me about programming Access using C#. I am trying to get my feet wet with C# and vs2008. I tried looking at kb317114, it...
1
by: sirhacksalot | last post by:
I'm sorry to resurrect an old topic ( Send Email Through Query ) but I am using the code you posted here to send auto emails through access using outlook. Everything works beautifully except the...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.