sharepoint

MOSS 2007 -- Invalid URL Exception SPSite.OpenWeb(...)

This may seem a bit trivial, but I have not been able to figure it out. I am opening up a SPSite and then trying to open up a SPWeb under that SPSite. This is working fine on the VPC, which has the same Site Collection/Site hierarchy, but on production, I get an exception telling me that the URL is invalid when I try the SPSite.OpenWeb...

Issue with database connection from sharepoint workflow with integrated security options

Good morning everyone, I'm running into an issue using a SharePoint workflow project (C#, VS 2008) and connecting to a database. Here is my database connection string: Data Source=DBSERVER;Initial Catalog=DBNAME;Integrated Security=True; When I attempt to run the following code I get the following error ... SqlConnection dbEngin...

MVC with SharePoint

Hi, We are looking to use the MVC Framework in our SP Application. This is what we are trying to accomplish... A virtual directory within the SPSite which can host and run MVC. for e.g., /_layouts/MVC/ Any hints on the required configuration changes (if at all this is possible) will be very helpful. Kind regards, Ashish Sharma ...

SharePoint site definitions not showing up in template list -- why?

I have some custom SharePoint site definitions that are deployed via SharePoint wsp solution packages. They appear to work fine. I can deploy them fine via the stsadm command line, and my C# code running in some features can also deploy sites based on them. My webtemp.*.xml files appear to be correctly placed in the 12\1033\XML folde...

SharePoint does not find my custom RenderingTemplate

So I've created a custom RenderingTemplate and deployed it to CONTROLTEMPLATES\MyControlTemplates\ It basically dictates how a custom content type that i've created should be rendered when displayed. For that I've added this: <FormTemplates xmlns="http://schemas.microsoft.com/sharepoint/v3/contenttype/forms"&gt; <Display>CustomDispF...

Removing contents of PlaceHolderPageTitleInTitleArea

Hi, In sharepoint there is a content place holder called PlaceHolderPageTitlteInTitleArea. I'm trying to remove everything in it from a custom RenderingTemplate that I placed in CONTROLTEMPLATES. So is it possible to achieve this either by using inline code or some other ways. Right now I've fixed it with this code in my SharePoint:Ren...

Why is Microsoft.SharePoint.Search.dll copied in my project?

When working on a VS2005 project that involves referencing Microsoft.SharePoint.dll, building the project causes Microsoft.SharePoint.Search.dll to be copied to my bin folder. Why is this? Okay, maybe it's just a bug, but I want to know the mechanism. [Edit: Copy local is most definitely turned off -- Microsoft.SharePoint.dll is not cop...

SharePoint, how do you programatically determine the storage size of a SPWeb?

Not of the site collection itself, but the individual SPWeb's. ...

How do I obtain the id of a workflow created in Sharepoint Designer?

I've written an event receiver that programmatically kicks off a workflow, but it needs the id (guid) of the workflow to start. How do I go about obtaining the id of the workflow(s) I just created in Sharepoint Designer? ...

Where is my Object being disposed?

I have a strange issue: I am using SPContext.Current.Web in a .aspx page, but at the end, I get a "Trying to use an SPWeb object that has been closed or disposed and is no longer valid." error message. From what I see, SPContext.Current.Web is Disposed by someone, but I have no idea where. I just wonder: With Visual Studio 2005's Debugg...

CAML query items with the given URLs

In SP2007/MOSS I need to run a CAML query against a single list like so: <Where> <Or> <Eq> <FieldRef Name='URL' /> <Value Type='URL'>/path/item1.aspx</Value> </Eq> <Eq> <FieldRef Name='URL' /> <Value Type='URL'>/path/item4.aspx</Value> </Eq> <Eq>...

Accessing a remote file with a SharePoint Web Part

I recently built a program that parses a remote file from \some_server\c$\directory\file.xls and it works fine on my local machine as just a normal aspx page. Then I put the program into web part form on my VM SharePoint server and I get this error: Access to the path '\some_server\c$\directory\file.xls' is denied. The fil...

Migrating from other Content Management Systems to SharePoint

I am currently working on a project which requires migration of content from different content management Systems to SharePoint. Are there any good, preferably open source, tools that would help me do this? Also, what are the best practices that I would have to keep in mind when it comes to such projects. One more thing that i would like...

SharePoint (MOSS) hosting with custom code allowed

I'm looking for a SharePoint (MOSS) shared hosting provider that supports deployment of custom solutions (.WSPs) - it'd be okay if it was medium trust. I'm building a public Internet site on SP and the client doesn't want to host it or pay for the license all up front. Any suggestions? ...

How does sharepoint recognize a file type?

How does sharepoint identify a file type? For example, SharePoint will not allow you to upload executable files. Suppose if i rename a file extension from .exe to say, .doc, will the sharepoint allow the upload of this file? ...

SharePoint interview questions

Let's have a list of some good interview questions for SharePoint developers. Please provide one question per entry, and if possible, the answers. Also, please feel free to suggest corrections if the provided answers are wrong. I will go first: Q: How does SharePoint store pages? A: How-to-locate-sharepoint-document-library-source-p...

Data disappearing after ItemUpdate in Sharepoint with Office 2007 documents

I have a simple event handler with a ItemAdding event that changes a column value that I need in the ItemUpdated method. After uploading a word 2007 document (*.docx, *.pptx or xlsx) the value of the column is changed, but when I protect the document the value of the column disappears in the ItemUpdated method. This only happens for off...

What user context do SharePoint timer jobs run under?

What user context do SharePoint timer jobs run under? The farm account? I'm going to be accessing some external resources (network share) via the timer job, so I need to know which SharePoint service account to grant permissions. ...

How do I get the URLs from any tab in any open browser

I am trying to detect which web in sharepoint that the user is looking at right now. One approach could be to read the URls from the browser and try to compare them to a reference URL to the sharepoint solution. I have not yet been able to locate any solution that works in both IE and Firefox. The idea is to write a small C# app that wi...

What is the most wanted SharePoint feature?

Are you the one that thinks: "Only if I had this thing available for me, I'll use SharePoint solution to solve my day-to-day problems?" What do you miss in the SharePoint functionality that can make you happy? What are the use cases that you think that SharePoint can solve for you but you miss something to make that happen? Is it a w...