Friday, September 3, 2010

VNC from a Windows PC to Mac OS

Friday, September 3, 2010
i spent a few hours recently trying to make this work... it should be a straightforward thing to remotely connect to a mac from a PC. but the two platforms, like cain and abel, just seem to hate each other.

Configure your mac to accept an incoming connection.
enabling remote access in mac OS X is easy. system preferences->sharing->screen sharing. select the computer settings button, and select the option to allow VNC access with a password. pleeeez... password your shits or suffer the wrath of khan! leave the other options at default.

Make note of your mac's IP address.

system preferences->network. look at the TCP/IP information for whatever network interface your using. if you have an ethernet cable connected to your mac, you're looking for the built-in ethernet IP Address. or your mac could be using a wireless airport connection. Screenshots and steps explaining how to find the IP Address of your mac.

Install a VNC client on your PC.
i use the free version of RealVNC. the download screen asks for your contact information, but none of the fields are required. so just skip down to the Download button. once you download the file and start the installation wizard, take the defaults... except where it asks if you want to install VNC Server or VNC Viewer or both. you only need VNC Viewer.

theoretically, you should be ready to fly. but in my case, when i tried to connect to the mac using VNC viewer, a saw a quick flash and then NOTHING. oooo. ahhhh.

the solution was to create a VNC preferences file.


copy the above and paste into notepad. be sure to insert the IP Address for your mac on the HOST line. when you save the file, enclose the name in quotes with a .vnc on the end. for example, i called mine: "mac.vnc"
this forces notepad to save the file as .vnc type instead of .txt

Create a batch file to run VNC viewer with the .vnc settings file.
i don't want to have to bring up the command prompt and type blah blah blah every time i VNC to my mac. waste o time.
so... i created a batch file so all i have to do is double click on an icon when i want to connect. the process:
copy the following into a new notepad file and save as "vnc_mac.bat" (quotes are important so notepad doesn't save it as .txt)
start "vnc" "c:\program files\realvnc\vnc4\vncviewer.exe" -config "c:\program files\realvnc\vnc4\mac.vnc"

some things to note: your mac.vnc file needs to be in the same folder as your VNC viewer executable. in most cases, your path will be the same as the one above. but it's possible you may need to change the file path (if you didn't install RealVNC on your C:\ for example).

i then put my mac_vnc.bat file in My Documents and created a shortcut to the desktop.

double click the shortcut on your desktop to mac_vnc.bat, and you should be prompted for the VNC password you set on your mac.

and all is happy with the world.

goodbye sharepoint, hello other nerdle realms...

i no longer have access to a production sharepoint environment, and as such, i probably won't be blogging much about adventures in sharepoint.

but i'm a nerdle to the core... so there will always be things i learn that maybe are of interest to others out there in the cybersphere.

Friday, January 22, 2010

Non-Specific Data Source Error in Sharepoint Data View Web Part

Friday, January 22, 2010
I ran into another annoyingly generic M$ error today when trying to configure the data source for a Data View web part (DVWP) in Sharepoint Designer.  I had created a SQL view which referenced some Sharepoint list data, did some calculations in SQL, and I wanted to show the results back in Sharepoint.

I was able to successfully show the list of SQL tables / views in the data source manager, but as soon as I selected my SQL view and clicked Next, I saw:
"Server Error: An error occurred while retrieving the list of Databases from : The server for the data source returned a non-specific error when trying to execute your query. Check the format and content of your query and try again. If the problem persists, contact the server administrator."
I found a forum where a user suggested that the issue was  Sharepoint Designer failing to properly handle SQL queries that were missing fully qualified table references.  I played around with that idea and determined through testing that it wasn't the source of my problem.

But, it did cause me to remember that the SQL database in which I'd created my view was not the Sharepoint Content database, and I had referenced Sharepoint data.  The view ran fine in SQL.  But I wasn't configuring the Data View web part with *my* credentials.

Problem resolved:  in SQL, add a User Mapping to the Sharepoint Content database in the properties of the login I was using in my Data View

Tuesday, January 5, 2010

"Failed to Load" workflow in Sharepoint Designer

Tuesday, January 5, 2010
i ran across this error today when attempting to open existing workflows, and found several posts which indicate the folder under \Documents and Settings\\Application Data\Microsoft\SharePoint Designer\ProxyAssemblyCache need to be deleted (after closing Designer).

this didn't work in my case.  it did allow me to create new workflows, but i wasn't able to open my existing ones.

and then i remembered the other day, i was troubleshooting a different sharepoint issue and in doing so, i replaced web.config with an earlier copy.  it didn't fix my other issue, but i also didn't restore the web.config to the later version.

so, i put the latest copy of web.config back in place, renaming the older, "safe" copy of the file.  i then deleted the folder, and launched SPD.

and there was much joy & singing across the land.