简体   繁体   English

VS Express 2012-无法调试

[英]VS Express 2012 - Can not debug

I'm following a tutorial on Virtual Studio Express 2012 to create windows 8 application. 我正在遵循有关Virtual Studio Express 2012的教程来创建Windows 8应用程序。 My application start, that not the point, but I've nothing to debug it. 我的应用程序开始了,不是重点,但是我没有什么可以调试的。 I placed a "console.log" on a trigger, and I know that the trigger is working but there is no console message... and no DOM explorer either. 我在触发器上放置了一个“ console.log”,我知道该触发器正在工作,但是没有控制台消息……也没有DOM Explorer。 Does anyone have an idea, because debugging something without debugger is hard ! 有谁有主意,因为没有调试器就很难调试!

Here is my code for my default.js 这是我的default.js代码

(function () {
"use strict";

WinJS.Binding.optimizeBindingReferences = true;

var app = WinJS.Application;
var activation = Windows.ApplicationModel.Activation;

app.onactivated = function (args) {
    if (args.detail.kind === activation.ActivationKind.launch) {
        if (args.detail.previousExecutionState !== activation.ApplicationExecutionState.terminated) {
            // TODO: cette application vient d'être lancée. Initialisez
            // votre application ici.
        } else {
            // TODO: cette application a été réactivée après avoir été suspendue.
            // Restaurez l'état de l'application ici.
        }
        args.setPromise(WinJS.UI.processAll().then(function () {

            document.getElementById('boutonPourOuvrir').onclick = function () {

                console.log('Salut !');

            }
        }));
    }
};

app.oncheckpoint = function (args) {
    // TODO: cette application est sur le point d'être suspendue. Enregistrez tout état
    // devant être conservé lors des suspensions ici. Vous pouvez utiliser l'objet
    // WinJS.Application.sessionState, qui est automatiquement
    // enregistré et restauré en cas de suspension. Si vous devez effectuer une
    // opération asynchrone avant la suspension de votre application, appelez
    // args.setPromise().
};

app.start();
})();

And this a screen from what I'm viewing when I launched my application : [sorry it's in French] http://sdz-upload.s3.amazonaws.com/prod/upload/demo8.jpg 这是我启动应用程序时正在查看的屏幕:[抱歉,它是法语的] http://sdz-upload.s3.amazonaws.com/prod/upload/demo8.jpg

Thanks you ! 谢谢 ! H4mm3R 高4mm3R

I switched to VS2013 where I didn't have the problem, but I created it with changing a value. 我切换到VS2013,那里没有问题,但是我通过更改值创建了它。 So here the answer for the "bug" Go to the property of the project > debug > debug type and chose "script only" 因此,这里的“错误”答案是转到项目的属性>调试>调试类型,然后选择“仅脚本”

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM