Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //have the choose a pdf document from their local drive
- <html>
- <input type="file" ng-model="theInputFile"/>
- <button ng-click="submit()"> Submit </button>
- </html>
- //pass the document to a c# function for parsing
- <script>
- $scope.submit = function(){
- $http.post('Home/GetVendorInfo',
- { "c#Input": $scope.theInputFile})
- .success(function (response) {
- console.log("send successtul");
- });
- </script>
- var app = angular.module("app", []);
- app.controller("uploadController", ["$scope",
- function($scope) {
- $scope.submit = function(){
- $http.post('Home/GetVendorInfo',
- { "c#Input": $scope.theInputFile})
- .success(function (response) {
- console.log("send succestul");
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement