-
- Decimal value of a char in Visual c++
by JGLP
- 8 Replies
- Last post
by Simple Samples
- Hi everybody I need to input a char and then return the decimal value of it. so i use this code: AllocConsole(); ConsoleKeyInfo cki; cki = Console::ReadKey(); //click 'a' for this example.the decimal value of 'a' is 97 String^ aux = cki.KeyChar.ToString(); //i need the aux to be 97, and not 'a' Using the debug step-by-step i see the variable cki {_keyChar = 97 'a' _key=A _mods=0} and the
-
- Question about call ShellExecute from Nt Service
by gundomcz
- 4 Replies
- Last post
by gundomcz
- Hi, When I call ShellExecute from a NT Service like this: ServiceRun () // service thread { if (GetInputFromXXX ()) // Get Input from some device { // Just open a txt file with Editplus.exe program ShellExecute( NULL, "open", "C:\PROGRAM FILES\EDITPLUS\EDITPLUS.EXE", "E:\PROG\WINDOWS\APP\MOUSEMUTILKEYS\MOUSEMUTILKEYS\TMP.TXT", "",
-
- How make one object to be visible in two froms?
by shiki_ilija
- 2 Replies
- Last post
by SThotakura2
- I load one form from another and I want the object of the second form to be visible in the main.How to make that.I tried to make public but nothing...
-
- Meyers and iteration operators
by Shakje
- 4 Replies
- Last post
by Shakje
- A colleague and I were chatting about it earlier, and I was just wondering where does Meyers talk about using ++a instead of a++ I can't seem to find it easily, wondering if someone could remind me of the reasoning behind it (even though it probably doesn't make any difference at all anymore) for curiosity's sake.
-
- declaring zero size array in vc++
by pavan_734
- 9 Replies
- Last post
by Peter Ritchie
- Hi,
Suppose I have defined an empty array like this:
int array[] = { };
This will compile in linux but Iam getting following error in windows:
error C2466: cannot allocate an array of constant size 0
What is the work around for this problem
-
- Application in release mode crahes on win2k
by adii28
- 9 Replies
- Last post
by adii28
- Hello, I have a win32 application built using vc++ 6.0. When I do the release build on the machine which I developed the application on which is running win XP Prof SP2, the release versions runs fine. But when I deploy the release version onto the actual box where it will run which is a windows 2000 box the application crashes. I have extensivly used STL in my aplication (std: tring, vecotrs and
-
- How to read specified line from a text file ?
by hanoi
- 2 Replies
- Last post
by Giovanni Dicanio
- Hello everyone !
I have a problem in reading file. Assuming that i have a text file which named: thanhly.txt. This file has 5 lines as below:
We are the world !
We are the children !
We are the farmers!
We are the workers !
We are ther engineers !
Problem is how to read fourth line in file. Can anyone help me
Function i need like: mygetline( char * filename
-
- Attempt to load an unverifiable executable with fixups exception
by Eby
- 1 Replies
- Last post
by Bite Qiu - MSFT
- Hi,
I am having an mfc application with clr support. I added a reference to a c# assembly and tried to subscribe to its events.This raised an exception while subscribing.
Attempt to load an unverifiable executable with fixups (IAT with more than 2 sections or a TLS section.) (Exception from HRESULT: 0x80131019)
The code that raised the error is
object->event+= gcnew Eve
-
- Disabling the CRL (Visual C++ 2003)
by Matt.J
- 13 Replies
- Last post
by talewisx
- Hi,
I would like to know if it is possible to disable VC++ from implementing the CRL, hence preventing my code
being compiled with the inclusion of (hidden) calls to the runtime library as I have no need for it.
I don't use features that depend on the CRL, such as classes, and have resorted to 'dropping in' assembly to prevent the use of the CRL as much as possible.
Tha
-
- Error compiling 64 bit VS 2005 __in is not recognized
by Govindh
- 5 Replies
- Last post
by Govindh
- Hi,
I am trying to compile our applications targeting the 64 bit platform but am getting the following error.
c:\program files\microsoft sdks\windows\v6.0\include\certbcli.h(187) : error MIDL2025 : syntax error : expecting a type specification near "__in"
2>c:\program files\microsoft sdks\windows\v6.0\include\certbcli.h(188) : error MIDL2025 : syntax error : expecting
-
- What is the perf difference between locking a byte in a file using LockFile and waiting for a Mutex?
by Youngman
- 0 Replies
- Last post
by Youngman
- Hi,
I am working on a project that needs to synchronizing multiple processes accesing a resources (could be a file). I have the choice of using LockFile() to lock a byte in a tmp or simply using a mutex for synchronizing access to the shared resource.
I like to find out if there is any difference in performance between the two options.
Any help is appreciated.
Thanks.
-
- Problem in Image Retrieving
by krishnasamy
- 14 Replies
- Last post
by Ramkrishna Pawar
- Hi,
I am retrieving the image from DLL through vc++ dll. Actually Image is retrieving in Callback function of main function. When I writing that image file inside of the Callback function then no problem in retrieving. At the same I want to send the Imagedata to the another function and write the same which cause the error.
Here I given that code,
//Callback function
pr
-
- How to deploy CRT as a shared assembly without using MSI, ClickOnce or vcredist_x86.exe?
by kto
- 5 Replies
- Last post
by Bite Qiu - MSFT
- I'm trying to deploy an application built with VC 2005. It includes few DLLs which might be called by other components than my own. I'm using dynamic linking so the only option is to have the runtime-libraries installed as shared assemblies. So far I haven't found a solution which wouldn't be based on either using MSI with merge modules, ClickOnce or vcredist_x86.exe. None of these is suitable in
-
- add and carry command in inline assembler
by lego434
- 1 Replies
- Last post
by Sdi
- I expected adc to produce 1 in EDX and 0xfffffffe in EAX when I add
0xffffffff and 0xffffffff. II do fet 0xfffffffe in EAX but EDX has some
u nexpected number in it. Where has the carry disappeared to
-
- registry Keys reading problem VC++ 6.0
by Rajesh Ghole
- 1 Replies
- Last post
by Viorel.
- Hi all I have used a registry key in my program and i write the key using RegSetValueEx(hKey, l_strStringSample, 0, REG_SZ, (LPBYTE) pathSelected.GetBuffer(pathSelected.GetLength()), pathSelected.GetLength()+ 1); the writing is working fine but while reading the key using RegQueryValueEx( hKey, // handle to key to query l_strStringSample, // address of name of value
-
- How to PostMessage between 2 separate applications?
by EnigMa_AnGeL
- 9 Replies
- Last post
by Brian Kramer
- I'm trying to implement messaging between 2 different applications using PostMessage (HWND_BROADCAST, msg, 0, 0) in one, and setting a On_Message handler in the other. The idea to test this is that when PostMessage is sent from App1, App2 will receive the message with On_Message and call the appropriate handler function. Unfortunately, its seems that this setting doesnt work. I set the message ID
-
- Help! DLL errors when I exited my program
by Lejing
- 12 Replies
- Last post
by Simple Samples
- I developed a prgram, and when I exited my program, I may got the bellow errors, but not always! Could any one give me some suggestions Thank you! 02347d07() kernel32.dll!7c80a017() [Frames below may be incorrect and/or missing, no symbols loaded for kernel32.dll] ntdll.dll!7c94a5d0() msvcrt.dll!77c2c2e3() msvcrt.dll!77c3a243() ntdll.dll!7c94a5d0() kernel32.dll!7c80b6
-
- Linker error porting an NT service from VC 6.0 to VC 8.0 - using a makefile
by OnFileOpen
- 14 Replies
- Last post
by einaros
- I am trying to port a service from VC 6.0 to VC 8.0.
My VC 6.0 service was compiled from the commandline using a makefile.
I created a Makefile project in VC 8.0. I did NOT create a Windows Service project in VC 8.0 because I am not using CLR.
After resolving various compiler and linker issues, the last remaining issue is:
error LNK2019: unresolved external symbol "int __stdcall
-
- NEED HELP WITH THIS PROBLEM... Anybody...?
by AllahIsGreat
- 3 Replies
- Last post
by code_hacker
- Hi,
... ... ... I use the Visual C++ 2005 Compiler... Here below are some of the class that I'm trying to compile...
// ... #include "Wm4TRVector.h"
#ifndef WM4TRVECTOR_H
#define WM4TRVECTOR_H
namespace Wm4
{
template < int VSIZE, int ISIZE>
class TRVector
{
public :
// construction
TRVector ();
TRVector ( const TRVecto
-
- Possible to load msvcp80.dll manually?
by O.Z.
- 0 Replies
- Last post
by O.Z.
- Hi, I have found quite an interesting tutorial at http://www.joachim-bauch.de/tutorials/load_dll_memory.html/en/view When experimenting I've discovered that one can't load dlls built with Visual C 8 this way, because LoadLibrary on msvcp80.dll triggers run-time error that manifest should be used. Is there a way to programmatically "use manifest" so that to load MSVC runtime dynamicall
-
- Has anybody the demo program which has a combox which can select all of the country in the world?
by Jakein2006
- 1 Replies
- Last post
by Sarath.
- Has anybody the demo program which has a combox which can select all of the country in the world
The most importance thing is that it has to including all the country and regions.
I apprecaite your help.
-
- How to change "Caption" of Dialog in run-time
by CryBaby
- 2 Replies
- Last post
by CryBaby
- I need to push two options from menu (two different function), and call the same Dialog, and change to different Caption (Dialog title) due to which function call Caption Location: http://140.134.4.20/~d8825313/1.GIF Example OnCopyFile(){ <... set "Copy" title to dlgOper Dialog ...> dlgOper.DoModal(); } OnMoveFile(){ <... set "Move" title to dlgOper Dialog ...> dlgOper.DoModal(); } I
-
- Visual Studio Compile Settings
by Cookster
- 10 Replies
- Last post
by Eugene Zakhareyev
- I wasn't sure really where to post this but I'm having issues with compiling released products using Microsoft Visual Studio 2005. All programs are written in C++. I have 3 differennt programs I'm trying to compile. 1.) Console application in C++ 2.) GUI application in C++ 3.) GUI application in C++ with .Net framework Now, I've compiled 1 and 2 succesffuly in Bloodshed Dev C++ and was able to run
-
- pseudo-random; time; srand...
by Jerry584894
- 4 Replies
- Last post
by scor7910
- The code:
Code Snippet
#include <iostream> #include <cstdlib> #include <string> #include <fstream> #include <cmath> #include <algorithm> #include <time.h>
using namespace std;
srand( (unsigned)time( NULL )); void main() { }
has these errors:
C:\Documents and Settings\JiangLiu\My Documents\jerryc\Debug\tests.cpp(1
-
- Startup ASSERT Problem
by MacKenrick
- 2 Replies
- Last post
by Damien Watkins - MSFT
- When Windows starts to load I get a Debug Error with a message to see Visual C++ documentation on Asserts. The error line reads:
C:\WORK\nc2_20020220\cyir\naturalcolor\systemtray.cpp Line:124
("Naturalcolor" is a program that came with my Samsung SyncMaster 930b monitor).
When this happens Windows stops loading the other programs in my systems tray. Sometimes I have to reboot se