|
Hi.
I want to restrict entering unicode characters in the edit box on a dialog. Could you please give any idea to handle this.
Mohan
|
|
|
|
|
Gday,
You need to look into input filtering. It's just a matter of sub-classing the edit control, passing only the allowed characters as input, while discarding undesired ones.
Here's an article that deals with input filtering. Enhanced Focus Edit Control with Input Filtering[^]
|
|
|
|
|
|
|
I don't know Zuma, but if you are interested in making a game in OpenGL, you can have a look at a series of articles I wrote. See here[^]
|
|
|
|
|
Hi,
I am trying to create a c++ dll in vs2008 and I have exported the sample function and class available in the files created (by using the export symbol option when the dll created). My problem is that whenever I try to call a the dll I get an error saying that no entry point is found in the dll.
I have manged to get C++ dlls working with vs 2005 and by using dllexport, however things seem to be a little different in vs 2008.
Any help is much appreciated.
Thanks
|
|
|
|
|
The syntax for exporting functions and classes have remained the same for a very long time and it has not changed with VS 2008.
You need to give some more information like -
How are you linking the dll to the exe.
In which language and VS version is the exe developed in.
Some code snippets would be helpful.
«_Superman_»
I love work. It gives me something to do between weekends.
|
|
|
|
|
Hi,
Thanks for the reply.
I am linking the dll to the exe using P/Invoke. The exe is developed in C# VS 2008.
When I use the export symbol option when creating the dll it creates a sample class with a constructor and a independent function (which are said to be exported). I am not sure how to instantiate this class or to call the independent function from the C# application.
|
|
|
|
|
Not totally sure, but I think P/Invoke only supports "C" linkage.
That means you can call exported functions but not exported classes.
If so, you will need to create a wrapper in C++ that export only functions and these functions can delegate function calls to the C++ class.
«_Superman_»
I love work. It gives me something to do between weekends.
|
|
|
|
|
Thanks for the info. I'll check out using a wrapper. It would be nice if I can get the class exported also.
|
|
|
|
|
what is the exact code to get the value of the editbox (variable type double) and displays in the listbox?
i tried : m_list.GetText(m_list.GetCurSel(), m_edit1) and m_list.GetText(m_edit1) but after building committed errors...
please help.
|
|
|
|
|
Neil Jigger wrote: what is the exact code to get the value of the editbox (variable type double) and displays in the listbox?
CString str;
m_edit.GetWindowText(str);
m_listbox.AddString(str);
"Old age is like a bank account. You withdraw later in life what you have deposited along the way." - Unknown
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
|
|
|
|
|
--------------------Configuration: g - Win32 Debug--------------------
Compiling...
gDlg.cpp
C:\Program Files\Microsoft Visual Studio\MyProjects\g\gDlg.cpp(179) : error C2039: 'GetWindowTextA' : is not a member of 'CString'
c:\program files\microsoft visual studio\vc98\mfc\include\afx.h(368) : see declaration of 'CString'
Error executing cl.exe.
g.exe - 1 error(s), 0 warning(s)
still i cannot get the right code...
|
|
|
|
|
Yes.. SetWindowText is not a member of CString.
I assume you are using a textbox. make a variable of control type.
Something like this
CEdit m_edit
and then compile the code.Hope this helps.
|
|
|
|
|
Wanting to know how to create payload as a block of binary data for DNS packet.
I have something in C but i was looking to increase the payload size. (test purposes)
|
|
|
|
|
char *buffer;
buffer = new char[bufferSize + extraSize];
sendto(socket, buffer, bufferSize + extraSize, flags, &destAddr, destaddrSize);
1300 calories of pure beef goodness can't be wrong!
|
|
|
|
|
im using Nemesis DNS generator so im going to call the file to be used and within the file are only datatype and i use the %c and %s to identify dateype when formatting the output
fp = fopen ("datafilename.dns"), "w");
fprintf(fp, "%c%c%c%c, 0x00, 0x01 ")
fprintf(fp,"%c%s, 0x03, "www");
etc......
fclose(fp);
your code may do the same but i am not a strong programmer and was wonder if you could explain if you code does what this does and point me to some reading material
|
|
|
|
|
|
|
but like i said, i already created the attack now im trying to generate a bigger one so i will be able to prevent it. you know the gov. created a company who's sole purpose is internet security so i understand that u may think i want this knowledge for ill usage.
|
|
|
|
|
but i will create an algorithm which will solve this problem so remember my user name(s)
|
|
|
|
|
but i will create an algorithm which will solve this problem so remember my user name(s)
|
|
|
|
|
The html content was downloaded from host with security info, such as Credit card number, IP address, user password etc.
I need to display the memory html file directly on a dialog without saving it as temp file for launching by IE or MS-Web-Browser because of security reason (delete file doesn't work always and is dangrous).
Do you know how to do this?
Thanks.
|
|
|
|
|
|
As I posted before, I thought I succeed to change my pointer shapes as I wanted (please see the codes & remember to add in stdAfx.h the #define OEMRESOURCE:
UpdateData(true);
if(m_Type == "ARROW")
SetSystemCursor(LoadCursor(NULL, IDC_ARROW), OCR_NORMAL);
else if(m_Type == "ALLSIZE")
SetSystemCursor(LoadCursor(NULL, IDC_SIZEALL), OCR_NORMAL);
else if(m_Type == "UPDOWN")
SetSystemCursor(LoadCursor(NULL, IDC_SIZENS), OCR_NORMAL);
else if(m_Type == "UP")
SetSystemCursor(LoadCursor(NULL, IDC_UPARROW), OCR_NORMAL);
UpdateData(false);
- The first time all working as I wanted, but after that they are mixed-up (rarely the right one, most of a time showing 1 of 3 other shapes instead)
Can someone show me the correctiuon, thanks in-advanced
|
|
|
|