Gmail Calendar Documents Reader Web more »
Recently Visited Groups | Help | Sign in
Google Groups Home
Message from discussion Bad site URL name
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Eric  
View profile  
 More options Jul 1, 4:01 pm
Newsgroups: microsoft.public.sharepoint.portalserver
From: Eric <eri...@nospam.nospam>
Date: Tue, 30 Jun 2009 23:01:01 -0700
Local: Wed, Jul 1 2009 4:01 pm
Subject: RE: Bad site URL name

Here's the fix.  The code was developed by MSFT support (as-is, no warranties).

Put the full bad URL in the first box:  http://sharepoint/apps/badsiteurl.aspx
Put the good relative URL in the second box:/apps/goodsiteurl

The code below is part of a Visual Studio solution which I can't attach.  
Here's the meat of the code to get the gist of how the fix works:

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using Microsoft.SharePoint;

namespace UpdateServerRelativeURL
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }

        private void button1_Click(object sender, EventArgs e)
        {
            SPSite mySite = new SPSite(textBox1.Text);
            SPWeb oWeb = mySite.OpenWeb();            
            oWeb.ServerRelativeUrl = textBox2.Text;
            oWeb.Update();
            MessageBox.Show("URL of the site " + textBox1.Text + " updated
!!!! ");
        }
    }

}


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.

Create a group - Google Groups - Google Home - Terms of Service - Privacy Policy
©2009 Google