Category Archives: SharePoint
SharePoint終極大爆炸

SharePoint 2016爆到連啲default column type都死埋,SharePoint真係少啲經驗都必炒無疑
[Real] Typescript has no type

If i pass an integer to the function’s parameter “from”, it will become integer and say it doesn’t has “includes” function, since it is belong to class string. This code is tested in SharePoint online with reactjs and typescript.   Below is my tsconfig.json  
Office 365 outlook有webhook

Office 365 outlook有webhook,以後要sync email去SharePoint又唔想用Microsoft Flow嘅話可以唔洗寫Polling了
Microsoft嘅SharePoint Online係會disable上左production嘅feature

Microsoft嘅SharePoint Online原來個feature就算上左production都會因為有問題而中途被disable返
Unexplainable : Typescript compiler has bug

Unexplainable : Typescript compiler has bug, if i add anything above {this.toDoList}, a html tag or just a string, the variable become nothing, nothing is shown on the screen. I am not sure it is reactjs bug or typescript bug, or may be chrome bug. I am using latest spfx 1.7.0 with SharePoint Online for […]
Solved : central admin new web application button is disabled

When you login to central admin and found out your “new web application” button is disabled. Just run SharePoint configuration Wizard, logout and login admin your windows. Everything will be fine. !!! If still failed, try to login to windows via non-administrator account. Then start central admin by “run as administrator”
Command to tail SharePoint Log

If in SharePoint 2013, change your path to C:\Program files\Common Files\Microsoft Shared\Web Server Extensions\13\logs\
Manually create sharepoint configuration database

1. you have to run sharepoint shell using administrator 2. when credential dialog popup, you have to input the user name as machine_name\administrator 3. when hitting error, you must close the shell and restart it, otherwise whatever you do, last error message still happen Tips: 1. if you hit “Requested registry access is not allowed”, […]
C# code to read out all webhooks of a SharePoint Online list

發現左一個可以玩殘你嘅咪記大bug

發現左一個可以玩殘你嘅咪記大bug,如果你寫sharepoint兼用typescript但係又想用jquery, 你好可能會用: import * as $ from ‘jquery’; 如果嗰畫面得一個webpart,甘你會無事,如果有多個webpart(見下圖),你reload幾次就會撞到有一次某幾個webpart無哂野,因為jquery撞左,網上有啲友話係config.json個externals加返jquery呢一招我試過唔得。但我撞到有一招係work嘅:
A workable and deployable package.json for spfx 1.5 with office fabric react

Solved: vscode [tslint] ‘ should be ” (quotemark)

To solve “[tslint] ‘ should be ” (quotemark)” when developing spfx webpart using visual studio code, do these: open config/tslint.json add {     “$schema”: “https://dev.office.com/json-schemas/core-build/tslint.schema.json”,     // Display errors as warnings     “displayAsWarning”: false,     // The TSLint task may have been configured with several custom lint rules     // before this config file is read (for example lint rules […]
SPfx on-premises solution is lagging behind to SPO

極嚴重, sharepoint framework個generator仲停留緊係1.1.0俾on-premises, 而sharepoint online已經去到1.5.0, 兩個世界再次被split開而咪記班友無意慾修正。千其唔可以sell啲客一個solution做哂sharepoint online同埋未來嘅sharepoint 2019, 死硬 !!!   https://github.com/SharePoint/sp-dev-docs/issues/1883
Building a small workflow using Microsoft Flow

I am building a small workflow using Microsoft flow to auto move the Nintex status email from my inbox to a SharePoint list. I found out some advantages of Flows than Nintex workflows. First it support a debug button to either : replay the last trigger or halt the workflow and want for you trigger. […]
The setting to identify an SPO/Onprem project for spfx

In file .yo-rc.json, the value of “environment” is either “spo” or “onprem”, it identify your project is on-premises or sharepoint online. If you want to create extension, you have to use “spo” { “@microsoft/generator-sharepoint”: { “version”: “1.4.1”, “libraryName”: “quantr-express”, “libraryId”: “1a6a217f-6fb8-44b4-981f-35d0ebe7025b”, “environment”: “onprem” } }
My notes on command set development for SPO

current list id : this.context.pageContext.list.id current list title : this.context.pageContext.list.title for (let row of event.selectedRows) { let itemId: number = row.getValueByName(‘ID’); Dialog.alert(`${itemId}`); } Get current user email : this.context.pageContext.user.email import * as strings from ‘SpfxCloneCommandSetStrings’; this._fieldTypesToIgnore = new Array( strings.typeCounter, strings.typeContentType, strings.typeAttachments, strings.typeModStat, strings.typeComputed ); this._fieldsToIgnore = new Array( strings.fieldModified, strings.fieldCreated, strings.fieldAuthor, strings.fieldEditor, strings.field_HasCopyDestinations, strings.field_CopySource, […]
SharePoint Online with webhocks

Thanks to MS tech community people, the webhocks solution is the key for SPfx to add remote event receiver function to SharePoint Online. https://github.com/SharePoint/sp-dev-fx-webparts/tree/master/samples/react-webhooks-realtime
why one-column in SharePoint online is not full width

why one-column in SharePoint online is not full width? why one-column in SharePoint online has a fixed max-width and not adjustable? I don’t understand why Microsoft put such a hardcode setting
unsolved : site column does not refresh

When i redeploy my SharePonit spfx extension, the new site column name never refresh. I tried to delete the app and redeploy the app. Or even change the version number in package-solution.json. It is no hope. The steps i pack the sppkg file are: This issue is reported to github https://github.com/SharePoint/sp-dev-fx-webparts/issues/472
Microsoft doc is MAD for sharepoint spfx dev

Microsoft doc teach us to hard code the cdn path with tenant name, first, it is wrong, if we want to deploy our webpart to office365 cdn, just leave it as “cdnBasePath”: “” , see the below image. Second, even we follow the doc to hardcode the cdn path, it doesn’t work !!! See my […]
Microsoft doc wrong again for SharePoint spfx dev

See this
Office 365 cdn sometime is slow

Deployed a webpart to office 365, it pop out an error, it is just because office cdn is slow and the javascript is not updated yet. All we have to do is wait.
I am very good at developing SharePoint modern webpart now

I am very good at developing SharePoint modern webpart now, below is my learning curve for you to reference. I know nodejs 2 years ago but i didn’t take any commerical project for that, so my nodejs skill is not very hands-on. I spent two days to review everything i need to start nodejs programming. […]
icon will not distort in v1.4 sharepoint sdk

When you are creating modern webpart, you need to upgrade your node modules to v1.4 manually by “npm updated” and “npm install –save @microsoft/sp-build-web@latest”, icon will not distort in v1.4 sharepoint sdk now.
Just tried Powerapps to build form in SharePoint Online

My first impression is, powerapps doesn’t support safari and i am in mac. I found a few bugs. The form designer is fast but if compare the functionalities to Nintex or AgilePoint, it still lacks of advance features, such as custom javascript, custom layout.
Break through agilepoint v5 smtp authentication problem

I can’t successfully config agilepoint to send email through smtp server with authentication. I finally able to find the project template in visual studio 2010 to create my own email stub. Still trying !
Redirect local IIS to SharePoint Online

Install Application Request Routing https://www.iis.net/downloads/microsoft/application-request-routing Make sure “url rewrite” is in your IIS Follow the below screen to add rule
SharePoint 2016 Central Admin Functionalities summary

Application management Create/edit/delete web application Create/edit/delete site collection Assign site collection primary and secondary administrator Create or extend Web application Remove SharePoint from IIS Web site Delete Web application Define managed paths Web application outgoing e-mail settings Web application general settings Content databases Manage Web application features Web application list SharePoint Site Management Create site […]
Microsoft is fake again, node 8.9.0 is not working for office365 development

In SharePoint with NodeJs development, Microsoft was suggesting us to use Node 6.9.x, now microsoft website is updated and telling us to use Node8.9.x, I tried which failed. Lots of people on technet are saying they can’t compile their SharePoint project too. Microsoft need a better open source QC team.
Community Kit for SharePoint

Community Kit for SharePoint is a famous open source project in SharePoint world, it has some projects for reference designs.
SharePoint left navigation bar in modern page

If you create a SharePoint site using the “communication site”, the left navigation is hidden and the top navigation menu appear. Which is different than the “Team Site” and there is no way to change it back unless you write code for custom branding. So need to beware of this when you create a SharePoint […]
SharePoint – Patterns and Practices

These web are good for you to learn latest SharePoint dev patterns and practices – [PnP at dev.office.com](http://aka.ms/OfficeDevPnP) – Welcome page with sample and guidance search – [SharePoint Dev Group](http://aka.ms/sppnp-community) – Questions and feedback – [PnP at MSDN](http://aka.ms/OfficeDevPnPMSDN) – [PnP videos](http://aka.ms/sppnp-videos) at YouTube – [PnP at Docs.com](https://docs.com/OfficeDevPnP) – Docs.com – [PnP Sites Core Component](http://aka.ms/officedevpnpsitescore) – […]
Installed AgilePoint NX

Installed AgilePoint NX, start doing research
Quantr forms logo and icon

Crazy icon size for sharepoint modern webpart

If using office fabric icon, it is 28px x 28px. If using iconImageUrl, is has to be 40px x 28px, which is much smaller !
Added test case for api /doesuserhavepermissions

Added test case for api : _api/web/doesuserhavepermissions, you can use this example to test for a specific permission of a specific user. You must add the user to the SharePoint owner group, otherwise it will return false. If the user don’t event have right to enter the subsite, the api will return 403. https://gitlab.com/quantr/sharepoint/Sharepoint-Java-API/blob/83750c61ec040a699ca02525bc4402ad7ae69227/src/test/java/hk/quantr/sharepoint/TestHavePermissions.java The […]
SharePoint Online get all items with fields specified by view

I am not sure i am correct or not. There is no /_api/web/lists/GetByTitle(‘your list’)/View/getbytitle(‘your view’)/items restful api for SharePoint online. So to get the items with fields that specificed by a view, you need these steps: Call “/_api/web/lists/GetByTitle(‘your list’)/fields” to read all fields and save all “InternalName” and “FieldTypeKind” Call “/_api/web/lists/GetByTitle(‘your list’)/View/getbytitle(‘your view’)/ViewFields” to read […]
Greate tutorial : SharePoint Framework Tutorial 6 – Using Office UI Fabric Components

https://channel9.msdn.com/blogs/OfficeDevPnP/SharePoint-Framework-Tutorial-6-Using-Office-UI-Fabric-Components
WordPress SharePoint tag to read document library

I want to display files in SharePoint’s document library in my wordpress. There is one big technical problem, javascript still can’t do external authentication to SharePoint, by default your browser blocked corss site script. Even you enabled it in command line, your javascript still can’t set the custom “Cookie” in the header that need to […]
Learning the advance skills to build new webpart

Since the classic webpart will be nuked, i am learning the advance skills to build new webpart