Click on this icon to open the XML page.Tom Van Gaever - Blog
Search:   

Cannot connect to the configuration database after renaming server 
Tuesday, April 22, 2008, 08:58 - SharePoint
Posted by Administrator
Change the alternate mappings in central administration

Central Administration > Operations tab > Alternate access mappings > change every link that is refering to your old server.

rename your server
using the following command:

C:\Program Files\Common Files\Microsoft Shared\web server extensions\12\BIN>

Stsadm.exe –o renameserver –newservername <newname> -oldservernaam <oldnamenaam>

restart IIS server
IISRESET /NOFORCE

AFTER ALL THESE CHANGES THEN RENAME YOUR SERVER
start > control panel > System > change

If you changed your server name before you did these configurations, rename it again to the original name and start with changing the mappings.

Good luck ;)
add comment ( 4 views )   |  permalink   |   ( 3 / 751 )
Excel Web Services and external Links in Workbooks 
Wednesday, April 16, 2008, 10:30 - SharePoint
Posted by Administrator
My question on MSDN forum

When using Excel webservices in combination with Sharepoint to manage the excel files, you are able to show graphics from excel files managed by sharepoint. But Excel web service can't handle external links to other workbooks.

So we need to use the BreakLink method in the Office Excel Interop... easy, you think?

not so difficult after some research:

Office 2007 Primary Interop Assembly

Use the Office PIA to create a reference to the Microsoft.Office.Interop.Excel namespace

Code snippet to open the Excel File:

protected void Page_Load(object sender, EventArgs e)
{
ID = Guid.NewGuid();
filename = "test.xlsx";
savepath = Environment.GetEnvironmentVariable("TMP") + @"\" + ID + "_" + filename;


file = new FileInfo(MapPath(filename));
copy = new FileInfo(savepath);

RemoveAllLinksFrom(file);

copy.Delete();
Response.Write("<hr/>" + copy.FullName + " has been deleted.<br/>");
}

private void RemoveAllLinksFrom(FileInfo FileToProcess)
{
Response.Write("<hr/>" + FileToProcess.FullName + " starts to process.<br/>");

//Retrieve the COM
//Make sure that the ASPNET(XP)/INTERACTIVE(SERVER2003) has read/write permissions
//SITE: http://blog.crowe.co.nz/archive/2006/03/02/589.aspx
//--------------------------------------------------------------------------------
Application ObjExcel = new Microsoft.Office.Interop.Excel.Application();
Workbook ObjWorkBook;
CultureInfo info = Thread.CurrentThread.CurrentCulture;
try
{
//Generates problems with PIA, set Culture info to en-us and it works
//------------------------------------------------------------------------
Thread.CurrentThread.CurrentCulture = CultureInfo.GetCultureInfo("en-US");
ObjWorkBook = ObjExcel.Workbooks.Open(FileToProcess.FullName, false, false, Type.Missing, Type.Missing, Type.Missing, Type.Missing, Type.Missing, Type.Missing, Type.Missing, Type.Missing, Type.Missing, Type.Missing, Type.Missing, Type.Missing);
Object list = ObjWorkBook.LinkSources(XlLinkType.xlLinkTypeExcelLinks);
List<string> listfailed = new List<string>();
foreach (string link in (ICollection)list){
try
{
ObjWorkBook.BreakLink(link, XlLinkType.xlLinkTypeExcelLinks);
Response.Write("External link to " + link + " removed" + "<br/>");
}
catch (Exception ex) {
Response.Write("<p style='color:red;'>External link to " + link + " failed" + "</p>");
listfailed.Add(link);
}
}


//Save the file to the temp directory.
//Make sure that the ASPNET(XP)/INTERACTIVE(SERVER2003) has read/write permissions
//--------------------------------------------------------------------------------
ObjExcel.ActiveWorkbook.SaveCopyAs(savepath);
ObjWorkBook.Saved = true;
ObjWorkBook.Close(Microsoft.Office.Interop.Excel.XlSaveAction.xlDoNotSaveChanges, Type.Missing, Type.Missing);
ObjExcel.Quit();
Thread.CurrentThread.CurrentCulture = info;
}
catch (Exception ex)
{
Response.Write("<hr/>" + ex.ToString() + "<br/>");
}
finally
{
Marshal.FinalReleaseComObject(ObjExcel);
}
}
}


Points of interest:

* As you are using ASP.NET to open the Excel com Object take a look at this site:
http://blog.crowe.co.nz/archive/2006/03/02/589.aspx new=true]http://blog.crowe.co.nz/archive/2006/03/02/589.aspx[/url]

* Check the credentials for you TEMP directory.

* Save the Excel file in the TEMP directory otherwise Excel deadlocks while trying to open the file directly out sharepoint.

* Set the CurrentThread CultureInfo to en-US otherwise you get the message that the excel file can't be openened.

* create a FileInfo Object from the excel file in the TEMP dir and open the RemoveAllLinksFrom() method.

After the RemoveAllLinks method has been processed you can upload the file back in to sharepoint using the SPFILE object so that Excel Web Service doesn't give an error anymore.
add comment ( 3 views )   |  permalink   |   ( 2.9 / 691 )
Removing a lang taking retact or deploy sharepoint solution  
Thursday, April 10, 2008, 13:46 - SharePoint
Posted by Administrator
Recently i couldn't install my new created solution because antorher retracting process was still active.

I waited for about 30min until i entered some panic mode but almost instantly a smile turned my face from a thundercloud to the happy me.

I found this blog entry by Alex Thissen:
http://www.alexthissen.nl/blogs/main/ar ... tions.aspx

At the end this is what matters:

add comment ( 3 views )   |  permalink   |  related link   |   ( 2.9 / 555 )
Restore local developping sharepoint enviroment to production 
Tuesday, April 8, 2008, 09:02 - SharePoint
Posted by Administrator
1. development environment
Try to export your web application with the stsadm command line

stsadm -o backup -url http://mydevwebapplication:myportnumber -filename c:\backup.back

2. Copy your backup.back file on your production environment
Start your central admin console on this environment
Create a web application
Create a site collection with the same name as your development environment
Execute the stsadm restore command line
stsadm -o restore -url http://myprodwebapplication:myportnumber -filename c:\backup.back -overwrite


add comment ( 4 views )   |  permalink   |   ( 3 / 519 )
SHAREPOINT SITE DELETE CAPTURE 
Friday, April 4, 2008, 14:13 - SharePoint
Posted by Administrator
Introduction
The Microsoft IT Site Delete Capture Feature 1.0 is a shared component assembly (DLL); by registering the Microsoft IT Site Delete Capture Feature 1.0 shared component assembly in the Global assembly cache SharePoint Products and Technologies

administrators can intercept both site/web delete requests and archive the site/web to a resource local to the web front-end computer or UNC path before the site/web is removed the configuration and content databases.

The Microsoft IT Site Delete Capture Feature 1.0 also exposes functionality allowing SharePoint Products and Technologies administrators to send e-mail messages to the end-user indicating the site has been archived and deleted, any failure in the event receiver will generate an e-mail message to the end-user indicating that the site/web has not been deleted. The message format, text, and language are stored in a flexible, culture-independent extensible markup language configuration file.

http://www.codeplex.com/governance
Download From here
add comment ( 5 views )   |  permalink   |   ( 3 / 615 )

<<First <Back | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | Next> Last>>