|
It really pisses me off when intellisense occasionally does not work. I'll try deleting .ncb and see if it works then. Thx for the tip
|
|
|
|
|
Hi all,
In my application, i created the property sheet with six property pages.. The property pages are appeared as 2 rows in tab control of the property sheet. I want to display the dialog property pages in a single row. Any one please give me the suggestion to achive this.
Regards,
Prakash
A Journey of thousand miles must begin with a single step.
|
|
|
|
|
I could be wrong on this diagnosis but I think you need to set the style of the tab control so that it doesn't have the TCS_MULTILINE property.
CTabCtrl* pTab = MyPropertySheet.GetTabControl ();
pTab->SetStyle (pTab->GetSylte & ~TCS_MULTILINE); I think that should remove the TCS_MULTILINE style from the tab control.
- Aaron
|
|
|
|
|
Hi,
I got the solution using EnableStackedTabs() method available in CPropertySheet class
Regards
Prakash
A Journey of thousand miles must begin with a single step.
|
|
|
|
|
Hello palls,
I am a C beginner and sti have some probems with memory allocating.
I know how to do it with a 1 dimension array but it doesn't work with a 2 dimension one, and please, how about to free them
|
|
|
|
|
Here is one solution.
char **pArray = new char *[1];
pArray[0] = new char [32];
...
delete [] pArray[0];
delete pArray;
Kuphryn
|
|
|
|
|
please do not forget that delete [] pArray[0]; did not free all memory because some time it does not know how long is the array. if you want to be shure that all memory are free you have to free memory like:
for(int i = 0; i < 32; i++)
delete pArray[i];
and of course delete pArray.
|
|
|
|
|
Currently I had a MFC program written in Microsoft Visual Studio VC++ 6.0.
But it can only be run on a single machine.I would like to change it to web version, which can be browsed by the browser. Is there any efficient ways to do this without rewriting the whole program?
Thanks a lot.
chad yang
|
|
|
|
|
chad_yang wrote:
Is there any efficient ways to do this without rewriting the whole program?
Try Taking snapshots of all the screen and save individual HTM pages and then ..... NAH can't be done like that
i can't even remember what my point is now, but anyway, i'm correct
Barring unforeseen acts of God and Adminstrators, my server will be up tomorrow. I'm more worried about the Adminstrators.
|
|
|
|
|
Umm...
I see....
But does the "ActiveX control" help?
Thank you.
chad yang
|
|
|
|
|
Hi all,
I want to control the menus and toolbars of MS office document which is embedded in my application.for the same i am using a MFc app. and have embedded MS-Word application using Edit->Insert New Object selecting MS word document from Dialog box.
Now how i can capture the events from menus and toolbar in my application.?
I have googled for the same,but not able to find any relevent infomation.
May be i am using wrong keywords.
Can someone reply me how to start with, any articles or sample code will be a great help.
Thanks in Advance,
Abhishake
|
|
|
|
|
try to find something into http://www.codeproject.com/com/xoffice.asp
|
|
|
|
|
how shall i add a button to IE toolbar using VC++. as givent in the following link.
http://msdn.microsoft.com/library/default.asp?url=/workshop/browser/ext/tutorials/button.asp
plz help me..
ComputerNewton
|
|
|
|
|
How to change the description of an service shown in SCM
|
|
|
|
|
SC_HANDLE hSCM;
hSCM = OpenSCManager(
NULL,
NULL,
SC_MANAGER_ALL_ACCESS
);
if(hSCM==NULL)
{
LOGERROR("ERROR opening SC manager");
}
SERVICE_DESCRIPTION sd;
sd.lpDescription=sDescription;
SC_HANDLE hService=OpenService(hSCM, "My Service", SERVICE_ALL_ACCESS);
ChangeServiceConfig2(hService, SERVICE_CONFIG_DESCRIPTION,&sd);
CloseServiceHandle(hService);
CloseServiceHandle(hSCM);
It's not a bug, it's an undocumented feature. suhredayan@omniquad.com
messenger :suhredayan@hotmail.com
|
|
|
|
|
I'm starting work on an MFC-based MDI project (does not use document-view architecture). If completed, it will employ some three dozen view classes, each consisting of 2 or more dot-CPP/dot-H pairs. This will make the project space somewhat crowded.
I was thinking of organizing the view-class files in static libraries, to reduce clutter and increase comprehensibility of the workspace.
Can anyone comment on this? Is there a better way?
Thanks, RD
|
|
|
|
|
I have been using the following section of code to send data to COM1:, but keep getting the error 87 = 'Incorrect function' when I send data to the port.
Note I have setup the device as a generic text printer and that works OK.
Code Listing:-
DWORD cbWritten; // No of bytes written
char mystring[255]; //string variable
int len; //Init the len variable for use of sizing our string
int error;
//set the handle for the CreateFile function
HANDLE hCom = CreateFile( "COM1:",GENERIC_WRITE | GENERIC_READ ,0, 0, OPEN_EXISTING, 0, NULL);
//Init the settings for the DCB (device control block) structure
DCB dcb; //Init the device control block
dcb.BaudRate = 300; //set baud rate
dcb.ByteSize = 8; //Set Bytes
dcb.Parity = NOPARITY; //Set Parity
dcb.StopBits = ONESTOPBIT; //Set stop bit
dcb.fTXContinueOnXoff=TRUE; // XOFf Sent Does Not Stop trans
dcb.fOutX=FALSE; // No Xon/Xoff on Output
dcb.fInX=FALSE; // No Xon/Xoff on Input
dcb.fErrorChar=FALSE; // No error Char in Parity Error
dcb.fNull=FALSE; // Accept Null Characters
dcb.fRtsControl=RTS_CONTROL_DISABLE; // No RTS Flow Control
dcb.fDtrControl=DTR_CONTROL_DISABLE; // No DTR Flow Control
dcb.fAbortOnError=FALSE; // Do Not Abort on error
//Set the port state
error = SetCommState(hCom, &dcb);
if(error != 0)
{
printf("Error Sending Data %d \t", GetLastError());
DisplayErrorText(error);
}
else
printf("State Set OK \n");
//get and size what's gotten
printf("Enter string: ");
gets(mystring); //Get input from keyboard
len = strlen(mystring); //get true length of string
//Output to the com port
error = WriteFile(hCom, mystring, len, &cbWritten, NULL); //write mystring to port
if(error != 0)
{
printf("Error Sending Data %d \t", GetLastError());
DisplayErrorText(error);
}
error = WriteFile(hCom, "\r\n", 2, &cbWritten, NULL); //write return and newline to port
if(error != 0)
{
printf("Error Sending CR/LF %d \t", GetLastError());
DisplayErrorText(error);
}
if(FlushFileBuffers(hCom) == 0)
{
printf("Faied To Flush Buffers \n");
}
printf("Enter Key to Close: ");
gets(mystring); //Get input from keyboard
CloseHandle(hCom); //close the handle
return 0; //exit
|
|
|
|
|
BOOL WriteFile(...) where if COM sending is successful return TRUE otherwise FALSE.
Change: if(error != 0) into if(error == FALSE) and read cbWritten to checkout numbers of characters that COM send.
if(cbWritten != len)
...
|
|
|
|
|
OK thanks, now getting the data through, but only when the program exits.
|
|
|
|
|
http://www.codeproject.com/system/serial_com.asp for more details.
|
|
|
|
|
get the number of records in an array of data structure after reading in a binary file?
|
|
|
|
|
How you read the array from the file?
Robert-Antonio
"Science is a differerntial equation.
Religion is a boundary condition."
|
|
|
|
|
number of bits in files divide with size of one structure.
|
|
|
|
|
i want to connect Oracle database inserver.and install Oracle client in my PC.how can i connect the database with ADO(not using ODBC)
|
|
|
|
|
sConnString = _T("Provider=MSDAORA;Data Source=MyOracleDB;User Id=myUsername;"
"Password=myPassword;");
It's not a bug, it's an undocumented feature. suhredayan@omniquad.com
messenger :suhredayan@hotmail.com
|
|
|
|