Click here to Skip to main content
15,903,799 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: Debug Assertion Pin
Stuart Dootson29-Jun-09 22:32
professionalStuart Dootson29-Jun-09 22:32 
GeneralRe: Debug Assertion Pin
Davitor29-Jun-09 23:05
Davitor29-Jun-09 23:05 
GeneralRe: Debug Assertion Pin
CPallini29-Jun-09 23:34
mveCPallini29-Jun-09 23:34 
GeneralRe: Debug Assertion [modified] Pin
Stuart Dootson30-Jun-09 2:27
professionalStuart Dootson30-Jun-09 2:27 
GeneralRe: Debug Assertion Pin
Davitor30-Jun-09 20:53
Davitor30-Jun-09 20:53 
GeneralRe: Debug Assertion Pin
Davitor8-Jul-09 18:16
Davitor8-Jul-09 18:16 
GeneralRe: Debug Assertion Pin
Stuart Dootson9-Jul-09 0:31
professionalStuart Dootson9-Jul-09 0:31 
QuestionHow to handle VSFlexGrid's OnPaste event ? Pin
prasadgates29-Jun-09 20:29
prasadgates29-Jun-09 20:29 
I am working on VC++ project where I am using VSFlexGrid.
I need to copy a string from any editor (e.g notepad, MS Word etc) and after validating for certain

conditions, paste the string in FlexGrid cell, if validations conditions are true.
I have tried using KeyPessEdit event for ctrl+v (ASCII == 22)
I tried something like this :

if(*KeyAscii == 22)
{

// Paste the string in FlexGrid cell

char* tempString= NULL ;
string buffer = NULL ;
bool bIsValidChar = true;
tempString = (char*)GetClipboardData(CF_TEXT);
for(int i = 0; '\0' != tempString[i]; i++ )
{
if( (tempString[i] >= 65 && tempString[i] <= 70 ) || tempString[i] >= 48 && tempString[i] <= 57))
{
continue;
}
else
{ bIsValidChar = false;
break;
}
}

But in this case before control reaches to 'bool bIsValidChar = true;' string copied from elsewhere gets pasted in FlexGrid cell. That means by default implementation of Paste method of FlexGrid is getting called.

So how can I do my validations and then allow or disallow the pasting of string in a cell.
How can I handle FlexGrid's OnPaste event ?
AnswerRe: How to handle VSFlexGrid's OnPaste event ? Pin
Madhu Nair29-Jun-09 22:30
Madhu Nair29-Jun-09 22:30 
AnswerRe: How to handle VSFlexGrid's OnPaste event ? Pin
ThatsAlok30-Jun-09 0:47
ThatsAlok30-Jun-09 0:47 
QuestionQuerry!! Pin
Razanust29-Jun-09 20:20
Razanust29-Jun-09 20:20 
AnswerRe: Querry!! Pin
Chandrasekharan P29-Jun-09 20:30
Chandrasekharan P29-Jun-09 20:30 
AnswerRe: Querry!! Pin
Razanust29-Jun-09 20:37
Razanust29-Jun-09 20:37 
AnswerRe: Querry!! [modified] Pin
Harsh Shankar29-Jun-09 21:40
Harsh Shankar29-Jun-09 21:40 
AnswerRe: Querry!! Pin
Michael Schubert29-Jun-09 21:41
Michael Schubert29-Jun-09 21:41 
GeneralRe: Querry!! Pin
Harsh Shankar29-Jun-09 22:44
Harsh Shankar29-Jun-09 22:44 
GeneralRe: Querry!! Pin
Michael Schubert29-Jun-09 23:03
Michael Schubert29-Jun-09 23:03 
GeneralRe: Querry!! Pin
Harsh Shankar29-Jun-09 23:12
Harsh Shankar29-Jun-09 23:12 
GeneralRe: Querry!! Pin
Michael Schubert29-Jun-09 23:29
Michael Schubert29-Jun-09 23:29 
AnswerRe: Querry!! Pin
Rajesh R Subramanian29-Jun-09 22:35
professionalRajesh R Subramanian29-Jun-09 22:35 
AnswerRe: Querry!! Pin
Aric Wang29-Jun-09 23:27
Aric Wang29-Jun-09 23:27 
AnswerRe: Querry!! Pin
David Crow30-Jun-09 3:36
David Crow30-Jun-09 3:36 
Questionhow to set an image as background for dialog box or form Pin
suthakar5629-Jun-09 18:56
suthakar5629-Jun-09 18:56 
GeneralRe: how to set an image as background for dialog box or form Pin
Michael Dunn29-Jun-09 19:01
sitebuilderMichael Dunn29-Jun-09 19:01 
GeneralRe: how to set an image as background for dialog box or form Pin
«_Superman_»29-Jun-09 21:40
professional«_Superman_»29-Jun-09 21:40 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.