|
It should return a zero-based index...
They sought it with thimbles, they sought it with care;
They pursued it with forks and hope;
They threatened its life with a railway-share;
They charmed it with smiles and soap.
|
|
|
|
|
Hello,
Yes, you are right, now its working. thanks.
Regards,
A. Gopinath.
|
|
|
|
|
Hi frnds,
anybody knows how to do it?
|
|
|
|
|
A C++ Implementation of the Rijndael Encryption/Decryption method [here].
Article explaining how to decrypt a file in C# using Rjindael Algorithm [here] and [here].
|
|
|
|
|
I construct a CRange object and then call CRange's function get_shapeRange() to get a CShapeRange object.
but it triggers an exception. (but it's OK to call another function get_InlineShapes) I have no idea why it triggers an exception.
does anyone knows why? thanks.
========================================================
By the way, I call this code in a keyboard hook function.
|
|
|
|
|
A question first : Are you using COM Interop?
When an exception is triggered, it is indicative that the function cannot be found.
You talk about Being HUMAN. I have it in my name
AnsHUMAN
|
|
|
|
|
Yes, you are right. but what I can't understand is in VBA corresponding code works fun.
VBA code below:
selection.range.shaperange works fun
=================================================================================
I'm sorry! in word2010 it works fun. in word2003 not fun. oh, my god!!!
modified 8-Aug-12 21:38pm.
|
|
|
|
|
now it works fun again!!! what have I done!!!!!!
|
|
|
|
|
BianChengNan wrote: does anyone knows why? There is probably a bug in your code. You need to provide a snippet of the code and full details of the exception if you want a better suggestion.
One of these days I'm going to think of a really clever signature.
|
|
|
|
|
thanks for your tip. code looks like following.
bool isRangeShape(__in CRange& oRange)
{
AFX_MANAGE_STATE(AfxGetStaticModuleState());
CShapeRange oShpRange = oRange.get_ShapeRange();
long lCount = oShpRange.get_Count();
if (lCount > 0)
{
return true;
}
return false;
}
modified 8-Aug-12 21:37pm.
|
|
|
|
|
I don't know why it works fun again. (but I think it should work fun!)
thanks for your help!
|
|
|
|
|
How to Decrypt file in C# that Encrypted in C using same Rijndael Algorithm?
|
|
|
|
|
Using the Rijndael algorithm implemented in C# (Microsoft gently provides it: "Rijndael Class"), of course.
Veni, vidi, vici.
|
|
|
|
|
Hi, dear all,
I have a license check exe file with only one argument.
CString exe = getCurrentProjectPath(); //e.g, C:\Temp
CString pwd = "12345"
CString exeString = exe + " \"" + pwd + "\"";
system(exeString);
everything works fines with above codes.
But if I put double quota between exe, I get "filename, .... syntext is incorrect".
CString exeString = "\"" + exe + "\" \"" + pwd + "\"";
But if I don't put exe data in a quota, if the path has space, it also cannot work.
How should I solve this issue? Thanks!
|
|
|
|
|
CString exeString = (CString)"\"" + exe + (CString)"\" \"" + pwd + (CString)"\"";
EDIT:
Added space between quotes.
The difficult we do right away...
...the impossible takes slightly longer.
modified 7-Aug-12 17:24pm.
|
|
|
|
|
Richard, thanks for your reply.
I try using double quota around all the arguments, not work.
If you have multiple arguments that all are in double quota, you need to use "call".
The following line works fine.
CString exeString = "call \"" + exe + "\" \"" + pwd + "\"".
|
|
|
|
|
You might find it better to use one of the exec() [^] functions.
One of these days I'm going to think of a really clever signature.
|
|
|
|
|
|
Then you should change the subject on your question and put a SOLVED at the end or at the beginning.
And it would be nice that you would put the answer/solution there too.
|
|
|
|
|
Hi,
I have one dialog box. I have picture control on that dialog. I'll draw two masks on the canvas using OnMouseMove functionality. one mask is completed, another one is incomplete mask (only a line drawn using pen). When I remove/delete the completed mask, incomplete doesn't get deleted but its not visible. How to show the line after removing the completed mask in MFC.
Anybody have any idea regarding this.?
Thanx in advance.
Regards,
|
|
|
|
|
mbatra31 wrote: How to show the line after removing the completed mask in MFC.
draw the line again?
|
|
|
|
|
Do you draw the stuff from a WM_PAINT handler? Because you should do so!
|
|
|
|
|
Hello everybody,
i am having n-number of points like p1(x,y), p2(x,y), p3(x,y), .... pn(x,y). All points lie on a single line.(either a curve or a straight line). i would like to find, using those points, whether that line is straight or not straight.
i googled and tried some of the methods given in examples, (straight line equation, finding if collinear) but those are not working fine even for straight line also.
i am using visual studio 2008 with win32 (not MFC).
Any ideas ?
Thanks in advance,
A. Gopinath.
|
|
|
|
|
The problem is one of mathematics not programming; once you find the mathematical solution, converting it to C/C++ is the easy part.
One of these days I'm going to think of a really clever signature.
|
|
|
|
|
Hello Richard,
Yes, i know its a mathematics question, i tried here so that someone can help me.
Thanks for the reply.
Regards,
A. Gopinath.
|
|
|
|