Automatically change default database path in MS Access? - vba

We recently switched servers and many times in the past it has not been an issue, but this time the My Documents folders had some issues on the server somehow, so everyone's getting an error prompt when they open a MS Access file ("cant change working directory").
Googling it, it appears to be due to the path listed in File -> Options -> General -> Default Database Folder.
Does every user have to change this themselves to their actual My Documents folder? Why isn't it linking automatically like it has in the past? Is there a way I can automate / change it for anyone who opens the database?
For instance if I know their current default path looks like \\OLD_SERVER\tshome$\user_name\my documents can I change it to \\NEW_SERVER\tshome$\user_name\my documents automatically?

Related

Change explorer columns in a network drive through desktop.ini

I have a directory within a network drive which mainly stores MS-Office documents. I would like to alter the desktop.ini to display the title-column by default whenever someone opens this folder in his explorer.
In another directory I have a bunch of folders with additional comments to guide the users through the structure / explain the correct purpose of each folder, etc... By default the comment-column is disabled so I also need a way to enable this column by default.
Does anybody have an idea how to do this?

Oracle SQL Developer Export Issue: Target not writable

I have SQL Developer on machine. Once while exporting data from database to my local drive, It prompted me to ask whether " you would like to allow the local drive to be writable or not". I accidentally clicked No. From then, I am not able to export any file from database to my local drive. Every time I get an error saying "Save as Target :D is not writable". I couldnt find any solution in the preferences section nor over the internet. I am accessing SQL developer via citrix. I have cleared cache, removed tmp files. Nothing helped. Is anybody facing the same issue? Any idea how to clear defaults? I use Windows 7 environment.
Even I faced this issue and googled but no luck. So, I started trying multiple options. Below one worked (exclude the double quotes as slash is lost while posting this update)
\\Client\C$\Test.txt
Example : \\Client\C$\Data\Test.txt

Export Application Settings to Shared Network Directory - Load / Import Settings on Startup

Can I export my application settings to a shared network drive and then 'point' users to it, essentially using this as a project settings 'ini' file.
I am referring to the system generated settings file created by the application. i.e. C:\APP_NAME\My Project\Settings.settings
For example I wish for all users on a particular project to use the same database connection string which is persisted in the application settings.
I would like the following functionality:
Administrator exports their application settings.
Users point to the exported settings file.
Settings file is used at startup for all users.
I have written a class to export a .txt file and transpose the settings at startup, but surely importing and exporting the settings file itself is a much more efficient and less error prone solution.
Thanks...
I think what you have done is correct. If you have written a method to read / import the settings at start, is this what you plan to achieve?
Couple of questions to go further into this...
What kind of settings are you actually trying to load? Are these startup dependent? or can they be loaded into the program at a later time? I.e. after the initial start / form has loaded?
Have you got access to SQL or MYSQL or similar? - If so you could write a small table with list of users or user groups and settings, then retrieve these using a hardcoded connection string (or another way you please), this can then be updated / modified by other 'Specified' users
It might even be nice to create a users table / csv to hold each user and then their permissions / group.
If you are not using SQL / MYSQL how are you making sure the text file cant be read, altered? Maybe look into some simple encryption (Its VERY easy, if this is needed at all?)

Word Files are opening in Readonly mode

I have program which get the word file from server and after editing it saved back to server . It was working and i was able to save files back to server but suddenly files are opening in Readonly mode . I have searched alot on google and have tried all options but it seems not working.Any ideas clues ??
If the file displays as read only in Word that means word thinks the file is readonly, which means its seen something to make it think that. Since word does not integrate with access control methods over webdav, that means it can only be that word has determined that the server does not support required operations for writing. This can be:
does not support uploading (ie PUT). Webdav reports this in the OPTIONS request, so please check for that
does not support locking (ie LOCK)
does support locking, and the file is locked. But this usually gives the user a specific warning
Locking comes into play in different ways depending on how you're connecting to the server (on windows you can either use a mapped drive or a network location), and the means of opening (either clicking a link in a web page which uses the sharepoint dll, or opening directly from a mapped drive, or opening from the file open dialog in MS office), and of course the application doing the opening (ie MS Office, Open Office, etc)
Depending on what combination of the above you're using locking might or might not be required to edit.
Webdav indicates locking support in the following ways
- the supported levels header
- MS-Author-VIA header, which should return "webdav"
- the presence of LOCK in the OPTIONS response.
So you might need to check for the presense of those, probably by using wireshark or similar.

About 'writing to files' and user permissions

I'm working on a VB.NET (2010) project that will need to write text files to the end user's computer. I have read online that due to some user's security settings, that the safest place to write files to is the Application Data folder.
But what I would like to do (if possible) is allow the user to select where they want the files written to, via a SaveToFile dialog (I am using a SaveFileDialog in combination with My.Computer.FileSystem.WriteAllText).
So my question is... if I use a SaveFileDialog (as opposed to saving a file without using a dialog), does that mean that my files will always be written to wherever the user selects?
Or is it possible that the user could select a location (ie their "desktop"), and it would not write the file there, due to their security settings? (UAC, Firewall, etc).
If the latter is possible, is there anything I can suggest to the user that they can do that would enable my program to write files to wherever they select, and it would work 100% of the time?
Like maybe... if they right-click on my program's exe file and go to Properties > Security, and make sure the 'Write' permission is allowed, will that do the trick? Or is there more to it than that?
And does it mke any difference whether or not they are logged into their computer as "admin"?
I've read a lot of conflicting things about all of this online, so I'm just trying to getting a better understanding of it all so that I know how to proceed.
Thanks!
The [Save As] dialog will only let the users select a folder they have read and write acceess to and that is done for you by the Operating system . So that is the best option in my openion