New answers tagged

1

I think the error is in query and in dates, check following code: var Startdate = today.toISOString().substring(0,10) + "T00:00:00.000Z"; var Enddate = today.toISOString().substring(0,10) + "T23:00:00.000Z"; var queryString = "&$Top=1&$filter=Today le datetime'" + Enddate + "' and Today ge datetime'" + Startdate + "'"; You missed & before $...


2

I think above will not work because it is taking into consideration time component, you have to ignore time component and compare only date to get value. There is no straight forward way to do this. You have to use below Logic is to compare Today date with current date(starting from first second) and tommorow(starting from first second) Add below function ...


0

Try this, with queryString= "$filter= yourDateField eq date'"+new Date().toISOString()"'" (eq = equal) Or queryString= "$filter= yourDateField ge date'"+new Date().toISOString()"'" (ge = greater or equal) In your response can be more than one item (data.d.results) jQuery.ajax({ url: encodeURI(_spPageContextInfo.webServerRelativeUrl + "/_api/web/...


0

I guess the best thing to start is gulp clean Then gulp build and then gulp serve. Maybe these simple steps will help you to refresh all dependencies and get rid of outdated artifacts


1

Looks like there seems to be some issue going on with domain isolated webparts, for the time being would suggest that you not use that property. As mentioned in the comments, would suggest that you modify the config > package-solution.json file and set the isDomainIsolated value to false and then bundle, package and upload the solution and try again by ...


1

Try to call method getToken with 'https://graph.windows.net' to get the JWT token return tokenProvider.getToken('https://graph.windows.net') You can refer to these similar situation below: https://github.com/Azure-Samples/active-directory-angularjs-singlepageapp-dotnet-webapi/issues/19 https://github.com/SharePoint/sp-dev-docs/issues/3102


0

I have never really tried, but I don't think it's possible. The schema has only the txtContent property, which get's inserted as "text", not as "html". I see no way to insert "html" content. You'd need an SPFx Field Customizer for that.


0

If you are using Multi line of Text and Enhanced rich text option is checked.. By Default List views display it in html format. below is screenshot of your example


1

You need to add and set the property loadLegacyFabricCss to true in your webpart's manifest.json file. The value needs to be set as below: "loadLegacyFabricCss": true, So, your <webpart>.manifest.json file will look something like: "alias": "Test182WebPart", "componentType": "WebPart", // The "*" signifies that the version should be taken from ...


0

It looks like there is some change in the back-end because of which the code has kinda stopped working in Edge and IE. As a workaround for now, would suggest that you set the header values explicitly. You need to add the below code for headers, don't forget to import ISPHttpClientOptions from @microsoft/sp-http module: let httpOptions: ...


0

Here is an example of passing pageContext to React component: Add property to component interface. Note that I import PageContent declaration for nice IntelliSence pop-ups (I use VS Code) import { PageContext } from '@microsoft/sp-page-context'; // load page context declaration export interface IHelloWorldProps { description: string; ...


0

TomB, It can be quite daunting to learn the array syntax, especially since many examples out there show older code syntax. It really depends on where in your code you're defining the arrays. If you're doing it within a method, you'll probably want to use this syntax: public render(): React.ReactElement<IHelloWorldProps> { const customerList: ...


0

Finally found the solution. What I was doing was that I was importing the polyfills after the statements of import * as React from 'react'; import * as ReactDom from 'react-dom'; I moved all my polyfills before even react loaded and the code started working on Internet Explorer. So the in my <WebPartName>WebPart.ts looked something like this. ...


0

Did you take a look at the sample command extension found at https://github.com/SharePoint/sp-dev-fx-extensions/tree/master/samples/react-command-print ?


0

Krunal, It can be a bit daunting to become familiar with the SPFx project structure, but I hope that these instructions will help. To create a base SCSS that is used by all web parts: 1. Create a shared or common folder under the src folder. For this example, I'll used shared 2. In the shared folder, create a new file and name it shared.module.scss 3. Copy ...


0

Have you tried creating a common "base" scss and import using the @import statement? Have a look at the Recommendations for working with CSS in SPFx and especially how office-ui-fabric can be imported in a WebPart.


0

Dan, You will have to include the Bing Maps as an external script in webpart as described here- https://docs.microsoft.com/en-us/sharepoint/dev/spfx/web-parts/basics/add-an-external-library In webpart's config.json (inside config folder) include something similar to this: "externals": { "bingmaps": { "path": "https://www.bing.com/api/maps/...


2

So even though this issue no longer persists (as of May 2019), heres a link to the relevant comment (solution) I used to fix this issue. Long story short this was due to some problems on both AAD authentication and the client libraries so Micorosoft had to work on a fix for quite a while. As of now, the comment I linked to is the only solution to this ...


Top 50 recent answers are included