visual-studio-2012

Initializer list not working in Visual Studio 2012 Update 2 CTP 4 (March)

人走茶凉 提交于 2019-12-24 20:28:35
问题 After installing Visual Studio 2012 Update 2 CTP 4 (March), this code doesn't compile: vector<int> b = {1, 2, 3}; with the following error message: 'std::vector<_Ty>' : Types with a base are not aggregate Earlier post about the same issue with previous CTP mentioned using initializer_list header, but CTP 4 didn't install it. Any suggestions how to fix it? 回答1: The compiler supports initializer lists, but the standard library (std::vector etc.) does not. You will have to wait before your line

insert into database using context doesn't work

雨燕双飞 提交于 2019-12-24 20:08:54
问题 I'm trying to insert values in a table. I'm doing it as follows : JobTable jobTable = new JobTable(); int result = -1; JobEntities context = new JobEntities(); try { jobTable.JobDate = DateTime.Now; jobTable.JobProcess = processName; context.JobTable.Attach(jobTable); context.JobTable.Add(jobTable); result = context.SaveChanges(); Console.WriteLine("Result => " + result.ToString()); } catch (Exception) { throw; } return jobTable.JobId; I'm getting a new JobId each time, but when I check my

Unable to see comments in javascript files generated by TypeScript

一个人想着一个人 提交于 2019-12-24 20:06:10
问题 I have created a TypeScript(.ts) file. Which upon save generates a minified JavScript file and a normal(readable) JavaScript file. All this works fine. But the comments I have added is TypeScript file is not visible in auto-generated JavaScript file. Since you cannot debug a TypeScript file (to add breakpoint, one need to use JavaScript file) and comments are not available in JavaScript file, I have to switch between .TS file and .JS file while debugging. Is there way to tell TypeScript, not

How to connect database to Report or Report Wizard in Visual Basic 2012?

帅比萌擦擦* 提交于 2019-12-24 19:31:19
问题 My database is Vertrigo(MySql) and i don't know how to connect my database to report or report wizard in Visual Basic 2012. I need the report or report wizard in order to print all the data that i have in my database. Can you help me? Please? 来源: https://stackoverflow.com/questions/46439217/how-to-connect-database-to-report-or-report-wizard-in-visual-basic-2012

Deploy multiple WCF Webservices with WiX Toolset - Wrong svc files

泄露秘密 提交于 2019-12-24 19:29:16
问题 I'm trying to use the WIX Toolset 3.7 in VS2012 to create an installer for my WFC services. All services got the same structure: The service.svc is simply linking to the specific class <%@ ServiceHost Language="C#" Debug="true" Service="LandwehrServices.Service.Vorlage.ServiceOption" Factory="ServiceCreator.DigestAuthenticationHostFactory" %> The dlls are getting installed right, but all folders contain the same service.svc (of the first installed service) file... This is my Product.wxs <Wix

how to fix warning ICE39: Admin Image flag set in SummaryInfo stream

谁都会走 提交于 2019-12-24 17:25:36
问题 I am creating an installer using Wix in visual studios 2012. Below is my code for the product.wxs. I am receiving a "warning ICE39: 'Admin Image' flag set in SummaryInfo stream. Should be set only for Admin packages." I have changed admin image from yes to no and rebuilt, it removes the warning but i am still unable to install on a computer that has local admin privileges, and is also a domain admin. However, i can install it on my machine, and im not a domain admin, I would upload the image

how to fix warning ICE39: Admin Image flag set in SummaryInfo stream

心不动则不痛 提交于 2019-12-24 17:23:13
问题 I am creating an installer using Wix in visual studios 2012. Below is my code for the product.wxs. I am receiving a "warning ICE39: 'Admin Image' flag set in SummaryInfo stream. Should be set only for Admin packages." I have changed admin image from yes to no and rebuilt, it removes the warning but i am still unable to install on a computer that has local admin privileges, and is also a domain admin. However, i can install it on my machine, and im not a domain admin, I would upload the image

Do I need TFS installed on the machine that will use some dlls to communicate remotely to it?

不羁的心 提交于 2019-12-24 17:17:08
问题 I guess not, but here's the catch: I've made a COM+ Object to be used from a machine where neither VisualStudio or TFS are installed. And this COM+ Object has referenced TFS dlls to make a login on a remote TFS server and create Work Items. And I have another additional issue. I used VS2012 and TFS2010, so the dlls referenced say 11.0.0.0 when I think they should say 10.0.0.0 or somethin of that style. I checked on this TFS 2010 build failing because it can't load Microsoft.VisualStudio

Tracing LNK1112 error in Visual Studio 2012

久未见 提交于 2019-12-24 17:05:10
问题 I have a project that I have been compiling as an x64 project for quite some time, but for various reasons I have to compile it as an x86 project now. The problem I have run in to is that every time I compile the project I now get a LNK1112 error. 1>Link: 1> 1> Starting pass 1 1>Release\CameraCapture.obj : fatal error LNK1112: module machine type 'x64' conflicts with target machine type 'X86' 1> 1>Build FAILED. The file Release\CameraCapture.obj is compiled from a .cpp file that is part of my

How can I automatically generate a constructor that receives and stores services for free?

杀马特。学长 韩版系。学妹 提交于 2019-12-24 16:26:31
问题 Problem I regularly find myself manually typing out code that looks like this: public class SomeClass { readonly ServiceA serviceA; readonly ServiceB serviceB; public SomeClass(ServiceA serviceA, ServiceB serviceB) { this.serviceA = serviceA.; this.serviceB = serviceB; } } Requirements I would like to save time by having a way to generate as much of this as possible. I don't want to use a tool that requires a purchase. The only information that is variable here is the class name and the types