|
Hello,
Is there a way to hide applicaiton menu at runtime? I would like to hide the menu once everything is loaded and once the application starts running. The application is written in vc++ 6.0 and the window is created using CreateWindowEx, I tried different dlg_styles options to hide it, but it still shows the menu.
Any suggestions??
thanks,
PKNT
|
|
|
|
|
create window with one menu and use ShowWindow function for hide the window.
Thanks and Regards,
Selvam,
http://www.wincpp.com
|
|
|
|
|
I would like to hide the menu only not the whole application window(thats easy as you said using showwindow function).
thanks though
PKNT
|
|
|
|
|
I don't find any direct function support from windows programming. We may use MENUINFO Structure for change style( ex, MNS_AUTODISMISS, mask MIM_BACKGROUND).
Thanks and Regards,
Selvam,
http://www.wincpp.com
modified on Thursday, September 10, 2009 1:31 AM
|
|
|
|
|
> I don't find any direct function support from windows programming
?????
1 line of code, first page of MSDN Win32 menu api list !!!
|
|
|
|
|
I've seen $3 bills that had more value than your response.
"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
|
|
|
|
|
Is there any Microsoft SDK or any other library or source code
to help with downloading MMS stream
Thanx for help
viliam
|
|
|
|
|
|
Hi,
I wrote a program using VC++ that should scan for available wireless networks in the area.
In my SW I use the commands OID_802_11_BSSID_LIST_SCAN and OID_802_11_BSSID_LIST.
My questions are:
1. How can I Force the Wireless NIC to do ACTIVE SCAN ?
2. According to tests that I did, the card does not flush the list between scans, i.e. I get for several scan a results of an AP that was on air during an old scan, but is no longer there and new scans return's it's data as if it is still there.
I am using Intel PRO 2200BG Wireless NIC, with driver version 8.1.0.28 (dated 24/8/2004).
Relevant information That I used is here:
Some relevant info from the above link:
---------------------------------------
"
The device must do the following when performing an explicit scan in response to a setting of OID_802_11_BSSID_LIST_SCAN:
* The device must flush the current contents of its cached BSSID scan list before initiating the explicit scan request.
* The device must scan both infrastructure and ad hoc networks, regardless of the current setting of its network mode.
* The device can use either the active or passive scanning methods, or a combination of both scanning methods.
Note Active scanning is preferred whenever appropriate.
* When performing an active scan, the device sets the BSSID to the broadcast MAC address in the 802.11 probe request that it sends. The device also sets the SSID to the zero-length broadcast SSID in the probe request.
* The device must perform the scan across all the frequency channels and bands that it supports.
* The miniport driver must minimize its response time for this OID. It is recommended that the driver just initiate the scan and return NDIS_STATUS_SUCCESS in response to the setting of OID_802_11_BSSID_LIST_SCAN. The driver must not return NDIS_STATUS_PENDING or wait for the scan to complete before returning NDIS_STATUS_SUCCESS.
"
-------
Any help will be appreciated.
-- Amit.
|
|
|
|
|
|
NDIS_802_11_BSSID_LIST* m_pBSSIDList;
m_pBSSIDList = (NDIS_802_11_BSSID_LIST *) VirtualAlloc (NULL,
sizeof (NDIS_802_11_BSSID_LIST) * NUMBEROF_BSSIDS,
MEM_RESERVE | MEM_COMMIT,
PAGE_READWRITE) ;
memset (m_pBSSIDList, 0, sizeof (NDIS_802_11_BSSID_LIST) * NUMBEROF_BSSIDS);
oidcode = OID_802_11_BSSID_LIST_SCAN;
DeviceIoControl (m_handle,
IOCTL_NDIS_QUERY_GLOBAL_STATS,
&oidcode,
sizeof(oidcode),
(ULONG *) NULL,
0,
&bytesreturned,
NULL);
Sleep (6100);
memset (m_pBSSIDList, 0, sizeof (NDIS_802_11_BSSID_LIST) * NUMBEROF_BSSIDS);
oidcode = OID_802_11_BSSID_LIST;
if (DeviceIoControl( m_handle,
IOCTL_NDIS_QUERY_GLOBAL_STATS,
&oidcode,
sizeof( oidcode),
( ULONG *) m_pBSSIDList,
sizeof( NDIS_802_11_BSSID_LIST) * NUMBEROF_BSSIDS,
&bytesreturned,
NULL) == 0)
{
return NULL;
}
else
{
return m_pBSSIDList;
}
|
|
|
|
|
i have a CString :"121 232 3232"
i want to cut it into 3 pieces : "121" ; "232"; "3232"
and convert them to "int". can you help me? Thanks!
|
|
|
|
|
CStringT::Tokenize is the method for you, have a look at the nice example in the documentation [^].
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]
|
|
|
|
|
You could use sscanf , or strtok or std::istringstream (or somthing like that, I always forget which one it is).
Me think the easier, but less safe and probably not well accepted today is sscanf :
int iRet = sscanf(input, "%i %i %i", &val1, &val2, &val3);
or maybe
std::istringstream buffer(input);
int val1, val2, val3;
buffer >> val1 >> val2 >> val3;
and in general, to convert a string to a int, we can use atoi ( or atol )
This signature was proudly tested on animals.
|
|
|
|
|
tucn87 wrote: i want to cut it into 3 pieces : "121" ; "232"; "3232"
Carlo has answered this part...
tucn87 wrote: and convert them to "int". can you help me? Thanks!
Take a look at _ttoi[^]
It is a crappy thing, but it's life -^ Carlo Pallini
|
|
|
|
|
There's also AfxExtractSubString() .
"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
|
|
|
|
|
Base 10 conversion is so simple, just write your own quick parser to walk the string and convert each chunk at the same time.
|
|
|
|
|
hi vc++ programmers,,
i am getting the following errors in migrating my code from vs-2--3 to vs-2008...
FeeEnterView.obj : error LNK2019: unresolved external symbol "public: __thiscall ATL::CTime::CTime(void)"
and
fwstissr.obj : error LNK2001: unresolved external symbol ___security_cookie
can enbody show a remedy for this....thanks in advance
modified on Wednesday, September 9, 2009 11:04 AM
|
|
|
|
|
Hi,
I have couple of text files in JAR. I want to access them in my C++ application. Basically I want to get the FILE pointer to those file. Please let me know how would we do it.
thanks in advance
Umrahi...
If you have faith in the cause and
the means and in God, the hot
Sun will be cool for you.
|
|
|
|
|
See here for ideas.
"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
|
|
|
|
|
Why don't you use the jar tool to decompress the files?
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]
|
|
|
|
|
Judging from the header, they are simple ZIP files. Try one of the ZIP/UNZIP classes here on CP to access them.
|
|
|
|
|
I am creating a vs2005 vc++ application and trying to get a secondary thread setup and working. I have read through the various postings and tried to put some code together but it won't compile.
I am trying to start the new thread from a menu item via a message handler based in my application's 'CView' based class. I have created a new class of my own (GcWorkerThread) and is derived from CWinThread, and contains a member function 'GcThreadFunction'
calling code:
int x;
CWinThread *pThread = AfxBeginThread (GcThreadFunction, x);
UINT GcWorkerThread::GcThreadFunction (LPVOID pParam)
{
int t;
for (int y=0; y<1000000; y++
{
}
}
When is comes to compiling the code I get an error:
"Error C3867 'GcWorkerThread::GcThreadFunction' function call missing argument list
use &GcWorkerThread::GcThreadFunction to create a pointer to member"
What am I doing wrong?
|
|
|
|
|
You cannot pass a instance method to AfxBeginThread . You've to pass a standard function or a class (i.e. static ) method.
BTW: have a look at this [^].
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]
|
|
|
|
|
try with the following change.
int x;
CWinThread *pThread = AfxBeginThread (GcThreadFunction, &x);
Thanks and Regards,
Selvam,
http://www.wincpp.com
|
|
|
|