473,655 Members | 3,056 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

open mode : adModeShareDeny None

9 New Member
Hi All,

We use “adModeShareDen yNone” open mode to allow others users to connect to database at the same time.
But when I open database through one client on computer, other user(computer) can not connect to database. It gets an error saying “file already in use”.
What can be the reason?

Note :: I have distributed .exe (front end) to different users.

## some part of code (visual basic)
'declare connection
Dim ConDB As ADODB.Connectio n
'declare SQL command
Dim myCommand As ADODB.Command
'declare record set to store output of SQL command
Dim myRecordSet As ADODB.Recordset

'To catch run-time errors
'On Error Resume Next
'Setting connection object
Set ConDB = New ADODB.Connectio n
'creating new record set
Set myRecordSet = CreateObject("A DODB.Recordset" )
'setting cursor type
myRecordSet.Cur sorType = adOpenStatic
'setting connection provider engine
ConDB.Provider = "Microsoft.Jet. OLEDB.4.0"

'clearing errors
Err.Clear
'let each user connect to database
ConDB.Mode = 16 'adModeShareDen yNone
'Opening connection
ConDB.Open CONNECTION_STRI NG <- declared constant in module
Dec 5 '08 #1
1 4915
FishVal
2,653 Recognized Expert Specialist
Hello, Anane.

Access doesn't support all ADO features.
Try different connection modes or open it in default adModeUnknown.

Regards,
Fish
Dec 7 '08 #2

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

Similar topics

1
1698
by: Eric Pederson | last post by:
WryPyY's- I've come across this file operation in others' code and have not seen any documentation for it: the use of "t" in the mode of file opening, such as: f1=open(somefile, 'at') f2=open(otherfile, 'rt') Is this merely another shorthand for a binary mode, or is there more going on with 't'?
6
8989
by: Mateo | last post by:
Hi! I tried to open page in new window with window.open(...) method. open() method supports fullscreeen mode, but I would like to open new maximized window with tiltle bar only.... Any idea how to do this? Can I maximize window from current page after it is opened with window.open?
0
1911
by: Mark Phillips | last post by:
Hello, I am having a problem in which a file can get stuck open when a thread that is attempting to write to it gets aborted (ThreadAbortedException occurs). The log file gets stuck open until the process is shut down (cannot delete file from Windows Explorer, for example). My test application stops execution with: An unhandled exception of type 'System.IO.IOException' occurred in mscorlib.dll Additional information: The process...
5
3950
by: ehui928 | last post by:
The following program is used to open a file in mode both read and append, but it has a problem that the file can't be opened. #include <iostream> #include <fstream> #include <cstdlib> using namespace std;
1
2551
by: Sorin Schwimmer | last post by:
Hi, I tried for the first time a Tix Tree, so, if my question is naive, I apologize upfront. The following code: <code> from Tix import * r=Tk()
7
2431
by: freegnu | last post by:
hi all, i dont dont whats the difference, and the different bettwen flags and mode
2
1856
by: tubby | last post by:
Does a py script written to open and read binary files on Windows affect files on a Linux or Mac machine in a negative way? My concern is portability and safety. I want scripts written within Windows to work equally well on Linux and Mac computers. Is this the safest, most portable way to open files on any platform: fp = open(file_name, 'rb') fp.close()
6
9283
by: =?Utf-8?B?TUNI?= | last post by:
I try to open a log file that is logging infomation by another process: StreamReader sr = File.OpenText(filePath); I got the exception message: The process cannot access the file 'c:\temp\myLog.txt' because it is being used by another process. How can I open, read and process the file in C#?
6
6000
by: sebastian.noack | last post by:
Hi, is there a way to or at least a reason why I can not use tarfile to create a gzip or bunzip2 compressed archive in the memory? You might might wanna answer "use StringIO" but this isn't such easy as it seems to be. ;) I am using Python 2.5.2, by the way. I think this is a bug in at least in this version of python, but maybe StringIO isn't just file-like enough for this "korky" tarfile module. But this would conflict with its...
0
8296
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8710
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8497
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
7310
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6162
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4150
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4299
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
1928
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1598
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.