Click here to Skip to main content
15,888,006 members
Home / Discussions / ASP.NET
   

ASP.NET

 
AnswerRe: port forwarding on mobile Pin
Debojyoti Saha19-Oct-15 1:22
professionalDebojyoti Saha19-Oct-15 1:22 
GeneralRe: port forwarding on mobile Pin
Member 1191972219-Oct-15 1:44
Member 1191972219-Oct-15 1:44 
GeneralRe: port forwarding on mobile Pin
Debojyoti Saha19-Oct-15 1:55
professionalDebojyoti Saha19-Oct-15 1:55 
GeneralRe: port forwarding on mobile Pin
Member 1191972219-Oct-15 2:13
Member 1191972219-Oct-15 2:13 
GeneralRe: port forwarding on mobile Pin
Debojyoti Saha19-Oct-15 2:55
professionalDebojyoti Saha19-Oct-15 2:55 
GeneralRe: port forwarding on mobile Pin
Member 1191972219-Oct-15 19:53
Member 1191972219-Oct-15 19:53 
GeneralRe: port forwarding on mobile Pin
Member 1191972219-Oct-15 20:30
Member 1191972219-Oct-15 20:30 
Questionangular js and asp.net mvc Pin
Arjun Mourya15-Oct-15 20:31
Arjun Mourya15-Oct-15 20:31 
Hi all,

I am very new to angularjs. For learning purposes I wrote a sample application that will render a partial page inside main page. For this I have used angularjs dynamic routing inside asp.net MVC project. Also I have hosted the website I created because I have used $location.

The problem I am facing is that When I try to click on the link "Client Information", i get the following error:
Quote:
Error: [$compile:tpload] http://errors.angularjs.org/1.3.0/$compile/tpload?p0=ClientInfo
as seen in the F12-> Console

My code is as below:

index.cshtml

@{
    ViewBag.Title = "Home Page";
    
}
<link href="../../Content/dealnavigation.css" rel="stylesheet" type="text/css" />
@section scripts{
    <script src="~/Scripts/angular.min.js" type="text/javascript"></script>
    <script src="~/Scripts/angular-route.min.js" type="text/javascript"></script>
    <script src="~/Scripts/angular/script.js" type="text/javascript"></script>
    
}
@section featured {
    <section class="featured">
        <div class="content-wrapper">
            <hgroup class="title">
                <h1>@ViewBag.Title.</h1>
                <h2>@ViewBag.Message</h2>
            </hgroup>
            
        </div>
    </section>
}

<div ng-app="deals" ng-controller="newdealController">
    <div class="col-xs-12 col-sm-12 col-md-12 col-lg-12">
        <ul class="nav nav-wizard margin-bottom-20 hidden-print">
            <li >
                <a ng-click="GotoClientInfo()" href="javascript:void(0);">Client Information </a>
            </li>
            <li >
                <a ng-click="GotoFacilityInfo()" href="javascript:void(0);">Facility Details </a>
            </li>
            
        </ul>      
        
    </div>
    <div ng-view>
    </div>
    </div>


script.js is the file where I have defined angular related code.
script.js
JavaScript
var $routeProviderReference;

angular.module('deals', ['ngRoute'])
.config(['$routeProvider', function ($routeProvider) {
    
    debugger;
    $routeProviderReference = $routeProvider;
    $routeProviderReference.when('/Step1', {
        templateUrl: 'ClientInfo',
        controller: 'newdealController'
    });
    $routeProviderReference.when('/Step2', {
        templateUrl: 'FacilityDetails',
        controller: 'newdealController'/// <reference path="../../Views/Home/ClientInfo.cshtml" />

    });
//        $locationProvider.html5Mode({
//            enabled: true,
//            requireBase: false
//        });

} ])
.controller('newdealController', function ($scope, $location, $route) {

    $scope.GotoClientInfo = function () {
        debugger;
        $location.path('Step1');
        // $scope.deal.current_page = 'ClientInfo';
        $route.reload();
        console.log($route);
    };

    
});


HomeController.cs

C#


public ActionResult Index()
{
ViewBag.Message = "Modify this template to jump-start your ASP.NET MVC application.";

return View();
}

public ActionResult ClientInfo()
{
ViewBag.Message = "Client Info.";

return PartialView();
}
BR,
Arjun


modified 21-Oct-15 9:56am.

QuestionIs there any way to avoid writing store procedure for 30 columns. Pin
Praveen Kandari15-Oct-15 1:40
Praveen Kandari15-Oct-15 1:40 
AnswerRe: Is there any way to avoid writing store procedure for 30 columns. Pin
ZurdoDev15-Oct-15 2:12
professionalZurdoDev15-Oct-15 2:12 
GeneralRe: Is there any way to avoid writing store procedure for 30 columns. Pin
Praveen Kandari15-Oct-15 2:19
Praveen Kandari15-Oct-15 2:19 
QuestionMake uploading of file optional?? Pin
samflex13-Oct-15 9:56
samflex13-Oct-15 9:56 
QuestionRe: Make uploading of file optional?? Pin
Richard MacCutchan13-Oct-15 9:59
mveRichard MacCutchan13-Oct-15 9:59 
AnswerRe: Make uploading of file optional?? Pin
samflex13-Oct-15 10:31
samflex13-Oct-15 10:31 
AnswerRe: Make uploading of file optional?? Pin
F-ES Sitecore13-Oct-15 23:28
professionalF-ES Sitecore13-Oct-15 23:28 
GeneralRe: Make uploading of file optional?? (SOLVED) Pin
samflex27-Oct-15 15:42
samflex27-Oct-15 15:42 
AnswerRe: Make uploading of file optional?? Pin
ZurdoDev15-Oct-15 2:14
professionalZurdoDev15-Oct-15 2:14 
QuestionEcommerce site development Pin
Member 1205587613-Oct-15 8:33
Member 1205587613-Oct-15 8:33 
SuggestionRe: Ecommerce site development Pin
Richard MacCutchan13-Oct-15 9:57
mveRichard MacCutchan13-Oct-15 9:57 
AnswerRe: Ecommerce site development Pin
F-ES Sitecore13-Oct-15 23:42
professionalF-ES Sitecore13-Oct-15 23:42 
QuestionRe: Ecommerce site development Pin
ZurdoDev15-Oct-15 2:15
professionalZurdoDev15-Oct-15 2:15 
QuestionHell All actually we want to make my website fast and i use repeater jquery ajax for get data using store procedure now we want to implement paging concept in this code but still remember our speed will not effect because we want ot fast website Pin
Member 1205134011-Oct-15 21:18
Member 1205134011-Oct-15 21:18 
QuestionRe: Hell All actually we want to make my website fast and i use repeater jquery ajax for get data using store procedure now we want to implement paging concept in this code but still remember our speed will not effect because we want ot fast website Pin
ZurdoDev13-Oct-15 2:23
professionalZurdoDev13-Oct-15 2:23 
Questionissue with accessing asp.net app over WAN Pin
Member 1191972211-Oct-15 20:27
Member 1191972211-Oct-15 20:27 
RantRe: issue with accessing asp.net app over WAN Pin
Richard Deeming12-Oct-15 1:45
mveRichard Deeming12-Oct-15 1:45 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.