sharepoint

SharePoint Designer Keeps turning 
 within source code into literal new line.

I am using an if statement that tests the amount of lines in a cell. <xsl:if test="string-length(@Example) - string-length(translate(@Example, '&#xa;', '')) &lt; 10"> When I type in this code and hit save, that code turns into this: <xsl:if test="string-length(@Example) - string-length(translate(@Example, ' ', '')) &lt; 10"> Instea...

small description window on mouse hover on hyperlink

Hi i have a sharepoint custom list and we have 2 columns in there URL and description. i have a list webpart which shows all the URLs from the sharepoint list. But when i mouse hover on the link i would like to show description for that link in a small window. Can anyone please help me implementing this using jquery. Jquery should be a...

Sharepoint + Value does not fall within the expected range + SPListItem

Looks like other people have had this issue, but I would like to understand how to target a column if there are spaces in a list column name when using the code below. Here is what I have: SPWeb oWebsite = SPContext.Current.Web; SPList oList = oWebsite.Lists["Project Info"]; SPListItemCollection collItem = oList.GetItems("Pr...

When does Sharepoint List ItemDeleting event actually fire?

We would like to block the deletion of documents in a list based on some custom functionality. What we have tried is to implement this in the ItemDeleting event. Where we set the cancel property of SPItemEventProperties to true when we do not want the user to be able to delete a document. What happened was that the Delete option in the...

DefaultAssetImageLocation property of RichImageField control does not work

I would like to have the "Look In" of the Asset Picker to default to the Site Collection Images for a given RichImageField. I tried using the DefaultAssetImageLocation attribute, but it doesn't seem to work properly. I found that unanswered post on msdn: http://social.technet.microsoft.com/Forums/en/sharepoint2010customization/thread/ba...

Error Code: 3604 when deleting file from SharePoint Document Library

I'm developing a WebPart in SharePoint 2007 and sometimes when I try to delete a file from Document Library with code like this: SPWeb web = SPControl.GetContextWeb(WebPart.WebPartContext); SPList list = web.GetList(web.Site.Url + "/ListName"); SPFile file = list.GetItemByUniqueId(new Guid(fileId)).File; file.Delete(); I get follo...

number of results for a specific keyword from the share point queryservies web service.

how to get the number of results for a specific keyword from the share point queryservice web service. ...

Error During import user from AD to my custom webpart.

I am trying to get user from active directory in my webpart but i am sruck somewhere please help me my code is as below. using System; using System.Runtime.InteropServices; using System.Web.UI; using System.Web.UI.WebControls; using System.Web.UI.WebControls.WebParts; using System.Xml.Serialization; using System.DirectoryServices; using...

Create folder in Sharepoint

I need to create a folder in the root directory of Sharepoint 2007. ...

Selected items on a sharepoint 2010 listitemcollection

Is there a way to get just the selected items of a document library from the server side? I was looking for something like this: SPDocumentLibrary docLib = web.Lists[list.Title] as SPDocumentLibrary; SPListItemCollection items = docLib.Items; foreach (SPListItem item in items){ //if (item.Selected) } ...

Is is possible to perform operations on a Sharepoint server file store from an external server?

I need to organise a bunch of files being stored on a Sharepoint server. I have a login to Sharepoint and privileges to modify files, but no access to any scripting or admin settings. The quickest way to make these changes currently is to "Open with windows explorer" - some kind of windows file server thingy, and that's very slow. I wan...

SharePoint Development in C# + Best way to deal with error handling

I have been developing pages and web parts in SharePoint 2007/2010 for the past year. One of the things that I always incorporate in my code is try/catch blocks to deal with error handling if an exception is thrown. That way, if I have a web part that breaks, I show a nice error message to the user in that specific web part, rather than ...

Sharepoint Services - List - Create view items created by {who ever logged in}

I have list where users can see all items, but only edit items they created. Is there a way I can create a 'Created by {User}' view? ...

MultipleBaseAddressBasicHttpBindingServiceHostFactory or WebScriptServiceHostFactory for SharePoint 2010 Web Service?

When it comes to creating a new Service running on SharePoint 2010, people seem to usually use the Sharepoint MultipleBaseAddressBasicHttpBindingServiceHostFactory. However, I would like to use the standard .net/WCF WebScriptServiceHostFactory instead because this gives me JavaScript code by calling the Service URL with /js. My Service...

help for creating web part for refreshing page

Hi , I'm fairly new to Sharepoint 2007 , I use a content editor webpart for refreshin page in sharepoint portal. i use following code in Source Editor of CEWP: <script type="text/javascript" language="javascript"> var reloadTimer = null; var sURL = unescape(window.location.pathname); function setReloadTime(secs) { ...

Unable to deploy my custom DLL to Sharepoint site

I created my custom assembly that has a simple HttpModule in it that I'd like to use in my Sharepojnt 2010 site. I added my module to sharepoint site's web.config/system.webServer/modules section. I then also copied my DLL directly to bin folder since that's how suual asp.net applications work. I got an exception about failed AspNetHos...

How to get Sharepoint User object from the "AssignedTo" field using client side object model ?

I am using managed client side object model in sharepoint 2010. And I want to get loginaName of the AssignedTo user in Task list. In server side object model I use SPFieldUserValue.User.LoginName to get this property but in client side object model FieldUserValue.User does not exists. How can I resolve this situation ? Thanks ...

How do I add a code-behind to a Sharepoint 2010 master page?

As part of our branding of Sharepoint 2010, we'll be modifying some custom HTML menu's based on database and user permissions. To do this, we are looking at the use of code-behind in a custom Sharepoint 2010 master page. The only reference I can find to creating a code-behind file for sharepoint 2010 is this blog post series. The issue...

How to grouping questions into sections and create descriptions in Sharepoint 2007 Surveys

Hi all, I would like to create a SharePoint 2007 survey with an introduction and background to the survey; confidentiality note at the beginning of the survey. I would also like to group questions into sections such as Personal Details (for questions 1 - 6), Training Needs (for questions 7 - 10), Challenges (for questions 11 - 25), etc....

Using sharepoint to pass credentials to other sites

Hi, being completely new to the Sharepoint scene, I was wondering what basic solutions are to the problem I'm facing. I have 2 different webapplications, which are both accessed by my clients by different logins. I want to simplify things and let them just log in on a Sharepoint application, so they have 2 links on their portal to t...