dimanche 30 novembre 2014

SP2013 Cannot see my Master page under Design Manager



I created a Master page (new.master) using notepad and uploaded to "_catalogs/masterpage" of site collection root. After some approve and publish process I am able to change the site Master to the new.master.


However when I click on Design Manager > step 4. edit Master page, I can only see Oslo and Seattle. Same problem for step 6. edit page layout. When I click build page layout, in the Master page selection there are only Oslo and Seattle.


What did I missed?






How do display free booking dates in calender



how could i display for the user if an calender dateTime is bookes display other available dateTime that are free to book? for example in a range 3 days before and 3 days after, anny suggestions?



function checkFreebookingdateTime() {
try {
var listItemCustom = document.getElementById('datepicker').value;
var listItemFromTime = document.getElementById('timepicker').value;
var listItemtoDate = document.getElementById('datepickerto').value;
var listItemToTime = document.getElementById('timepickerTo').value;
var result = listItemCustom + "T" + listItemFromTime + ":00" + "Z";
var result2 = listItemtoDate + "T" + listItemToTime + ":00" + "Z";
var fromTime = new Date(result);
var toTime = new Date(result2);


getListCalender = document.getElementById('CalenderListDrop').value;
spHostUrl = decodeURIComponent(getQueryStringParameter('SPHostUrl'));
context = new SP.ClientContext.get_current();
parentContext = new SP.AppContextSite(context, spHostUrl);
web = parentContext.get_web();
list = web.get_lists().getByTitle(getListCalender);
context.load(list);
context.executeQueryAsync(
function() {

var camlQuery = new SP.CamlQuery();
camlQuery.set_viewXml('<View><Query><Where><And><Ge><FieldRef Name=\'EventDate\' /><Value IncludeTimeValue=\'TRUE\' Type=\'DateTime\'>'
+ fromTime.toISOString() + '</Value></Ge><Ge><FieldRef Name=\'EndDate\' /><Value IncludeTimeValue=\'TRUE\' Type=\'DateTime\'>' + toTime.toISOString() +
'</Value></Ge></And></Where></Query></View>');


this.collListItem = list.getItems(camlQuery);
context.load(collListItem);
},
function() {

alert(collListItem);


}
);

} catch (e) {
alert("");
}


}






SPListItemCollection Export To Excel timer job



I have a timer job that queries specific SPListItemCollection and transform it to DataTable.


I want to export this DataTable to an excel file that will be saved to a specific location (ftp)


how will I do the exporting to excel programmatically? can you share some code snippets that will work for this?


I have tried some codes but it asks me if I want to Save SaveAs or Cancel. What I want is it will immediately download this to a specific location (ftp)






How to link web parts from one dashboard to another using Sharepoint Online 2013?



I have two dashboards on two different pages in one subsite. I'm using two views FutureItems and PastItems. FutureItems is for one dashboard and PastItems for another. On each dashboard im using different webparts which is already connected to eachother. But now i want to make a connection for those web parts from one dashboard to another, any help please?

I'm doing eactly the same as given in the link below.


http://ift.tt/1v257LR


I'm using SharePoint Online 2013.


Thanks Amir






Word Automation Service fails



I am new to SharePoint and facing this problem in SP2013 I have used Word Automation Service which helps me to convert the Word file (which is actually a Template to which I am adding my data from various lists) to PDF using ConversionJob & ConversionSettings. this process works well for certain time limit without any error and i get expected output, the issue is this Conversion from Word to PDF fails suddenly and Word files created are not converted, there is no issue with generating word file. i have tried various ways but i am not able to trace the problem can anyone help me out or suggest ways






Creating new feature for list each time when we create a list with same ListTemplate attribure



We are facing following issues in SharePoint, when we create a custom list in visual studio a separate feature is created for each list automatically and type attribute in ListTemplate tag is set to 100, which should by default be auto generated unique id among that feature. This is causing issues when we deploy list.


This issue is arrising since we have created new development environment for SharePoint.


Old sharePoint environment was with visual studio Visual Studio Professional 2012 V 12.0.21005.1 REL


and new one is with SharePoint Server 2013 with latest cumulative update and Visual Studio Ultimate 2013 V 12.0.31101.00 Update 4


What can be the issue? How to proceed ahead ?


I will be pleased if you help me to solve the issue.


Thanks, Prasad






How Do I programaticaly display Survey List Result? or How Do I Identify Result Field?



I have created a survey List with SharePoint Server 2010 . I want To Display Survey List Result on Button Click.(MEANS: Trying to Retrieve Graphical Result Of Survey List WebPart ,and Trying To show it after button click )


How Do I Identify Result Field?






problem using JavaScript in SharePoint provider hosted app



I have created a provider hosted app for a SharePoint Online site and want to use JavaScript for most of the front end logic, rather than ASP.NET MVC


I have run into Cross domain problems trying to query REST endpoints from the SharePoint Online domain. this article gives advice on getring a basic example up and running for a JavaScript SharePoint provider hosted app, however it doesn't seem to work for me, as I don't have an SPAppWebUrl paramater in the url...


So I tried just using my app domain as the SPAppWebUrl which is something like http://ift.tt/12iMpc6 but it doesn't seem to work, giving the error


GET 404 http://ift.tt/1vyZOIM (Not Found)


That error makes sense to me, as the test app isn't a SharePoint Online site... If I change it to the SPHostWebUrl, it has the correct endpoint http://ift.tt/12iMpsm... but won't work because of the cross domain restriction, giving the error:


Uncaught SecurityError: Blocked a frame with origin xxxx accessing a frame with origin xxx. Protocols, domains, and ports must match.


Here is my code for a very simple JavaScript app to get some list data. The Endpoint opens fine in the browser when I set it to the SPHostWebUrl but not in the app due to the cross domain error



$(document).ready(function () {
$.getScript(
"Scripts/SP.RequestExecutor.js",
continueExecution
);
});

function continueExecution() {
// have tried both hostweburl and appweburl
executor = new SP.RequestExecutor(hostweburl);
getCustomers();
}

function getCustomers() {

// begin work to call across network
var requestUri = hostweburl + "/_api/Web/Lists/getByTitle('Customers')/items/"
+ "?$select=Id,FirstName,Title";

// execute AJAX request
executor.executeAsync({
url: requestUri,
method: "GET",
headers: { "ACCEPT": "application/json;odata=verbose" },
contentType: "application/json",
success: function (data) {
console.log(data);
},
error: function (data) {
console.log(data);
}
});
}





Public-facing on-premises SharePoint with NTLM authentication



I've been searching for authentication best practices for public-facing SharePoint site but I didn't find any useful resources on the issue that is troubling me.


Suppose I set up a web application with Classic NTLM authentication. On that web application I enable Anonymous access. This means that users inside organization's network will be able to authenticate (actually use SSO) using organization's DC. They will be able to access and administer all content. All other anonymous users will be able to see published content only i.e. content which is permitted to anonymous users.


My question is: Is this kind of setup a security issue because if a potential attacker hacks a WFE then he has direct access to DC?


Is FBA maybe a better solution for public-facing sites? Or maybe use NTLM, but create a separate domain with one-way trust to organization's domain?






Publishing or mirroring content from Drupal to SharePoint 2013



I'm fairly new to SharePoint, so apologies in advance if I'm asking a dumb question.


My company is rebuilding our intranet, and basing it on Drupal. We're also deploying SharePoint 2013 for content management, and we're trying to figure out the best place to store the help documentation for SharePoint.


I'm thinking it would be better if we stored it on the intranet because at least that way, people could still access it even if they were unable to log in to SharePoint. Storing it on the intranet also makes sense because that's where people expect to find other software-specific help documentation.


Here's my question: is it possible (or advisable) to store the documentation in Drupal and somehow mirror or link to it in SharePoint? If so, how? Thanks.






Allow others to see picture, but deny access to mysite



We are sharing parts of our SharePoint 2013 enterprise site with our customers. Security-wise this can be managed pretty well, but i have one problem. Customers do see employee photo & names (next to a post in a newsfeed) and they can also click that name to go to the employee mysite. Browsing to this mysite should not be possible, but, it do want the customer to see the employee picture in the newsfeed, and this picture also comes from a mysite location.


How can i set this up?






Using page title in Sharepoint 2013 content search webpart query



I'm creating a page layout using Sharepoint Designer 2013. I'm adding content search webparts into the page layout and would like to add a page title to the query in the content search web part.


Can this be done? Is it possible with ASPX or do I need Visual Studio?






Sync documents locally with O365



I am using O365 site in a company, and they have documents inside libraries, when I want to view a document, it's downloaded to my laptop. How do I keep the document sync that I open it from my laptop and it gets latest modifications from O365?






Field name already exists



All


I have backed up a sharepoint site and restored to another environment. I have a specific list which I want to update the default value of a hidden field in powershell


I found the field, set default value. But when I call field.Update() I see the error below.


I also see this error when I try to create and index on same list. I did quite a lot of search last 2 days, but no luck.


Do you guys have any idea?


Update : Exception calling "Update" with "1" argument(s): "Field name already e xists. The name used for this field is already used by another field in the list. Sel ect another name and try again." At line:1 char:14 + $field.Update <<<< ($true) + CategoryInfo : NotSpecified: (:) [], MethodInvocationException + FullyQualifiedErrorId : DotNetMethodException






Cannot Check In Document After a Document Library Has More Than 15 User-Defined Person Fields [SharePoint]



I am working with a document library in SharePoint 2010 which has 16 user-defined person / group columns (excluding created by, modified by, etc).


But a strange thing starts to happen when I checked in a checked out document. It shows a permission error, but it works when i tried to reduce the person / group columns to 15.


The same thing happened when I try to update a list item with my custom edit form, exception about permission (The document blabla has been modified by blabla), but it works when I reduce the person / group columns to 15.


Is there any limitations from Microsoft in maximum number of person / group in a document library? Because i've researched and found that 96 is the maximum number of person/group column in a list / document library (which means it should be fine in my case).


If it is not about the limit, then what is really happening with my document library?


Any help will be greatly appreciated.


Thanks.






samedi 29 novembre 2014

Moving 2 different SharePoint2013 servers to one installation



We have 2 different SharePoint 2013 servers installation in our organization. One runs on "http//production-portal" and other runs "http//test-portal". Due to some problems with production-portal, the test-portal is working perfect and we want to move the SharePoint 2013 to production-portal as we have only 1 SharePoint 2013 license (cannot afford two licenses). How can I do this? Both are different farms with different installation but on the same network.


Kindly help me to move my test server into production or merge both under same domain address.


The "http//test-portal" is on the trial development license.






SharePoint reporting services integration





I am using the SharePoint report services integration.

I deployed a report to a document library, but when I try to view the report (form SP), I receive this error:



login failed for user 'nt authority anonymous logon' sharepoint



If I open the report (with the same user) from the report builder client, it is working fine.

What is it wrong?


Thanks






List item limit breaks row hover effect



I have created a list and really like the way when you move your mouse of the an item the row highlights, the list I have has about 80 items and I wanted to show them all on the same page so I changed the item limit of the list to 80.


The problem is now the row hover effect is not working, how do I bring it back?






Refreshing webpart view automatically



I have a document library called 'Client Documents' that has a column called 'Client' and 'Document Type', when a user uploads a document to the library they select a client for example 'Microsoft' and then the document type 'Network Diagram'


I then created a view called 'Microsoft Network Diagrams' that filters the company name 'Microsoft' and the document type 'Network Diagrams' to just show me the documents for that client.


I then created a page with a webpart that connects to the document library 'Client Documents' and then I select the view 'Microsoft Network Diagrams' from the webpart options which works as expected.


The problem I have is if I make a change the to view I have to edit the webpart and re-select the view for it to update.


Is there a way for the view to update automatically on the page?






Stop users creating an infopath form if it already exists



I have a form library with the following content types


enter image description here


I have set each form to be saved with the following format Company Name - Network Information


We only need one network information form per customer that's why I set the filename structure this way using the concat function


So once the network information form has been created and information entered I will still need users to be able to go to the form and edit the info.


The problem I have found it if a user does not realize the network information form for the customer has been created, if they create the form again it will overwrite all the info in the original form


Hope that explains it better, thanks






run exe as process from sharepoint webpart



Im trying to run an exe file to create a contentdatabase and then create a sitecollection in this database, running this process is working well outside the sharepoint, but when im trying to run it from sharepoint it did nothing and no database creates.


this is my console app (exe file)



if (args != null)
{
string name = args[0];
string serverName = args[1];
SPWebApplication webApplication = SPWebApplication.Lookup(new Uri(args[2]));
SPContentDatabaseCollection dbc = webApplication.ContentDatabases;

var contentDatabase = new SPContentDatabase();
SPSecurity.RunWithElevatedPrivileges(delegate
{
contentDatabase = dbc.Add(
serverName,
"WSS_Content_" + name,
"",
"",
10,
20,
0);
contentDatabase.Update();
webApplication.Update();
});
}


and this im running in sharepoint webpart to run the exe file



SPSecurity.RunWithElevatedPrivileges(delegate
{
ProcessStartInfo pInfo = new ProcessStartInfo(@"C:\CreateContentdb");
pInfo.CreateNoWindow = false;
pInfo.UseShellExecute = false;

var arr = new string[] { name, dbServerName, webApplication.ToString() };
const string argsSeparator = " ";
string args = string.Join(argsSeparator, arr);
pInfo.Arguments = args;
Process.Start(pInfo).WaitForExit();





how to check Timer job error on production server



I am new to sharepoint and want to ask a question. I have to deploy a custom timer job on production and if there will be an error on production then how to debug it. what are the different ways to capture that error.






Create sharepoint app available to all ofice365 users?



I have an idea for some sharepoint app but I don't know much about sharepoint. I'm reading a lot about sharepoint and building apps for sharepoint but still I can't figure out how to implement my idea. So, some help would be appreciate it.


I want to have web app(hosted on my server) where any office365 user can go and see some information from his office365 sharepoint(assume that info can be pulled via rest api). So, my web app will ask user for his office365 url and then web app should call his office365 sharepoint via rest api to retrieve information.


I don't understand should I create sharepoint app on my sharepoint(for example: my sharepoint is mydomain.sharepoint.com)? If I create provider-hosted app on my sharepoint, will other office365 users, users outside my office365, be able to use that app? Should I use azureAD for authentication?


As I said at the beginning, I'm novice to sharepoint and a lot of new information just confused me.






how to reload the same web part after insert



I used !IsPostBack in Page_Load function.



protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{ }}


In my Page_Load function have lot of controls like textboxes and dropdown lists.


I need to reload the same web part(sharepoint 2010) after insert to the list. I used below code to reload page at the end of my submit button, but not working fyn (ie, Page_Load function is not working).



Response.Redirect(Request.RawUrl);





Erro on Uploading Document and Picking Up People in Sharepoint 2013



I recently implement Sharepoint 2013 on my Server . i found that when i want to upload document or Pick people with People Picker i have this error:



Log Name: Application
Source: System.ServiceModel 4.0.0.0
Date: 11/29/2014 2:25:44 AM
Event ID: 3
Task Category: WebHost
Level: Error
Keywords: Classic
User: CCI\sp-farm
Computer: Portal.CCI.Local
Description:
WebHost failed to process a request.
Sender Information: System.ServiceModel.ServiceHostingEnvironment+HostingManager/17010420
Exception: System.ServiceModel.ServiceActivationException: The service '/_vti_bin/client.svc' cannot be activated due to an exception during compilation. The exception message is: A binding instance has already been associated to listen URI 'http://portal.cci.local/_vti_bin/client.svc'. If two endpoints want to share the same ListenUri, they must also share the same binding object instance. The two conflicting endpoints were either specified in AddServiceEndpoint() calls, in a config file, or a combination of AddServiceEndpoint() and config. . ---> System.InvalidOperationException: A binding instance has already been associated to listen URI 'http://portal.cci.local/_vti_bin/client.svc'. If two endpoints want to share the same ListenUri, they must also share the same binding object instance. The two conflicting endpoints were either specified in AddServiceEndpoint() calls, in a config file, or a combination of AddServiceEndpoint() and config.
at System.ServiceModel.Description.DispatcherBuilder.InitializeServiceHost(ServiceDescription description, ServiceHostBase serviceHost)
at System.ServiceModel.ServiceHostBase.InitializeRuntime()
at System.ServiceModel.ServiceHostBase.OnOpen(TimeSpan timeout)
at Microsoft.SharePoint.Client.Services.MultipleBaseAddressWebServiceHost.OnOpen(TimeSpan timeout)
at System.ServiceModel.Channels.CommunicationObject.Open(TimeSpan timeout)
at System.ServiceModel.ServiceHostingEnvironment.HostingManager.ActivateService(ServiceActivationInfo serviceActivationInfo, EventTraceActivity eventTraceActivity)
at System.ServiceModel.ServiceHostingEnvironment.HostingManager.EnsureServiceAvailable(String normalizedVirtualPath, EventTraceActivity eventTraceActivity)
--- End of inner exception stack trace ---
at System.ServiceModel.ServiceHostingEnvironment.HostingManager.EnsureServiceAvailable(String normalizedVirtualPath, EventTraceActivity eventTraceActivity)
at System.ServiceModel.ServiceHostingEnvironment.EnsureServiceAvailableFast(String relativeVirtualPath, EventTraceActivity eventTraceActivity)





Content Query webpart - Showing extra info



I have added the content query webpart to my page which shows the top 10 rated client documents from a document library called 'Client Documents'


The columns I have created in the document library include:


Client


Document Type


Here are the properties I have selected


enter image description here enter image description here enter image description here


Everything is working fine and shows the top rated documents but I would like to present the information with the client name above the document name


enter image description here






SharePoint Online Admin Center Url



I'm looking to validate a sharepoint online admin url, will this always be username-admin.sharepoint.com.


Would it be safe to say that if a url ends with -admin.sharepoint.com is valid admin site?


If not, is there another way?






vendredi 28 novembre 2014

Link button issue inside gridview in sharepoint



i have link button inside gridview. can some one help me to form proper URL for this



<asp:TemplateField HeaderText="View" >
<ItemTemplate><asp:LinkButton runat="server" ID="lnkView" OnClientClick="OpenDialog('/SitePages/View%20Booking.aspx?','','');return false;" ><%#Eval("Booking Name") %></asp:LinkButton>

</ItemTemplate>

</asp:TemplateField>


if i use above, than popup opens fine on link button click but if append parameter as shown below, it throws error on load itself.



<asp:LinkButton runat="server" ID="lnkView" OnClientClick="OpenDialog('/SitePages/View%20Booking.aspx?BID="+ Eval("ID")+"','','');return false;" ><%#Eval("Booking Name") %></asp:LinkButton>


can some one help to form proper URL?






Is there any problem in Installing Sharepoint foundation patches and CU inside sharepoint server 2013 professional



I have live & staging SharePoint servers 2013. and i have installed the November 2014 CU on both of them, then i run the product configuration wizard. now when i run the following command on both servers



(get-spfarm).buildversion


on live i got:-



Major Minor Build Revision
----- ----- ----- --------
15 0 4641 1000


while on staging i got:-



PS C:\> (Get-SPFarm).BuildVersion

Major Minor Build Revision
----- ----- ----- --------
15 0 4667 1000


so why i have different build numbers (4641 & 4667). i have noted on my live server that windows update tool is showing the following update for SharePoint foundation server http://ift.tt/1FE0XQA (this update was installed by mistake inside my staging), so could this update cause the difference ?


second question. is there any problem of installing SharePoint foundation updates inside SharePoint server 2013 professional ?






Sharepoint server 2013 professional , is showing SharePoint foundation core patches



I have SharePoint server 2013 professional , as shown below:-


enter image description here


But when I checked the patches inside central administration web aplication, I found that I have many SharePoint foundation patches, as follow:-


enter image description here


Also when I create a new web application , I will get the following message that “The Microsoft SharePoint Foundation Web application has been created.”


enter image description here


So I am not sure what is doing on, do i have foundation or server license ? can anyone advice ?






Foundation 2010: add additional menu levels using spf-dropdown.js



This spf-dropdown.js script works fine adding a sub level drop down feature to the top link bar, but I need to add another level. Any menu item with "-- " in front of it gets inserted into a new ul dynamically appended to its parent li.


I'd like to also have items with "---- " inserted into a new ul attached to the first sub item li and triggered by a hover on the sub item. (If that makes sense).


So it would look like this:

Top level site

-- Sub item

---- Sub sub item


Here's the jQuery that's used - if anything else is needed, please let me know:



var namespace = namespace || {
init :
function () {
with (namespace) {
spfDropdowns();
}
},
spfDropdowns :
function () {
// get drop-down menu items
var dropDownItems = jQuery('.s4-tn li.static');

// tag submenu items as submenu items
dropDownItems.filter(':contains("-- ")').addClass('spfDropdowns-submenuitem');
dropDownItems.filter(':contains("---- ")').addClass('spfDropdowns-submenuitem2');


// move submenu items into a dynamically created submenus
dropDownItems.each(function(i,val) {
// hi, i'm the menu item
var $me = jQuery(this);
if ($me.hasClass('spfDropdowns-submenuitem')) {
// i don't need to tell you i'm a submenu item again, do i?!
this.innerHTML = this.innerHTML.replace('---- ','');
this.innerHTML = this.innerHTML.replace('-- ','');


// look back at the nav items before me, until you find my parent
var $parent = $me.prev(':not(.spfDropdowns-submenuitem)');
// my parent holds me in a submenu, so make sure it has one!
if(! $parent.hasClass('spfDropdowns-haschildren')) {
$parent.addClass('spfDropdowns-haschildren').append('<ul class="spfDropdowns-dynamic"></ul>');
}
// I give up and go to live with my $parent :)
$me.remove().appendTo($parent.children('ul.spfDropdowns-dynamic'));
$me.removeClass('static').children().removeClass('static');
$me.addClass('dynamic').children().addClass('dynamic');
}
});
jQuery('.s4-tn').addClass('processed'); // .s4-tn should now be hidden unless it has the .processed class
},

}
//queue for DOM load
jQuery(namespace.init);





Displaying parent data when selecting a child



I have a parent child relation between Organisation and Person and I need to select a person by displaying "Organisation name: Person name" to the user.


From what I have read it seems the only way to do this is to create a single line text field in the Person and populate it with a workflow.


Is there another/better way?






Search box not returning any results



I have a SharePoint 2010 solution.


I've started the search service application, enabled crawling, did a full crawl, and created a Search Center Sub site. I've also set up a crawl rule. Looking at the Crawl logs, there is data that is indexed, and ready to be returned in a search result.


However, when I go to my search center subsite on my sharePoint site, and search for a term, no results come back. I've tried several key words that are on the site, but no results.


Does anyone have any suggestions why there are no results being returned in search?






Where can I view a list of URL Suffixes for SharePoint 2013 like 'viewlist.aspx'?



I am interested in acquiring a list of suffixes that might be available in SharePoint 2013, as they were in SharePoint 2010, such as '/_layouts/15/sitemanager.aspx' or '/_layouts/15/viewlist.aspx.






Is there a way to monitor Newly created Index Component Sync Sp2013 search



I am in a process of fixing degraded Index Component in my search topology. I was able to remove and new index component. After i added index component now its stuck at status degraded, i know it takes some time before it comes online, but do we have any too to track the sync progress of that newly created index component.


Thank you






Visual Web Part with Web Part Zones



I am trying to create a unique component that has two Content Editor Web Parts. One of these will contain embed code showing a video, while the other one will contain description as HTML.


The idea is to keep both controls separate, but treat this as a unique Web Part so adding it to different pages will be easier.


Adding a Web Part Zone to a Web Part sounds weird, but I tried it anyway and I keep getting different errors. Is this even possible?


Would this be possible using a User Control instead?






Same question but different column names



Im sorry for bothering you again but when I tried the same formula but different column names it did not work... Column names for example are: F1 Makeup (26),F1 bridge tap (26),F2 bridge tap (26),F1 Makeup (26), f1 makeup(22), ETC Just for your reference)


below is the calculation that didn't work when I clicked save...


=IF([Circuit Type]="ISDN",(([F1 Makeup (26)] + [F1 bridge tap (26)] + [F2 Makeup (26)] + [F2 bridge tap (26)]) * 2.81) + (([F1 Makeup (24)] + [F1 bridge tap (24)] + [F2 Makeup (24)] + [F2 bridge tap (24)]) * 2.03) + (([F1 Makeup (22)] + [F1 bridge tap (22)] + [F2 Makeup (22)] + [F2 bridge tap (22)]) * 1.42) + (([F1 Makeup (19)] + [F1 bridge tap (19)] + [F2 Makeup (19)] + [F2 bridge tap (19)]) * 0.84),IF([Circuit Type]="56",(([F1 Makeup (26)] + [F1 bridge tap (26)] + [F2 Makeup (26)] + [F2 bridge tap (26)]) * 2.45) + (([F1 Makeup (24)] + [F1 bridge tap (24)] + [F2 Makeup (24)] + [F2 bridge tap (24)]) * 1.85) + (([F1 Makeup (22)] + [F1 bridge tap (22)] + [F2 Makeup (22)] + [F2 bridge tap (22)]) * 1.3) + (([F1 Makeup (19)] + [F1 bridge tap (19)] + [F2 Makeup (19)] + [F2 bridge tap (19)]) * 0.77),IF([Circuit Type]="19.2",(([F1 Makeup (26)] + [F1 bridge tap (26)] + [F2 Makeup (26)] + [F2 bridge tap (26)]) * 1.73) + (([F1 Makeup (24)] + [F1 bridge tap (24)] + [F2 Makeup (24)] + [F2 bridge tap (24)]) * 1.31) + (([F1 Makeup (22)] + [F1 bridge tap (22)] + [F2 Makeup (22)] + [F2 bridge tap (22)]) * 0.96) + (([F1 Makeup (19)] + [F1 bridge tap (19)] + [F2 Makeup (19)] + [F2 bridge tap (19)]) * 0.59),IF([Circuit Type]="DDS T.R",(([F1 Makeup (26)] + [F1 bridge tap (26)] + [F2 Makeup (26)] + [F2 bridge tap (26)]) * 1.91) + (([F1 Makeup (24)] + [F1 bridge tap (24)] + [F2 Makeup (24)] + [F2 bridge tap (24)]) * 1.46) + (([F1 Makeup (22)] + [F1 bridge tap (22)] + [F2 Makeup (226)] + [F2 bridge tap (22)]) * 1.08) + (([F1 Makeup (19)] + [F1 bridge tap (19)] + [F2 Makeup (19)] + [F2 bridge tap (19)]) * 0.64),IF([Circuit Type]="HDSL",(([ F1 Makeup (26)] + [F2 Makeup (26)]) * 3.88 + (([F1 Makeup (24)] + [F2 Makeup (24)]) * 2.84) + (([F1 Makeup (22)] + [F2 Makeup (22)]) * 2.18) + (([F1 Makeup (19)] + [F2 Makeup (19)]) * 1.5) + (([Num of F1 BTs + Num of F2 BTs]) * 3) + [Num of F1 Guage changes (HDSL)] + [Num of F2 Guage changes (HDSL)]),0)))))






Remote authentication using REST



I am trying to access SharePoint online using REST API's remotely. Office 365 Smart links are enabled for the site. As per this blog I don't receive wsse\\:BinarySecurityToken in the response. My code is as follows:



$.ajax({
'url': 'http://ift.tt/15HXUMk',
dataType: 'text',
type:'POST',
'data': '<s:Envelope xmlns:s="http://ift.tt/18hkEkn" xmlns:a="http://ift.tt/HKXHai" xmlns:u="http://ift.tt/Hm2joJ"><s:Header><a:Action s:mustUnderstand="1">http://ift.tt/1iRriyY s:mustUnderstand="1">http://ift.tt/1eD0XsE s:mustUnderstand="1" xmlns:o="http://ift.tt/LRW8Ij"><u:Timestamp u:Id="_0"><u:Created>2012-07-26T16:13:00.622Z</u:Created><u:Expires>2012-07-26T16:18:00.622Z</u:Expires></u:Timestamp><o:UsernameToken u:Id="uuid-69882db9-2d6b-45d3-b016-c2156cb6c01d-1"><o:Username>userid@something.com</o:Username><o:Password Type="http://ift.tt/1aTA7XU">*********</o:Password></o:UsernameToken></o:Security></s:Header><s:Body><t:RequestSecurityToken xmlns:t="http://ift.tt/1iRriz0"><wsp:AppliesTo xmlns:wsp="http://ift.tt/Hm2joK"><a:EndpointReference><a:Address>http://ift.tt/1uSZNKx;',
headers: {
Accept : "application/soap+xml; charset=utf-8"
},
success: function(result, textStatus, jqXHR) {
console.log('done in login ');
console.log('result '+result);
var xmlDoc = $.parseXML( result );
console.log("xmlDoc:"+xmlDoc);
var xml = $( xmlDoc )
console.log("xml:"+xml);
var binToken= xml.find( "wsse\\:BinarySecurityToken" ).text();
console.log("Binary Token:"+binToken);
alert("Binary Token:"+binToken);

// alert( localStorage.getItem('BinaryToken') );
wsignin(binToken);
},
error:function (jqXHR, textStatus, errorThrown){
console.log(errorThrown+'error login:' + jqXHR.responseText);
},
complete:function(jqXHR, textStatus) {
console.log('login completed ' + textStatus);
}
});


My response in fiddler is as follows:


<html><head><title>Working...</title></head><body><form method="POST" name="hiddenform" action="http://ift.tt/1sRvdjz"><input type="hidden" name="wa" value="wsignin1.0" /><input type="hidden" name="wresult" value="&lt;t:RequestSecurityTokenResponse xmlns:t=&quot;http://ift.tt/1uSZOhz xmlns:wsu=&quot;http://ift.tt/15HXV2M xmlns:wsu=&quot;http://ift.tt/1uSZOhE xmlns:wsp=&quot;http://ift.tt/15HXXrB xmlns:wsa=&quot;http://ift.tt/1uSZNKD MajorVersion=&quot;1&quot; MinorVersion=&quot;1&quot; AssertionID=&quot;_7f55172b-43f9-466c-bede-436d794119e2&quot; Issuer=&quot;http://ift.tt/15HXV2T; IssueInstant=&quot;2014-11-28T18:37:25.274Z&quot; xmlns:saml=&quot;urn:oasis:names:tc:SAML:1.0:assertion&quot;>&lt;saml:Conditions NotBefore=&quot;2014-11-28T18:37:25.272Z&quot; NotOnOrAfter=&quot;2014-11-28T19:37:25.272Z&quot;>&lt;saml:AudienceRestrictionCondition>&lt;saml:Audience>urn:federation:MicrosoftOnline&lt;/saml:Audience>&lt;/saml:AudienceRestrictionCondition>&lt;/saml:Conditions>&lt;saml:AttributeStatement>&lt;saml:Subject>&lt;saml:NameIdentifier Format=&quot;urn:oasis:names:tc:SAML:1.1:nameid-format:unspecified&quot;>ddcNR0t/6kWEAp4knvEteA==&lt;/saml:NameIdentifier>&lt;saml:SubjectConfirmation>&lt;saml:ConfirmationMethod>urn:oasis:names:tc:SAML:1.0:cm:bearer&lt;/saml:ConfirmationMethod>&lt;/saml:SubjectConfirmation>&lt;/saml:Subject>&lt;saml:Attribute AttributeName=&quot;UPN&quot; AttributeNamespace=&quot;http://ift.tt/1uSZNKH AttributeName=&quot;ImmutableID&quot; AttributeNamespace=&quot;http://ift.tt/1uSZNKK AuthenticationMethod=&quot;urn:oasis:names:tc:SAML:1.0:am:password&quot; AuthenticationInstant=&quot;2014-11-28T18:37:24.943Z&quot;>&lt;saml:Subject>&lt;saml:NameIdentifier Format=&quot;urn:oasis:names:tc:SAML:1.1:nameid-format:unspecified&quot;>ddcNR0t/6kWEAp4knvEteA==&lt;/saml:NameIdentifier>&lt;saml:SubjectConfirmation>&lt;saml:ConfirmationMethod>urn:oasis:names:tc:SAML:1.0:cm:bearer&lt;/saml:ConfirmationMethod>&lt;/saml:SubjectConfirmation>&lt;/saml:Subject>&lt;/saml:AuthenticationStatement>&lt;Signature xmlns=&quot;http://ift.tt/15HXXrD Algorithm=&quot;http://ift.tt/1mXLI0V; />&lt;SignatureMethod Algorithm=&quot;http://ift.tt/NWqVuI; />&lt;Reference URI=&quot;#_7f55172b-43f9-466c-bede-436d794119e2&quot;>&lt;Transforms>&lt;Transform Algorithm=&quot;http://ift.tt/1p0glUu; />&lt;Transform Algorithm=&quot;http://ift.tt/1mXLI0V; />&lt;/Transforms>&lt;DigestMethod Algorithm=&quot;http://ift.tt/1mXLI0X; />&lt;DigestValue>9Jldbpiqe7ie6Q4R9MBRBL3y3to=&lt;/DigestValue>&lt;/Reference>&lt;/SignedInfo>&lt;SignatureValue>geVzxtwW4bSbLRCEUTgIdn3xwZFnyHXLBamGlnudEwBdxpUrtlyUZBD71zpbP85AIuoFTNPsAGwDsknaRa5jhurDIJ2AsR2rsOh8dlnFDEwCK76zldPVXWIVIat255ShMDRLG3dlBDuHN1h8rdBihKrMD2tfS4xJ8KAI1+jwhaeM8/RYIFktCQUhjnUszmiChOfiqSl+a0aitgboGmP9blDrZcEu8UflslAgnmRr0mRg3NP8JoRqhNH/XuqEXNJUihuGmGqK8pwbSQpPGMl2qmBk20F3lliOFXcToQCFHBMY52c4jix2X8yxvFTU5Wx0JLYqoOo8FKPBEwfPtGD01g==&lt;/SignatureValue>&lt;KeyInfo>&lt;X509Data>&lt;X509Certificate>MIIC2jCCAcKgAwIBAgIQN5pkvQA4VKJHhmyqe1c7EzANBgkqhkiG9w0BAQsFADApMScwJQYDVQQDEx5BREZTIFNpZ25pbmcgLSBzdHMuYnJpbGxpby5jb20wHhcNMTQwMzE0MTk1NDEyWhcNMTUwMzE0MTk1NDEyWjApMScwJQYDVQQDEx5BREZTIFNpZ25pbmcgLSBzdHMuYnJpbGxpby5jb20wggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQCnGPNSXDlOvjxlT8qOk2apR0OUfCgDHD14zL0v+YCochzKSmvz8c7W8o5Bs36JFYPHqTYI0SnsrYM5IspGoET1rjc+8oUTQHs9QY41F8edq8DgMGBfIfkffEuKEtfnblBAWFsGWI94XZFl5wXcsunR+UqkcdaAlitPJ4tGTMF2G4LW8HCYu9uR9mkpT19/HGlhncAi8dHpmrzQ9yoIt4PRDFzECRwBbbpxxB1K4Sae8rb5GNE8b5IVKVAD7sIqI8UShcMaOTT357Esvm9MGB4aJH1BpW3qUa63vOc834nvE2EgBff3CXW1cwnOtLkiQ0xQW3otdCHm8lZdT0YNpPHNAgMBAAEwDQYJKoZIhvcNAQELBQADggEBAIC75Yfa+EhA/0vbKVhdib9yBa7F3fS1UmLz+Zzxij2AkIvSmGb3sf95OX6lwAuCAgVTTcU/qy2LMgUFUWNsxOxsDmeDbeOUdHjILgRAZnE+8kQTVagws4w5T+AFXAIeqVuYxxUqtP33prECzxwklwYW9FOLD4nGx4w5uz/rfP7yfxN+q1XdZu/U1WiRcYd7cSIsLlceNF5yA0yey9L24iEPBZDjAQAatppws4pusHyEJVL3gFLnvJWGlC4Khtb/41LFAe16n8LTKS4jJcx3Msu7TkHKfZYX7lIufAKK6ObyenGKszTdLvemZO46RicG0Dlm9PtaEjoqUn3Iok4/KEk=&lt;/X509Certificate>&lt;/X509Data>&lt;/KeyInfo>&lt;/Signature>&lt;/saml:Assertion>&lt;/t:RequestedSecurityToken>&lt;t:TokenType>urn:oasis:names:tc:SAML:1.0:assertion&lt;/t:TokenType>&lt;t:RequestType>http://ift.tt/15HXXrJ;" /><input type="hidden" name="wctx" value="wa=wsignin1.0&amp;rpsnv=4&amp;ct=1417199483&amp;rver=6.1.6206.0&amp;wp=MBI&amp;wreply=https:%2F%2Fsomethingonline.sharepoint.com%2F_forms%2Fdefault.aspx&amp;lc=1033&amp;id=500046&amp;bk=1417199484&amp;LoginOptions=3" /><noscript><p>Script is disabled. Click Submit to continue.</p><input type="submit" value="Submit" /></noscript></form><script language="javascript">window.setTimeout('document.forms[0].submit()', 0);</script></body></html>


I get the above response when I am within the domain else I get the html for custom login page as smart links has been configured. I am not sure if I am posting to the right url.How do I get to to the response with BinarySecurityToken?






Recaptcha.dll not found after webpart deployment



I'm developing a webpart that contains a form for register data and send it to a list.


I know a little about Sharepoint webpart development but again, implementation of external resources in SharePoint customizable webparts (not even the development using SPListItems, SPQuery, etc) still produces me headaches...


I'm trying add recaptcha control in this webpart form, but after the deployment I check the form in runtime and I get this error:



Parser Error Message: Could not load file or assembly 'Recaptcha, Version=1.0.5.0, PublicKeyToken=9afc4d65b28c38c2' or one of its dependencies. The system cannot find the file specified.



The full error that shows me the Elements tab in Google Chromes says:



[FileNotFoundException]: Could not load file or assembly 'Recaptcha, Version=1.0.5.0, PublicKeyToken=9afc4d65b28c38c2' or one of its dependencies. The system cannot find the file specified. at System.Reflection.Assembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, Assembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection) at System.Reflection.Assembly.InternalLoad(AssemblyName assemblyRef, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection) at System.Reflection.Assembly.InternalLoad(String assemblyString, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection) at System.Reflection.Assembly.Load(String assemblyString) at System.Web.Configuration.CompilationSection.LoadAssembly(String assemblyName, Boolean throwOnFail) at System.Web.UI.TemplateParser.AddAssemblyDependency(String assemblyName, Boolean addDependentAssemblies) at System.Web.UI.MainTagNameToTypeMapper.ProcessTagNamespaceRegistrationCore(TagNamespaceRegisterEntry nsRegisterEntry) at System.Web.UI.BaseTemplateParser.ProcessDirective(String directiveName, IDictionary directive) at System.Web.UI.TemplateParser.ParseStringInternal(String text, Encoding fileEncoding) [HttpParseException]: Could not load file or assembly 'Recaptcha, Version=1.0.5.0, PublicKeyToken=9afc4d65b28c38c2' or one of its dependencies. The system cannot find the file specified. at System.Web.UI.TemplateParser.ProcessException(Exception ex) at System.Web.UI.TemplateParser.ParseStringInternal(String text, Encoding fileEncoding) at System.Web.UI.TemplateParser.ParseString(String text, VirtualPath virtualPath, Encoding fileEncoding) [HttpParseException]: Could not load file or assembly 'Recaptcha, Version=1.0.5.0, PublicKeyToken=9afc4d65b28c38c2' or one of its dependencies. The system cannot find the file specified. at System.Web.UI.TemplateParser.ParseString(String text, VirtualPath virtualPath, Encoding fileEncoding) at System.Web.UI.TemplateParser.ParseFile(String physicalPath, VirtualPath virtualPath) at System.Web.UI.TemplateParser.ParseInternal() at System.Web.UI.TemplateParser.Parse() at System.Web.Compilation.BaseTemplateBuildProvider.get_CodeCompilerType() at System.Web.Compilation.BuildProvider.GetCompilerTypeFromBuildProvider(BuildProvider buildProvider) at System.Web.Compilation.BuildProvidersCompiler.ProcessBuildProviders() at System.Web.Compilation.BuildProvidersCompiler.PerformBuild() at System.Web.Compilation.BuildManager.CompileWebFile(VirtualPath virtualPath) at System.Web.Compilation.BuildManager.GetVPathBuildResultInternal(VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile) at System.Web.Compilation.BuildManager.GetVPathBuildResultWithNoAssert(HttpContext context, VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile) at System.Web.UI.TemplateControl.LoadControl(VirtualPath virtualPath) at Glogic.FormLiberty.FormLiberty.FormLiberty.CreateChildControls() at System.Web.UI.Control.EnsureChildControls() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) at System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) at System.Web.UI.Page.ProcessRequest() at System.Web.UI.Page.ProcessRequest(HttpContext context) at Microsoft.SharePoint.Publishing.TemplateRedirectionPage.ProcessRequest(HttpContext context) at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)



The steps I follow for add the dll in GAC and SharePoint project are:



  • Register the dll in GAC using Visual Studio Command Prompt.

  • Add the dll directly in /bin folder.

  • Add the dll in the Package folder following the steps described in this answer.

  • Check in the manifest.xml file if the dll is already registered.


In this link says that the recaptcha.dll must be added in a SafeControl tag instead in a Assembly tag:


I haven't the log files. In resumen, the main problem is:


Could not load file or assembly or one of its dependencies. The system cannot find the file specified.


I downloaded the recaptcha.dll here