Tech
Forums
Jobs
Books
Events
Videos
Live
More
Interviews
Certification
Training
Career
Members
News
Blogs
Contribute
An Article
A Blog
A Video
An Ebook
An Interview Question
Register
Login
1
Answer
$scope variable undefined in angular controller
Kapil Bhati
7y
157
1
Reply
Hi ,
I have the following example code in my app:
Go
Now i have Angular controller like this :
angular.module('WidgetsApp').controller('Widgetscontroller', function ($scope, factory) {
$scope.getData = function () {
$scope.d = {};
var txt = $scope.d.txt_chart;
var res = factory.getData(txt);
});
})();
but
var txt = $scope.d.txt_chart;
this gives undefined value. how to resolve this. i m new to angular
Post
Reset
Cancel
Answers (
1
)
Next Recommended Forum
How to save data with special characters
How to show images from database to bootsatrap carousel(mvc)