An attempt to attach an auto-named database for file ….database1.mdf failed

I had this problem also and it was a pain. I configured my connection string and managed to solve the problem. In the connection string I replaced the value |DataDirectory|\dbfilename.mdf for AttachDbFilename property, with the path to the file. |DataDirectory| can only be used if the database file is in the App_Data folder inside same … Read more

Firefox Links to local or network pages do not work

This is the default Firefox behavior designed for security .The assumption is probably that most web sites don’t know what and where are you local files (including UNC paths). This could be turned off in firefox: type “about:config” in the address bar and accept “i’ll be careful” find “security.checkloaduri” in older versions or “security.fileuri.strict_origin_policy” in … Read more

How to (quickly) check if UNC Path is available

How’s this for a quick and dirty way to check – run the windows net use command and parse the output for the line with the network path of interest (e.g. \\vault2) and OK. Here’s an example of the output: C:\>net use New connections will be remembered. Status Local Remote Network ——————————————————————————- OK O: \\smarty\Data … Read more

Linking a UNC / Network drive on an html page

To link to a UNC path from an HTML document, use file:///// (yes, that’s five slashes). file://///server/path/to/file.txt Note that this is most useful in IE and Outlook/Word. It won’t work in Chrome or Firefox, intentionally – the link will fail silently. Some words from the Mozilla team: For security purposes, Mozilla applications block links to … Read more

How to run batch file from network share without “UNC path are not supported” message?

PUSHD and POPD should help in your case. @echo off :: Create a temporary drive letter mapped to your UNC root location :: and effectively CD to that location pushd \\server\soft :: Do your work WP15\setup.exe robocopy.exe “WP15\Custom” /copyall “C:\Program Files (x86)\WP\Custom Templates” Regedit.exe /s WPX5\Custom\Migrate.reg :: Remove the temporary drive letter and return to … Read more

Find UNC path of a network drive?

In Windows, if you have mapped network drives and you don’t know the UNC path for them, you can start a command prompt (Start → Run → cmd.exe) and use the net use command to list your mapped drives and their UNC paths: C:\>net use New connections will be remembered. Status Local Remote Network ——————————————————————————- … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)