We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Can not use ej angular2 components

Thread ID:





128119 Jan 3,2017 03:59 PM UTC Jan 4,2017 05:19 AM UTC Angular 1
Tags: General
Jemmy Lu
Asked On January 3, 2017 03:59 PM UTC

Hello! I'm using the angular2 components and I'm facing a error is when I import ej components in app.modult.ts and will occur error like:" Cannot set property 'backGroundImageUrl' of undefined ; Zone: <root> ; Task: Promise.then ; Value: TypeError: Cannot set property 'backGroundImageUrl' of undefined" if I import the chart components.and here's the code:

import { NgModule } from "@angular/core";
import { BrowserModule } from '@angular/platform-browser';
import { RouterModule } from '@angular/router';
import { FormsModule } from '@angular/forms';
import { HttpModule, RequestOptions } from "@angular/http";
import { AppRequestOptions } from "./app.request";

import { AppRoutingModule } from "./app-routing.module";
import { AppComponent } from "./app.component";

import { EJ_CHART_COMPONENTS } from "./ej/chart.component";

    imports: [
    declarations: [
    providers: [
        { provide: RequestOptions, useClass: AppRequestOptions }
    bootstrap: [AppComponent]
export class AppModule { }

And My folder strucrure is like:

If I remove the import ej component part from app.module.ts then it works.
Is there any extra files I need to include?Thanks

Abinaya Subbiah [Syncfusion]
Replied On January 4, 2017 05:19 AM UTC

Hi Jemmy,  
Thanks for contacting Syncfusion support. 
The script error “Cannot set property ‘backGroundImageUrl’ of undefined(…)” due to mismatching versions of npm packages. Since, the Syncfusion JavaScript components supports Angular 2 final release version 2.0.0 , so we suggest you to use Angular 2 packages from final release version “2.0.0”.  
We already consider this  as feature request “Upgrade Syncfusion Angular 2 components to Angular v2.2.0”, it will be included in our Essential studio 2017 Volume 1 release, which is expected to be rolled out by 7th February, 2017. We appreciate your patience until then.  
We have also implemented seed applications, to quick-start with Syncfusion JavaScript Angular 2 components. Refer to the below documentation link for getting started with seed application.  
We also implemented Angular 2 sample browser using our JavaScript Angular 2 components. 
Please revert us back if you need further assistance on this.  
Abinaya S  


This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon