visual-studio-2008

COM method call returns Catastrophic Failure

浪子不回头ぞ 提交于 2019-12-24 12:34:30
问题 Note: Pass BSTR variable to COM method, HRESULT return is 8000FFFF Previous calls with interface pointer , was successful : HRESULT is 0 Execution, inside Visual Studio succeeds , outside fails - release and debug Illustration: const char *simFile; simFile = new char; //omitted _bstr_t simFileToOpen(simFile); BSTR raw_sim_Open = simFileToOpen.copy(); SysFreeString(simFileToOpen); delete simFile; hresult = pis8->raw_Open (raw_sim_Open); //0x8000FFFF returned 回答1: simFile looks to be a single

Which is better VB6 to .NET converter?

佐手、 提交于 2019-12-24 11:59:38
问题 Is the VB6 to .NET upgrade wizard included in VS2008 better than the one in VS2005? UPDATE: I ran the same VB6 code through both upgrade wizards and VS2008 produced far less reported issues in the ugprade report. The upgrade wizard in VS2008 must be an improved version. 回答1: Both VS2005 and VS2008 use the same convertion utility. 来源: https://stackoverflow.com/questions/8194038/which-is-better-vb6-to-net-converter

Visual Studio 2008 C ++ stopping during Linking

佐手、 提交于 2019-12-24 11:40:09
问题 I have written some image processing program using OpenCV 2.1 I received a error during linking, related to "projectname.ilk" file.(message said VS is trying a non-incremental linking). So I triied rebuilding the project. The initial message went away, but now VS never completes "Linking". It prints "1>Linking..." and stays that way. What might be the problem? Thanks 回答1: If clean build fails to remedy, try eliminating /LTCG on the link and whole program optimization in c++. There have been

textbox textchanged event always firing

别说谁变了你拦得住时间么 提交于 2019-12-24 11:39:59
问题 I have a form with a few text-boxes and a Grid-view. There is this one text-box called "Inward Number", whose text-changed event fires all the time. When i want to fire another control's event, it simply fires the text-changed event of the Inward Number text-box. This happens with all of the other controls. Can someone please help? protected void txtInward_No_TextChanged(object sender, EventArgs e) { a = 'A'; NewRow(); } I have used the correct names, but still this error occurs. <asp:TextBox

How to automatically add a huge set of .vcproj files to the solution?

浪子不回头ぞ 提交于 2019-12-24 11:01:03
问题 I have a huge set of .vcproj files (~200) stored in different locations. I have a list of these files with full paths. How can i automatically add them to the solution file(.sln) ? UPD: I'm looking for existing tool/method. 回答1: Here's how I'd do it: Create and save a blank solution to insert the vcproj files into (File->New Project->Other Project Types->Visual Studio Solutions->Blank Solution) Create a VS macro which adds a project to a solution, saves the solution, and exits. Try the

Meyers Singleton thread safe with C++-98

拈花ヽ惹草 提交于 2019-12-24 10:47:37
问题 Currently I have this implementation of the meyer singleton: class ClassA { public: static ClassA& GetInstance() { static ClassA instance; return instance; } private: ClassA::ClassA() {}; // avoid copying singleton ClassA(ClassA const&); void operator = (ClassA const&); }; Now I need some improvements to getting this code thread safe in C++-98 and VS-2008?! Thanks! PS: What is unclear? You see the tags visual-studio-2008 and c++-98 -> so the target OS is Windows! I also don't understand why I

old dlls in GAC are still being used

时光总嘲笑我的痴心妄想 提交于 2019-12-24 10:36:29
问题 I have a set up where the assembly is published to the GAC after each build. But My application uses the old dll all the time. After build the new dlls are created in a new folder. The folder names are 7.1.7573.0_ d516cb311 and 7.1.5000.8888 _d516cb311. The second folder being the latest. It seems(from the folder name) my current code is publishing old dll. Is it the reason my application is using old dll? If yes What will I have to do so that currect assembly is published? Edit: In the web

Forcing value to boolean: (bool) makes warning, !! doesnt

冷暖自知 提交于 2019-12-24 10:20:29
问题 I like (bool) way more, but it generates warnings. How do i get rid off the warnings? I have code like: bool something_else = 0; void switcher(int val = -1){ if(val != -1){ something_else = (bool)val; }else{ something_else ^= 1; } } Should i just do it like everyone else and use '!!' or make it somehow hide the warning messages when using (bool) ? Or is '!!' actually faster than (bool) ? I would like to use (bool) and so i have to hide the warning, but how? Edit: Visual Studio 2008 i am using

visual studio 2008 output window stopped working

混江龙づ霸主 提交于 2019-12-24 10:13:01
问题 i've been working on a C++ project for some time now in VS 2008. Until recently, upon terminating my application the output window would show if i had any memory leaks. however, a few days ago i noticed it stopped showing this valuable information. i also tried throwing some printf() around, but the output window isn't showing that either. i'm guessing i changed a preference somewhere, but i can't seem to find it. all the output shows now is which dll's it has loaded/unloaded. any ideas?

How can I select a row from a datatable using two variable values?

一笑奈何 提交于 2019-12-24 10:10:07
问题 Alright, so what I'm attempting to do here, is select from a datatable all the rows that match two variables. First, I queried a SPList into a datatable. The datatable has two columns, Client ID, and Model Details. Here's some of the code, so hopefully you can get an idea of what I'm attempting. //These are contained within a foreach loop, so will be different through each //iteration through. int iClientID = gdbData.GetClientID(iJobNumberID); string strModelDetails = xeApprovalUpdate