Making a user a Site Collection Administrator in MOSS 2007 via the SQL database

I had inadventenly locked myself out of Sharepoint by removing myself as site administrator. But, because I have access to the SQL database I was able to restore my permissions. First run the following query to find out your tp_ID. (You will have to run this on the correct Content database).

select tp_id, tp_siteadmin, tp_login from userinfo

Find your user name in the query results (you can use a WHERE LIKE clause to simplify this step). Then run the following query to give yourself permissions.

UPDATE userinfo SET tp_siteadmin = 1 WHERE tp_Id = ?

 

That should give you everything you need.  Log into Sharepoint and you should be a Site Collection Administration

18. June 2010 06:46 by Danny Gershman | Comments (0) | Permalink

MediaPanel hosted in a blog

10. June 2010 08:03 by Danny Gershman | Comments (0) | Permalink

Supressing “…navigate... page?” message in Internet Explorer (IE)

Whenever there is a download going on and the page changes you’ll get a similar alert popup.

“Are you sure you want to navigate away from this page?  There is currently a download in progress.  If you leave now, the download will pause shortly.  Press OK to continue, or Cancel to stay on the current page.”

image

<body onBeforeUnload=”return false;”>

Technorati Tags: ,
24. May 2010 08:56 by Danny Gershman | Comments (0) | Permalink

Simulating POST with Fiddler

Sometimes its useful to simulate POST action on a WebForm or a Webservice in ASP.NET for debugging.  Fortunately Fiddler allows you to compose (construct) such a request.  First thing to do is fire up Fiddler.  Jump to the “Request Builder” tab.

image

From the drop down, select “POST”.  Put the URL you are testing in the textbox.  The other thing to input is in the “Request Headers” field which is to let the receiving page that form data is being passed.  “Content-type: application/x-www-form-urlencoded”

image

The final piece of data is the key value pairs of the data to be passed.  Make sure these values are URL encoded.  Put this in the “Request Body” field.

image 

One setting to change is to ensure that request will be automatically tracked.  Switch to the option tab, as ensure “Inspect Session” is checked.

image

Click “Execute” to fire off the request.  This can be really useful if you need to debug something.  Make sure your ASP.NET development server is running.  In this case mine is running on localhost, port 8080.  Set your breakpoint in Visual Studio and then fire off the request.  Then the breakpoint will catch and you can step through.  This is a great way to test different variations of data POSTs.

Technorati Tags: ,,,,
6. May 2010 07:40 by Danny Gershman | Comments (3) | Permalink

Intellisense Problem – Microsoft’s Quick Response

I had sent out a tweet on Friday to list #VS2010 about how my intellisense stopped working all of sudden in VS2010.  Scott Guthrie @scottgu replied within 27 minutes and asked me to send a direct email to him. 

I sent an email today.  Within several hours I was redirected to Brittany Behrens @VSEditor.

Well here was the response that worked.  I completely reset my settings.

The problem is that when ReSharper is enabled for a user, it disables the default Visual Studio IntelliSense and replaces it with ReSharper IntelliSense.  The .vssettings file records that IntelliSense is disabled.  When you install VS 2010, it automatically imports your settings file from the previous version of Visual Studio, including the setting that disables IntelliSense.

You can fix this in one of two ways:

1.)   Install a build of ReSharper that’s compatible with VS 2010, or

2.)   Re-enable IntelliSense in VS 2010.  To do this, go to Tools->Options->Text Editor->[your language]->General and check “Auto list members”.  For C#, you might also need to visit Tools->Options->Text Editor->C#->IntelliSense and reset those options as well.

Technorati Tags: ,
19. April 2010 17:21 by Danny Gershman | Comments (0) | Permalink

CheckPoint VPN-1 SecureClient on x64 Windows

There is no 64-bit runnable client for Windows (including Vista and Windows 7).  After much frustration, today I finally found a workable solution.

1.) Install Windows XP Mode which is available for free from Microsoft’s website.  http://www.microsoft.com/windows/virtual-pc/download.aspx.  This will only work for Windows 7.  You might be able to install VMWare w/Unity Mode to do the same.

2.) Once you have the whole thing set up, fire up the virtual machine and install the CheckPoint VPN-1 SecureClient.  This will publish it to the Start Menu on Windows 7.

3.) You need to turn off NAT in order to get this to work, so under Tools, select the currently connected Network Adapter.

4.) Now you can run the application seamlessly in Windows 7, the virtual machine will run hidden.

5.) If you need to remote desktop, you’ll need to hack the registry in order to all the Remote Desktop application (which by default is not enabled) to be published.

6.)

Original Post: http://social.technet.microsoft.com/Forums/en-US/w7itprovirt/thread/42e03393-749b-466b-997c-35276ab89730

  1. Open regedit in the VM
  2. navigate to HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Virtual Machine\VPCVAppExcludeList a the Name of the program in question
  3. Delete the value that you don't want (say Name: mstsc.exe Type: REG_SZ Data: C:\WINDOWS\System32\mstsc.exe)
  4. Restart the virtual machine

7.) Now you should be able to use the VM’s RDP application to remote to any system that you’ve connected to via the VPN

image

Technorati Tags: ,,
12. April 2010 12:55 by Danny Gershman | Comments (1) | Permalink

Shrinking a div

display:inline-block;
Technorati Tags: ,
6. April 2010 20:38 by Danny Gershman | Comments (0) | Permalink

Perfmon Counters for Measuring Bandwidth

Works well, measured in bytes.

image

Technorati Tags: ,,

31. March 2010 18:32 by Danny Gershman | Comments (0) | Permalink

Configuring ASP.NET MVC on IIS6

23. March 2010 08:30 by Danny Gershman | Comments (4) | Permalink

Sharepoint related upload problems

There was a slight issue with uploading documents larger than 28 MB on Windows Server 2008.  This Microsoft knowledgebase article helped me resolve it.

http://support.microsoft.com/kb/925083

Technorati Tags: ,
15. March 2010 19:09 by Danny Gershman | Comments (0) | Permalink

About dannyg

dannyg has been writing software for the last 12+ years and worked with various languages and programs.  He specializes business process automation, versatile solutions and R&D.