Software Development Network Logo
  • Audio and Video
  • Windows Vista
  • SQL Server
  • Smart Devicet
  • Visual C++
  • .NET Development
  • VS Team System
  • Visual Basic
  • SharePoint Products
  • Visual Studio
  • Game Technologies
  • Windows Forms
  • Microsoft ISV
  • Visual FoxPro
  • Visual C#

Software Development Network >> Visual C++

Visual C++

New Question

setting an environment variable on target computer
Smartbridge Alerts
testing programs
Problem using #import with ADODB in VS2005
VCToolkit
Getting bug report support from Microsoft
LNK2001: unresolved external symbol in logFels.obj how to solve?
Problem with exceptions
converting text from a text box to a int type
Deleting a node from a linked list

Top Answerers

pdxJaxon
LouArnold
crussmann
Polity4h
cam_mac
Predator14567
shivali.sadavarte
Andrew Mackie
beefeater
Alexei_shk
sitemap
Only Title

Answer Questions

  • Drudkh "error LNK2005"

    I have the following code in my Form1.h file: #include "stdafx.h" #include <stdio.h> #pragma once struct Record { char arr[15]; }; Record theRecord; errno_t err_temp; FILE *tempfile; namespace StrToCharArr { .... //typical stuff } #pragma endregion private: System::Void button1_Click(System::Object^ sender, System::EventArgs^ e) { StrToCharArray(this->textBox1->Text); } }; } My StrToCharArray.cpp function is the following: #include "stdafx.h" #include "Form1.h" using namespace StrToCharArr; void Form1::StrToCharArray(String^ str) { err_temp = tmpfile_s(&tempfile); fprintf(tempfile,"%s",str); } I am g ...Show All

  • Josibe Please read. Thank you

    Hi, I am trying to compile an Win32 project but I keep getting linking errors. I tryed to fix and search forums and google but really nothing helped, if anybody could help id be really greatful. Anyway here is the error report. I am using Microsoft Visual Studio 2003 .net Pro. All my libs and includes are located right. Header for main.cpp #include <windows.h> #include <stdio.h> #include <fstream> using namespace std; #include "main.h" #include "d3d9.h" #include "d3dfont.h" #include "d3d9dev.h" ------ Rebuild All started: Project: TatniumD3D, Configuration: Release Win32 ------ Deleting intermediate files and output files for project 'TatniumD3D', configuration 'Release|Win32'. Compiling... d3d9tex.cpp d3d9int.cpp d3d9de ...Show All

  • Chandler Chao C# to C++ WMI

    Does anyone know to convert the following C# code to VC++.Net       foreach(ManagementObject partition in new ManagementObjectSearcher(         "ASSOCIATORS OF {Win32_DiskDrive.DeviceID='" + drive["DeviceID"]           + "'} WHERE AssocClass = Win32_DiskDriveToDiskPartition").Get())     (via Instant C++) for each(ManagementObject ^partition in gcnew ManagementObjectSearcher("ASSOCIATORS OF {Win32_DiskDrive.DeviceID='" + drive["DeviceID"] + "'} WHERE AssocClass = Win32_DiskDriveToDiskPartition")->Get()) David Anton www.tangiblesoftwaresolutions.com Instant C#: VB to C# converte ...Show All

  • Landon Parks DLGINIT structure

    I want to create the dialog dynamically in memory. The dialog contains some ActiveX controls. According to the description for CDialog::CreateIndirect, I have to provide a DLGINIT resource. But I can't find the details about this structure. Following is a sample of such structure in a .RC file: ///////////////////////////////////////////////////////////////////////////// // // Dialog Info // IDD_XXXDIALOG DLGINIT BEGIN IDC_YYCONTRO1 , 0x37a , 298, 0 init data 1 IDC_YYCONTROL2 , 0x37a, 186, 0 init data 2 0 END I could load the resource and create a dialog. But I can't generate the data on the fly since I don't know the structure, for example, what is the value 0x37a Thanks for any info. ...Show All

  • Allaudeen_N_587b24 Windows Service : Types HANDLE and HMODULE cause error :(

    As I write a Windows service in C++, compiler doesn't reckognize types: HANDLE, HMODULE, WTSGETACTIVECONSOLESESSIONID and function GetProcAddress. Are there any libraries that should be included I only have the following libraries in my code: using namespace System; using namespace System::Collections; using namespace System::ServiceProcess; using namespace System::ComponentModel; Try this instead: HMODULE hmod = LoadLibrary( _T "kernel32.dll"); Do you mean compiling the project under WinServer 2003 Is compiling under XP not possible ----------------------------------------- I tried to compile under WinServer 2003, but effect is the same :( You need to add line #include <windows.h> ...Show All

  • Dots ATL8, depending library's

    Hi, i'm creating a activeX object (ATL8/COM) with Visual studio 2005. I was wondering when at the moment that i publish the client object, do the users need new updated dll's like with the new CRL when running a C++ application written in VC8 because that wouldnt be really effective ;) thanks already Ok thanks, i can live without it :) hardly but still ok but that would take one big advantage away from ATL, filesize. You can link the libraries into your dll. If you compile with VC8 and use the CRT, then yes, it will use the VC8 CRT. VC8 uses the VC8 CRT. All you can do is avoid using the CRT. I try to avoid it any how. ...Show All

  • MFZ Application built with VS 2005 SP1 does not run on another computer

    Three executables were delivered from a development machine to a production machine, to which I do not have direct access at this time. One built with VC6 runs without a problem. One built with VC8 SP1 does not run due to an error that looks like vcredist was not installed. One apparently built with VC8 w/o SP1 does run. My questions - 1. How can one check with which version of VC was the 3rd executable was created 2. How can one check whether vcredist for VS8 was installed or not on that machine 3. Anyone knows of a problem with VC8-SP1 built images requiring extras beyond said vcredist TIA, Tzal. "I don't know what vcredist is but it probably is not the recommended solut ...Show All

  • polymorphicx Compiler Crash

    OK I know I shouldn't have written it, it was a result of some slow responses on the machine that a class name got replaced by a bracket, and I;ve thrown away a lot of unnecessary stuff however:make a file containing typedef struct {} (; And the compiler will crash. .Net 2005, I haven't tried it on 2003 or Team System. BTW I saw another "compiler crash" thread http://forums.microsoft.com/MSDN/ShowPost.aspx PostID=323623&SiteID=1 That referred the submitter to http://lab.msdn.microsoft.com/productfeedback/default.aspx So I went there - and ended up back here. Andy   Andy Champ wrote: Still, if Corporate Microsoft's view of a report that someone raises saying that they (MS)&nbs ...Show All

  • lostromich HELP WITH CIN.GET

    my program builds and runs when i try to use cin.get while the program is running it doesn't input using cin.get here is my code(note it is not entirely done but it still builds/works): #include <iostream> #include <fstream> using namespace std; int main() { ofstream out; char task[50]; char due_date[50]; char classnumber[50]; out.open("todo.txt"); if (!out) cout<<"error"<<endl; else { cout<<"What is your task name :"<<endl; cin.get(task,50,'/n'); cin.get(); cout<<"What is the due date :"<<endl; cin.get(due_date,50,'/n'); cin.get(); cout<<"What is the class # :"<<endl; cin.get(classnumber,50,'/n'); cin.get(); out<<task; out.put(':'); out. ...Show All

  • Bartosz Using Visual Styles in VC++ 6

    Can anybody give me a sample code for using visual styles in VC++ 6. I wanted to display texts using XP's font and style. Urgent. I wanted to display some caption text using the font of XP's current theme. One more thing I needed is, to draw lines using the color of current theme. I wanted to display texts and drawings(lines) using XP's style in an activex control. I don't have using any controls in it. Just an image with few lines and a caption for that. Please hepl me. what exactly do you want to look like XP The caption of the window, for example text and drawing should not be affected by or related to XP visual styles. Can you give an ...Show All

  • Andrew XYZ faulted while dumping object

    Hello, I' ve added #define _CRTDBG_MAP_ALLOC #include <stdlib.h> #include <crtdbg.h> in the "stdafx.h" Header and "_CrtDumpMemoryLeaks();" in my program. If I run and stop my program, I got the following error message in the output window: "Detected memory leaks! Dumping objects -> {62} client block at 0x003B3358, subtype c0, 64 bytes long. faulted while dumping object at $003B3358, 64 bytes long Object dump complete." If I set a memory breakpoint at that memory allocation number, the program doesn't break. Has someone an advice, how I can identify the memory leaking object Thanks for your help. I replaced "_CrtDumpMemoryLeaks()" with " ...Show All

  • Febin error C3861: 'wsprintf': identifier not found

    New to c++ using Visual C++ 2005 Express Edition Created a new "CLR/windows form application". added a "wsprintf" line and got " error C3861: 'wsprintf': identifier not found" will appreciate any help. following the test1.cpp source // test1.cpp : main project file. #include "stdafx.h" #include "Form1.h" using namespace test1; [STAThreadAttribute] int main( array <System::String ^> ^args) { char Fname [50]; int i = 1; wsprintf (Fname, "Abc_%2d.txt" ,i); // Enabling Windows XP visual effects before any controls are created Application::EnableVisualStyles(); Application::SetCompatibleTextRenderingDefaul ...Show All

  • mkrtchyan.arsen problem with /NODEFAULTLIB linker option

    Hello, I'm trying to compile a C++ code with /clr option and remove all references to the default library. I want to only analyze the output code and do not need to run it. I used the /NODEFAULTLIB option and got two liker errors: Error 1 error LNK2001: unresolved external symbol " .cctor@@$$FYMXXZ " ( .cctor@@$$FYMXXZ ) main.obj Error 2 error LNK2001: unresolved external symbol _mainCRTStartup Test1 To resolve the second error, I changed the project type to .dll and set the /NOENTRY option in the Liner/Advanced properties. Now I'm stuck with the first error. It seems it is looking for the constructor of some object. I'm guessing if I define a dummy object with proper name, this should be resolved too. Is that ...Show All

  • Jon Derbyshire SetWindowsHookEx making all console apps come to a crawl.

    I have a case where my Windows process uses SetWindowsHookEx to inject a WH_KEYBOARD hook in all processes of the desktop. Everything works as expected except in the case of console applications; including cmd. While my process is running, in console applications, typing is very slow almost like there is a delay in each keyboard event. This is the case even if I have my KeyboardProc does nothing except call CallNextHookEx. All Windows processes are unaffected; it's only console apps. I debugged cmd and found that my DLL never gets loaded in the cmd process, which I would expect since console apps shouldn't bind to User32. I know of other hooks on my computer from other installed software that don’t have the same effect as my hook. A ...Show All

  • CaptainSmudge Hot to retrieve the date and and time of a system??

    Dear all, Any one can remind me on how to retrieve the Date, Time or Datetime of a system using stndard C++ and wich header file should I use. I am using win32 C++ with Visual C++ 2005 express edition on windows xp Regards Bassam Thanks for reminding me Mike Danes. Regards Bassam For the C Runtime Library, the Run-Time Routines by Category  is a very useful reference.   "but I can't get it to print them all on the same line" Easy, replace endl with something else like the ":" character for example: cout << ptm->tm_hour<< ":"; cout << ptm->tm_min<< ":"; ...Show All

697071727374757677787980818283848586

©2008 Software Development Network

powered by phorum