I've been trying to create a custom alert for SharePoint 2010 using the following guidelines : http://support.microsoft.com/kb/948321/en-us
At this point I haven't succeeded in getting the alert to work. I was wondering of this guide also applies for SharePoint 2010. Because at the button of the article is clearly states:
APPLIES TO
Microsoft Office SharePoint Server 2007
Microsoft Office SharePoint Server 2007 for Search (Enterprise Edition)
Microsoft Office SharePoint Server 2007 for Search (Standard Edition)
Can anyone enlighten me?
Kind regards
Oxillery
I have it working in 2010.
A new Alert Template.
a.Original is found here:
\14\TEMPLATE\XML\alerttemplates.xml
b.The custom templates are found in this file which has the original definitions plus the custom definitions.
CCPersonalAlertTemplates.xml
c.Load them with stsadm
stsadm.exe -o updatealerttemplates -url "http://Beefy.com/Sites/my_name" -filename " \CCPersonalAlertTemplates.xml"
d.Every out of the box solution has a matching custom template.
The custom templates have a .ext at the end of their name.
The custom features also call a custom NotificationHandlerAssembly like this:
<Properties>
<NotificationHandlerAssembly>Shared.CCPersonalEmail, Version=1.0.0.0, Culture=neutral, PublicKeyToken=5694e116d3fc8c0c</NotificationHandlerAssembly>
<NotificationHandlerClassName>Shared.CCPersonalEmail.CCPersonalClass
</NotificationHandlerClassName>
<NotificationHandlerProperties />
</Properties>
Custom Notification Handler assembly
a.IAlertNotifyHandler that implements an OnNotification method
- Attempts to send the custom alert (if it fails send normal alert.)
Custom alert:
Gets the PersonalEmail field data from the User Information List
If Personal Email is empty it just sends normal alert
If personal email is populated
Send normal email to internal email
Send reduced email to external address
Replace http:// with external address http://extranet-
Regex replace (keep content data from being sent)
<td class=\"formlabel\">.*<td class=\"altvb\"> </td>
Make all the alerts use the external template
Existing alerts:
Site.allwebs.alerts get flipped to the same template name they had with .ext appended
Future alerts:
Site.allwebs.lists flipped the attached alerttemplates to their .ext counterpart
Future webs and their Future lists
SPListEventReceiver ListAdded() event flips the template on all lists created in the site collection
Housekeeping
a.During feature activation
create a PersonalEmail field on the rootweb’s User Information List (This becomes content so it is not removed upon deactivation)
flip all lists and alerts to the custom alert templates.
During feature deactivation
Flip all lists and alerts back to their respective out of box alert templates
Related
I have a scenario where my Outlook Web App Add-in looks for the same email by subject in a database through API. If this email found in the database, I want to mark that email with some categorization so that user can visualize which emails have already been in the Database.
I am using the Office.js to get the subject and pass it to the API as through ajax call. The API written in C# looks into the database and return true or false.
if it returns true, I want to mark this email with category red from the code automatically.
Red category means follows.
Currently, there is no way of dynamically setting categories.
We track Outlook add-in feature requests on our user-voice page. Please add a feature request there. Feature requests on user-voice are considered when we go through our planning process.
I have a small VSTO add-in that I've used with Outlook 2010 for some time. A move to Office 2013/Outlook 2013 is soon happening and so the add-in needs to be re-written to work with Outlook 2013.
The Outlook add-in is triggered by a custom ribbon button. When triggered, the add-in will create a new meeting request window and fill the message body with some custom content. After which the user can complete the meeting request and send it if they so desire.
The issue I'm currently having is that previously, this message window was created using the CommandBarControl object to programmatically trigger a click of the "New Meeting" button in Outlook. This worked in previous versions of Outlook, but I gather that the CommandBarControl object has been removed from Outlook 2013 and now fails silently. This is indeed what I am seeing.
The original code that was being used to create the new meeting request is this:
Explorer activeExplorer = Globals.ThisAddIn.Application.ActiveExplorer();
CommandBarControl commandBarControl = activeExplorer.CommandBars.FindControl(Type.Missing, 1106);
commandBarControl.Execute();
appointmentItem = (AppointmentItem)Globals.ThisAddIn.Application.ActiveInspector().CurrentItem;
appointmentItem.MeetingStatus = OlMeetingStatus.olMeeting;
appointmentItem.RTFBody = message; // message is a byte array being passed in from elsewhere.
The FindControl() method is used to find the "New Meeting" button in Outlook and then Execute() a click action on that button.
An alternative might be something like this:
appointmentItem = (AppointmentItem)Globals.ThisAddIn.Application.CreateItem(OlItemType.olAppointmentItem);
appointmentItem.MeetingStatus = OlMeetingStatus.olMeeting;
appointmentItem.RTFBody = message; // message is a byte array being passed in from elsewhere.
appointmentItem.Display(false);
The second code block will also create a new meeting request window and works in Outlook 2013, however there are a couple of subtle but important differences with the second code block...
The created meeting request will not inherit the date and time that a user has previously clicked on in their calendar, instead it will default to the current date/time regardless of what date/time the user has clicked on in their calendar.
The created meeting request will not respect the situation where a user is creating a meeting request "on behalf of" another user, because it ignores which calendar has been clicked on before the user initiated the new meeting request.
So my question is this: how can one now programmatically create (using a VSTO add-in) a new meeting request in Outlook 2013 that will respect which calendar the user has clicked on before hand? That is, it will satisfy the above two requirements that previously using the CommandBarControl object managed to satisfy?
You are right, Command bars were deprecated in Office 2010. Now the Fluent UI is used instead. You can read more about the new UI in the following series of articles:
Customizing the 2007 Office Fluent Ribbon for Developers (Part 1 of 3)
Customizing the 2007 Office Fluent Ribbon for Developers (Part 2 of 3)
Customizing the 2007 Office Fluent Ribbon for Developers (Part 3 of 3)
You can run the required ribbon button programmatically using the CommandBars.ExecuteMso method (see the CommandBars property of the Explorer and Inspector classes). You just need to pass the idMso value of the built-in control you need to run. The following links provides lists of built-in controls for Office 2010 and 2013:
Office 2010 Help Files: Office Fluent User Interface Control Identifiers
Office 2013 Help Files: Office Fluent User Interface Control Identifiers
I am writing a custom piece of code that dynamically creates modified document libraries. I've attempted to create a document library template, which succeeds in the UI but cannot be found via-webservices.
So to get to the point - I am attempting to:
1. Set "Allow Management Of Content Types" on the list.
2. Add a new Content Type (Already Created) to the list.
3. Set the new content type as the default content type.
4. Remove the "Document" content type from the list.
So far I have succeeded in being able to "Apply" the custom content type but the others are evading my grasp. The methods I have attempted are through the Lists.asmx service and the method described here: http://msdn.microsoft.com/en-us/library/websvclists.lists.updatelist.aspx
I tried setting the Flags property and a few other potential candidates with no success and no error messages complaining about what I was trying to attempt.
One limitation is that I do NOT have access to the sharepoint dll where this is living.
Once completed - this would be a plugin living in another non-sharepoint system. The only option to include the SharePoint client dll's would be to perform an ILMerge.
EDIT:
http://msdn.microsoft.com/en-us/library/sharepoint/jj193051.aspx (SharePoint 2013 Web Services)
http://msdn.microsoft.com/en-us/library/ee705814(v=office.16).aspx (SharePoint 2010 Web Services)
and yes - technically the ASMX services sound like they're on their way out: http://msdn.microsoft.com/en-us/library/sharepoint/jj164060.aspx
Edit: Tags are relevant to the question.
use SharePoint Client Object Model. This is a library that wraps calls to webservices that allows among other things to batch commands.
The operations you mention are all available.
here is a link to an article that explains Client Object Model:
http://www.codeproject.com/Articles/399156/SharePoint-2010-Client-Object-Model-Introduction
The article focus on ListItems but you can also interact with list properties, even web properties if you want.
Please note that you don't need to run Client Object Model from your sharepoint server. Note the "Client" part in the name.
I am creating an Outlook add-in using C# that searches for a link in an HTML (new) email body signature when a user clicks on Send button in Outlook email. I am hooking into Application_ItemSend event. What's odd is that on my machine running XP/Outlook 2007 and in another Win7/Outlook 2007 machine, I am able to search for the link in the signature with no problems. But on some other Win7/Outlook 2007 machine, I am not able to search for the link because an additional span element is being inserted by Outlook.
For example, I am searching for Link in an HTML (new) email body. The link above is being inserted by a default signature so I am expecting to find it all the time. On some machines I am able to, on some machines I am not able to because the link appears like this:
<span style='color:blue'>Link</span>
I've rolled out a standard signature html file so the signatures for all machines are the same, but the issue still persists. I am still in the process of comparing the font/theme settings, but so far have seen no difference.
Does anyone have an idea on what's happening here?
Thanks.
I'm using the Enterprise Library Logging application block to allow my application to log various events. This is working fine and the logs can be seen by Event Viewer (eventvwr.exe) going into the Application log.
However, Event Viewer always shows the user field as "N/A". Other applications have the field populated - how do I populate this field?
I have the current user logged into the extended properties of the log entry (using the UnmanagedSecurityContextInformationProvider). This means that I can capture the username and have it appear within Event Viewers 'Description' text box - but I cannot use EventViewer's filtering to see one user's log entries.
I've since found this question which suggests this is not possible without breaking into unmanaged Win32 API code - and a posting over on another site that has a MSFT employee stating the same.
Looks like I'll have to just put the username in the main body of the message.