|
Can you show any example of this.
Thanks.
IN A DAY, WHEN YOU DON'T COME ACROSS ANY PROBLEMS - YOU CAN BE SURE THAT YOU ARE TRAVELLING IN A WRONG PATH
|
|
|
|
|
Hi,
there is an excellent Codeproject article called CFilterEdit: Use Regular Expressions to filter your input by Ben Hanson. This can serve you well as a base clase for your problem.
http://www.codeproject.com/KB/edit/FilterEdit.aspx[^]
There are already some sample derived classes like
* CCurrencyEdit
* CDateTimeEdit
* CFloatEdit
* CIntEdit
* CUIntEdit
* CUIntRangeEdit
* CSpin
So long,
Stefan
|
|
|
|
|
Hi all;
i m using this on PreTranslateMessage(MSG* pMsg)
if (pMsg->message == WM_KEYDOWN && (pMsg->wParam == VK_RETURN))
{
UINT CtrlID = ::GetDlgCtrlID( pMsg->hwnd );
// Check whether its that of your button.
if( CtrlID != IDOK &&
CtrlID != IDCANCEL && )
{
pMsg->wParam = VK_TAB;
}
}
for using both on Tab key and enter key on controls execpt button controls.
Now on presssing Tab key the button is clicked.
I dont want to press button on Tab key.
Please tell me what can i do?
I m waiting for ur valuable suggestions.
Thanks in advance.
IN A DAY, WHEN YOU DON'T COME ACROSS ANY PROBLEMS - YOU CAN BE SURE THAT YOU ARE TRAVELLING IN A WRONG PATH
modified on Friday, July 25, 2008 1:17 AM
|
|
|
|
|
The simple solution just remove the tab stop style from button controls.
modified on Friday, July 25, 2008 2:19 AM
|
|
|
|
|
Hi all,
I am making some connections with gsoap and services as I am looking into an example program I notice why this is possibe:
class CMyCurrencyConvertor
{
public:
CMyCurrencyConvertor();
virtual ~CMyCurrencyConvertor();
bool GetConversionRate(CString sFromCurrencyCode,CString sToCurrencyCode, double &dRate);
bool GetConversionRate(ns1__Currency oFromCurrencyCode,ns1__Currency oToCurrencyCode, double &dRate);
Can someone explain to me the double meaning of GetConversionRate()
thanks,
Jayjay
|
|
|
|
|
That is function overloading. Allows you to use functions with the same name that do similar tasks. Based on the parameters of the function the compiler decides [runtime] which version of the function does it give a call to.
For eg: if you have to add two numbers irrespective of the parameters to the Add function you can simply write:
void Add(int a, int b);
void Add(float a, float b);
it would really be a bit cryptic if you want to add two numbers and have to write functions as
void AddInt(int a, int b);
void AddFloat(float a, float b);
you would need hundreds of names in case you want to add different types of variables and write functions for them.
In essence function with the same name do similar tasks. In your case they give you the Conversion Rate with different parameter types
Somethings seem HARD to do, until we know how to do them.
_AnShUmAn_
modified on Friday, July 25, 2008 1:03 AM
|
|
|
|
|
I need some quick help with this problem:
I've created a simple video player using DirectShow.
When I set playing a video file (f.e. wmv) I need do some file decryption (file is encrypted with own algorithm) before playing the movie stream - during reading data from file into DirectShow's stream buffer.
I need some ideas, how can I do this:
> Open video file > fread(buffer, bufflen) / apply buffer decryption -> redirect to DirectShow (apply filters, etc.) -> Play
Thank you for any support
|
|
|
|
|
For DirectShow, you'll probably need to write your own transform filter that
decrypts the raw file data and passes it downstream unencrypted.
Writing DirectShow Filters[^]
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
Thanx, I've done it during today, but created a Source filter (file reader). The transform filter won't work as well
|
|
|
|
|
Hello,
Is there a way to can send parameters through command line to the executable that is already active.
Let me explain my requirement clearly.
I have an exe which accepts command line parameters and one of the command line parameter is a file name. Now i need to input another file while the exe is still running.
Please let me know if there a way to acheive this?
Thanks,
Hari krishna.
|
|
|
|
|
You probably need some sort of IPC [^].
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
[My articles]
|
|
|
|
|
Not possible since the application is only started once, and thus main() is only called once.
"Love people and use things, not love things and use people." - Unknown
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
Adarapu Harikrishna wrote: Is there a way to can send parameters through command line to the executable that is already active.
Yes. You could have the program prompt the user to supply the new file name.
led mike
|
|
|
|
|
may be a solution:
you run the app #1
in MSG processing define an own message, f.e. WM_OWNMSG
run app #2
handle the command line parameters
find/catch the main window of app #1 (f.e. throu FindWindow(...); )
send the cmdline parameters throu SendMessage(FindWindow(...), WM_OWNMSG, (LPARAM)cmdline, (WPARAM)whatWithIt);
modified on Thursday, July 24, 2008 7:07 PM
|
|
|
|
|
You got the communicate between your 2 apps. If the have Windows (HWND) you can post messages with approbiate values. Or make a network connection, write something in registry (file) were the other app have to read repeatedly.
Greetings from Germany
|
|
|
|
|
Dear All
As I write in subject part, I want to change the size of a static box by programming.
But I didnt know how to do that.
Thus please help me.
Regards
|
|
|
|
|
What about SetWindowPos [^]?
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
[My articles]
|
|
|
|
|
|
I have some static text control that I want user to be able to copy the text out. However I could not find an easy way of doing that, can someone shed some light on how this can be done?
Thanks!
|
|
|
|
|
A read-only edit control? That would allow scrollable text as well.
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
Sure, that is a good way of doing it. But I have a CStatic derived class which can Resize itself to fit the text. If I switch to CEdit I will loose the func.
Any good CEdit with resize functionality.(Not just scrollbar but grow itself if text is too much)
Thanks,
|
|
|
|
|
Well, probably won't be a daunting task porting such functionality to a CEdit derived class.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
[My articles]
|
|
|
|
|
Troll[^] attack.
Just fixed this[^].
Many are stubborn in pursuit of the path they have chosen, few in pursuit of the goal - Friedrich Nietzsche
.·´¯`·->Rajesh<-·´¯`·.
[Microsoft MVP - Visual C++]
|
|
|
|
|
Thank you pal. Balanced.
BTW balanced stupid troll's vote here [^] too.
BTW2: you are almost at 5,000 posts. Congratulations.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
[Image resize DLL]
|
|
|
|
|
CPallini wrote: BTW2: you are almost at 5,000 posts. Congratulations.
ThankZ frand. Itz all bekaz of THHB.
Many are stubborn in pursuit of the path they have chosen, few in pursuit of the goal - Friedrich Nietzsche
.·´¯`·->Rajesh<-·´¯`·.
[Microsoft MVP - Visual C++]
|
|
|
|