Sharepoint : Div tag with ExternalClass

December 16, 2014

Every time I insert enhanced rich text in a field in SharePoint and
save it, SharePoint inserts DIV tags with an external class reference
around my content.

Why does it do this? Where is this class? What does it specify?

have multilined text field. When it is empty it is rendering in the list view as below. Can anyone tell me why and how to fix it?

– See more at: http://www.go4sharepoint.com/Forum/externalclass-enhanced-rich-text-fields-7091.aspx#sthash.lS18KFks.dpuf

Solution :

You can use Regex.Replace(currentItem[“Your Field Name”].ToString(), “”, string.Empty); Basically this will replace your div tag with empty string so you will get your plain text

http://www.sp-blogs.com/blogs/adnan/Lists/Posts/Post.aspx?ID=15

In Jquery use regex like this – stringvalue.Replace(“”, “”);


Sharepoint 2010 and 2013 : managed metadata columns

February 26, 2013

If the requirement is like you want to manage all your default values for columns from central place then create Managed metadata ..

http://www.jasperoosterveld.com/2013/02/sharepoint-2013-managed-metadata-and.html


SharePoint 2013 is out

July 18, 2012

 

Please check the link below indicating the new offerings from Microsoft.  Fantastic feature in SharePoint 2013.

 

http://www.c

 

 

Please check the link below indicating the new offerings from Microsoft.  Fantastic feature in SharePoint 2013.

 

 

 

http://www.collaboris.com/blogs/collaboris-blog/mark-jones/2012/07/16/office-2013-beta-launch-live-blog-from-steve-ballmers-announcement

 

 

ollaboris.com/blogs/collaboris-blog/mark-jones/2012/07/16/office-2013-beta-launch-live-blog-from-steve-ballmers-announcement

 


How To: Add Time/Date to Layouts or Master Page

May 9, 2012

Source :

 

http://erikswenson.blogspot.in/2012/03/how-to-add-timedate-to-layouts-or.html

To add this JavaScript to your page layout do the following:

  1. Add in the following code anywhere within your page layout:
    <table cellpadding=”0″ cellspacing=”0″>
        <tr>
            <td valign=”top”>
                <script type=”text/javascript”>
                    function getClockTime()
                    {
                        var now    = new Date();
                        var hour   = now.getHours();
                        var minute = now.getMinutes();
                        var second = now.getSeconds();
                        var ap = “<span class=’company-homepagetime-ampm’>AM</span>”;
                        if (hour   > 11) { ap = “<span class=’company-homepagetime-ampm’>PM</span>”;}
                        if (hour   > 12) { hour = hour – 12;      }
                        if (hour   == 0) { hour = 12;             }
                        if (minute < 10) { minute = “0” + minute; }
                        if (second < 10) { second = “0” + second; }
                        var timeString = hour +
                            ‘:’ +
                            minute +
                            ” ” +
                            ap;
                        return timeString;
                    } // function getClockTime()
                        var clockTime = getClockTime();
                        document.write(clockTime);
                </script>
            </td>
        </tr>
        <tr>
            <td valign=”top”>
                <script type=”text/javascript”>
                    var months=new Array(13);
                    months[1]=”January”;
                    months[2]=”Febuary”;
                    months[3]=”March”;
                    months[4]=”April”;
                    months[5]=”May”;
                    months[6]=”June”;
                    months[7]=”July”;
                    months[8]=”August”;
                    months[9]=”September”;
                    months[10]=”October”;
                    months[11]=”November”;
                    months[12]=”December”;
                    var day=new Date();
                    var lmonth=months[day.getMonth() + 1];
                    var date=day.getDate();
                    var year = day.getFullYear();
                    document.write(lmonth + ” ” + date + “, ” + year);
                </script>
            </td>
        </tr>
    </table>
  2. Then Add in the following CSS to give it a little style
    .company-homepagetime{
        color: #000;
        font-family: Arial, sans-serif;
        font-weight: normal;
        font-size: 30px;
        text-align: left;
        padding: 10px 0px 0px 15px;
    }
    .company-homepagetime-ampm{
        color: #000;
        font-family: Arial, sans-serif;
        font-weight: normal;
        font-size: 20px;
        text-align: left;
    }
    .company-homepagedate{
        color: #000;
        font-family: Arial, sans-serif;
        font-size: 14px;
        text-align: left;
        text-transform:uppercase;
        padding: 0px 0px 0px 17px;
    }

The result should look similar to the following:


Sharepoint Notes : Content Types – Featurs

December 24, 2011

 

——————————————————————————–
http://office.microsoft.com/en-us/windows-sharepoint-services-help/introduction-to-content-types-HA010121570.aspx

What is a content type?
In the course of a single project, a business might produce several different kinds of content, for example, proposals, legal contracts, statements of work, and product design specifications. Although these documents might be stored together because they are related to a single project, they can be created, used, shared, and retained in different ways. A business might want to collect and maintain different kinds of metadata about each kind of content.

Windows SharePoint Services 3.0 enables organizations to define these different sets of documents as content types. A content type is a group of reusable settings that describe the shared behaviors for a specific type of content. Content types can be defined for any item type in Windows SharePoint Services 3.0, including documents, list items, or folders. Each content type can specify:

The columns (metadata) that you want to assign to items of this type.
The document template on which to base new items of this type (document content types only).
The custom New, Edit, and Display forms to use with this content type.
The workflows that are available for items of this content type.
The custom solutions or features that are associated with items of this content type.
Content types provide organizations with a way to manage and organize content consistently across different lists and libraries in a site collection (site collection: A set of Web sites on a virtual server that have the same owner and share administration settings. Each site collection contains a top-level Web site and can contain one or more subsites.), and they also make it possible for a single list or library to contain multiple item types or document types.

 

————-

 

A content type is a reusable collection of metadata (columns), workflow, behavior, and other settings for a category of items or documents in a Microsoft SharePoint Foundation 2010 list or document library. Content types enable you to manage the settings for a category of information in a centralized, reusable way.

For example, imagine a business situation in which you have three different types of documents: expense reports, purchase orders, and invoices. All three types of documents have some characteristics in common; for one thing, they are all financial documents and contain data with values in currency. Yet each type of document has its own data requirements, its own document template, and its own workflow. One solution to this business problem is to create four content types. The first content type, Financial Document, could encapsulate data requirements that are common to all financial documents in the organization. The remaining three, Expense Report, Purchase Order, and Invoice, could inherit common elements from Financial Document. In addition, they could define characteristics that are unique to each type, such as a particular set of metadata, a document template to be used in creating a new item, and a specific workflow for processing an item.

Content Type Scope

The Microsoft SharePoint Foundation site in which you create a content type determines its scope—that is, the extent of its availability. A site content type becomes available to lists and document libraries within the site on which the content type is created, and also to lists and document libraries in any child site.

Content Type Features
——————————————————————————–

Content types are a site-scoped Feature. Features are a way of encapsulating SharePoint Foundation functionality for ease of distribution and deployment. Features provide a mechanism by which you can package the files that a solution needs, such as content types, Web Parts, lists, and site definitions. You can package the necessary files into a .wsp file, which is basically a .cab file that contains a manifest that lists its contents.

Inside the Feature, the feature.xml file contains references to all the element manifests within that Feature. Content type definitions are element manifests. You must create a content type definition for each content type that is included in your Feature.

 


Sharepoint : Default approval workflows

December 24, 2011

Default approval workflows

Microsoft SharePoint Server 2010 includes several approval workflows that you can begin using right away to manage human workflows in your organization. Each workflow can be added to a list, library, or content type and then used by your business users to manage the items or documents in the associated lists or libraries.

You can use the workflows to run document approvals, collect feedback, collect signatures, manage publishing of assets, manage dispositions, and create three-state approvals. When you associate and initiate the workflow, you can change the basic behaviors of the workflow, like who approves it, how the tasks are assigned, duration, due dates, workflow messages, and so on. For most of the workflows, you can also customize them in SharePoint Designer 2010.

Each workflow is described below, including the main differences between the workflows, and whether they’re supported for customization in SharePoint Designer 2010.

Workflow Description In SharePoint Designer
Approval The Approval workflow routes a document or item to a group of people for approval.

It supports staged approvals whereby the first set of approvers can review and approve, then the next set of approvers can review and approve, and so on. Each stage of approvers can do review in serial order (one at a time), parallel order (all at once), and normal serial or parallel task assignments that were supported in SharePoint Server 2007.

The duration and due dates of the task can be specified in days, weeks, and months, as well as a final due date for all of the tasks in the workflow. You can individuals to the CC (carbon copy) field. The workflow can be set up to end when the first approver rejects it. It can end if the document being review is changed. And, the workflow can enable content approval, if you like.

The tasks and emails in the workflow request content approval, so the task form includes buttons for Approve, Reject, Request Change, and Reassign. For approvers, comments support a consolidated comment that shows the entire list of previous approvers’ comments. Approval workflows can also be used to set content approval status at the end.

The Approval workflow is by default associated with the Document content type so it is available to document libraries.

NOTE: This workflow is only available in SharePoint Server 2010.

Yes
Collect Feedback The Collect Feedback workflow is very similar to the Approval workflow. It routes items or documents to a group of people, but in this case, the workflow is designed to get feedback from the approvers. The feedback is compiled and sent back to the person who initiated the workflow.

Like the Approval workflow, this workflow supports staged approvals and lets you specify duration and due dates in days, weeks, and months, as well as the final due date. The workflow can also be set up to end if the document is changed, and you can add individuals to the CC (carbon copy) field.

Unlike the Approval workflow, there is no option to end the workflow on first rejection since that doesn’t apply here, and there is no option to enable content approval.

Since the tasks and emails in the workflow request content approval, the task form includes buttons for Send Feedback, Request Change, and Reassign.

The Collect Feedback workflow is associated with the Document content type so it is available in document libraries.

NOTE: This workflow is only available in SharePoint Server 2010.

Yes
Collect Signatures The Collect Signatures workflow routes documents created in a Microsoft application to a group of people to collect their digital signatures.

You can add signers in serial or parallel order, and you can add them in stages. You can also add individuals to the CC (carbon copy) field. There are no other fields or behaviors for this workflow (unlike the Approval and Collect Feedback workflows).

When the signers of the workflow receive the task, they can sign it from the Task list in SharePoint or from within the host document, such as Microsoft Word, Excel, and PowerPoint.

The task form includes buttons for Sign or Reassign the task only. The signing mechanism uses the Microsoft Office Signature Line control. The signature image can be provided by the user or applied automatically using logic in the form (specifically, rule and action in the InfoPath form).

The Collect Signatures workflow is associated with the Document content type so it is available in document libraries However, the workflow will only appear in the library if that document contains one or more Microsoft Office Signature Lines.

NOTE: This workflow is only available in SharePoint Server 2010.

Yes
Publishing The Publishing workflow routes content for approval in the same the Approval workflow does this except that it’s designed for Enterprise Content Management sites with publishing features enabled.

Another difference is in the workflow forms. The association and initiation forms hide the option to add approvers, end workflow on first rejection, end workflow if document changes, and enable content approval.

NOTE: The Publishing workflow is only available in SharePoint Server 2010 where the Publishing feature is enabled.

Yes
Three-state The Three-state workflow tracks the status of an issue or item through three states and two transitions between the states, which help track high volume issues.

The workflow is designed to work with the Issue Tracking list template but can be used with any list that has a Choice column with three or more values that serve as the state of the workflow.

Participants in the workflow may be working with the list directly or outside projects related to the list. The workflow updates the status of the list and creates a new task for the next participant, and this process continues.

Workflow participants can change the complete their task or change the status of the workflow item.

NOTE: This workflow is available in both SharePoint Foundation 2010 and SharePoint Server 2010.

No
Disposition Approval The Disposition Approval workflow tracks content that has expired or is out-of-date and needs to be evaluated or deleted.

This workflow is especially useful on a Records Center site or a site that supports records management document retention policies. The workflow can be configured to start automatically when documents or items expire or started manually by participants.

The workflow uses Disposition Approval workflow tasks for specific documents and items in the tasks list rather than assigning them to specific participants. Only those who have permissions to this tasks list can complete the task by approving or rejecting items for deletion.

The workflow also includes bulk task completion so that individuals can process large numbers of items for deletion in one step. This is commonly needed because of the high volume of tasks generated by the workflow.

NOTE: This workflow is only available in SharePoint Server 2010.


Introducing Dynamic Management Objects (DMO) in Sqlserver

October 25, 2010

Dynamic Management Objects (DMO)

Dynamic Management Views(DMV) ,  Dynamic Management Functions(DMF)

Execution :  Starts with sys.dm_exec

1 . sys.dm_exec_connections ( Get a count of SQL connections by IP address)

2. Session Ownership (sys.dm_exec_sessions)

3. Current expensive, or blocked, requests (sys.dm_exec_requests ,sys.dm_exec_sql_text)

4 .Query Stats – Find the “top X” most expensive cached queries  (sys.dm_exec_query_stats)

5 How many single-use ad-hoc Plans? (sys.dm_exec_cached_plans)

6 DMV#6: Ad-hoc queries and the plan cache (sys.dm_exec_cached_plans and sys.dm_exec_sql_text)

7 Investigate expensive cached stored procedures ( sys.dm_exec_procedure_stats )

8  Find Queries that are waiting, or have waited, for a Memory Grant (sys.dm_exec_query_memory_grants)

Transactions : begin with “sys.dm_tran_”.

1. Monitor long-running transactions (    sys.dm_tran_database_transactions ,  sys.dm_tran_session_transactions)

2. Identify locking and blocking issues (    sys.dm_tran_locks )

Database and Indexes:  Starts with sys.dm_db_

  1. sys.dm_db_missing_index_groups
  2. sys.dm_db_missing_index_group_stats
  3. sys.dm_db_missing_index_details
  4. Interrogate Index usage            sys.dm_db_index_usage_stats,
  5. Table Storage Stats (Pages and Row Counts)        sys.dm_db_partition_stats
  6. Monitor TempDB         sys.dm_db_file_space_usage

Disk I/O

1.  sys.dm_exec_query_stats – IO that a given query has cost over the times it had been executed

2.  sys.dm_exec_connections – IO that has taken place on that connection

3.  sys.dm_exec_sessions – IO that has taken place during that session

4.  sys.dm_os_workers – IO that is pending for a given worker thread

5.  Investigate Disk Bottlenecks via I/O Stalls ( sys.dm_io_virtual_file_stats)

6.  Investigate Disk Bottlenecks via Pending I/O  (sys.dm_io_pending_io_requests)

Operating System :  “sys.dm_os_”,

  1. sys.dm_os_wait_stats(Returns information about all the waits encountered by threads that executed)
  2. sys.dm_os_performance_counters(exposes the PerfMon counters)
  3. sys.dm_os_sys_info  (Basic CPU Configuration)
  4. sys.dm_os_ring_buffers(CPU Utilization History)
  5. sys.dm_os_schedulers (Monitor Schedule activity)
  6. sys.dm_os_sys_memory  (System-wide Memory Usage)
  7. sys.dm_os_sys_memory  (System-wide Memory Usage)
  8. sys.dm_os_memory_cache_counters (Investigate Memory Usage Across all Caches)
  9. sys.dm_os_memory_cache_counters (Investigate Memory Usage Across all Caches)

Miscellaneous

  1. sys.dm_clr_tasks Rooting out Unruly CLR Tasks
  2. sys.dm_fts_active_catalogs Full Text Search
  3. dm_db_mirroring_auto_page_repair Page Repair attempts in Database Mirroring

 

Download the pdf : http://ahref=

Download the word document : Important Notes

http://ahref=