|
My goal is to prevent any navigation on any browser different than IE.
Hence, I'm trying to deny the use of port 80 to any programs different than Iexplorer.exe
Any advice or help would be greatly appreciated as I have some hard time finding samples covering that kind of functionnality.
PS: yes it is dracstic but that's the way it is lol
PSS: ThatsAlok you're a guru man!! I'm a fan
|
|
|
|
|
I want to set color of string and move that string in cosole but i don't know.Who know to help me.
Thank you.
|
|
|
|
|
Hello
We Believe in Excellence
|
|
|
|
|
Go to "The Soapbox".
Don't try it, just do it!
|
|
|
|
|
how do i sense ctrl+C in a dialog based application?
|
|
|
|
|
|
Sorry Heman!
RegisterHotKey function never register Hotkey for Ctrl+c as it is previously register by window for system wide Clipboard usage!
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
|
|
|
|
|
theerkanamai wrote:
how do i sense ctrl+C in a dialog based application?
If your just looking to handle the Ctrl-C key while your dialog is in focus, you can easily add an accelerator key.
In the resource view locate the Accelerator folder.
Double click to open it, right click and scroll down to “New Accelerator”
-------------------------------
|
|
|
|
|
I have a question on setting the application window size. I'm trying to do something non-standard. I want to increase the size of an application's window to be greater than the desktop size. I've tried to use the Cwnd class functions (SetWindowPos and MoveWindow), but none of them allow me to increase the size beyond the desktop's window size. I can increase any application's window size; just not bigger than the desktop. Is there a way around this? Can I use the graphics interface to get around this; or would it just create a stretched image with no real application functionality?
|
|
|
|
|
Anonymous wrote:
I've tried to use the Cwnd class functions (SetWindowPos and MoveWindow), but none of them allow me to increase the size beyond the desktop's window size
I have tried this too! and it works well for me!, Could you show your code snippet!
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
|
|
|
|
|
I get the application window's Cwnd handle. Then, I do something like this:
pWnd->GetWindowRect(&Rect);
pWnd->SetWindowPos(pWnd, 0, 0, Rect.right + size_inc, Rect.bottom +size_inc, SWP_NOZORDER | SWP_SHOWWINDOW);
It will increase the size of the app window. At a certain point size_inc does not matter.
|
|
|
|
|
try this
<br />
::SetWindowPos(this->m_hWnd,HWND_TOP,0,0,850,650,SWP_SHOWWINDOW);
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
|
|
|
|
|
hiho@ll
i'm searching a part of the file system for files to upload to a server
i'm using FindFirst and FindNext to search for the files
in my WINXP home directory i have a subfolder which i use to search through
the problem is, FindFirst and FindNext just find "." or ".."
if i set the path to another dir it just finds the first entry!
what's the problem?
anybody please post a simple example prog?
thx@ll
|
|
|
|
|
WIN32_FIND_DATA fd = { 0 };
HANDLE hFind = FindFirstFile( filespec, &fd );
if ( hFile != NULL )
{
do
{
}
while( FindNextFile( hFind, &fd ) );
CloseHandle( hFind );
} Note that filespec should contain wildcards (e.g. "C:\\Windows\\*") if you want multiple files to match.
Stability. What an interesting concept. -- Chris Maunder
|
|
|
|
|
You'll miss the last file and you won't properly read the first one with the above example.
WIN32_FIND_DATA fd = { 0 };
HANDLE hFind = FindFirstFile( filespec, &fd );
if ( hFile != NULL )
{
BOOL MoreFilesFollow;
do
{
MoreFilesFollow = FindNextFile( hFind, &fd );
}
while(MoreFilesFollow);
CloseHandle( hFind );
}
|
|
|
|
|
hmm
i tried the code from the msdn documentation
and a code (which looks like yours and the same from msdn) from a website
the website code works, msdn not, but all look very similar
thx@ll
|
|
|
|
|
Brad, I'm sorry, you're wrong. After FindFirstFile returns successfully, fd contains the attributes of the first file that matches the file specification. FindNextFile returns non-zero until it has returned all the files unless some other error occurs. You can find out why it returned FALSE by checking GetLastError . If no more files were found the last error code is ERROR_NO_MORE_FILES .
Your code will skip the first file and process the last file twice.
My code is derived from many working programs, which have been well tested and deployed in production.
My experience is that FindFirstFile appears to perform a capture operation - it actually finds all the matching files and stores them in an in-memory structure. FindNextFile then hands out the next entry in that structure until it runs out. The effect of this is that any files added to or deleted from the folder after FindFirstFile is called will not be found (or will be found, if deleted).
Stability. What an interesting concept. -- Chris Maunder
|
|
|
|
|
!@#$!@#$ CFileFind
They just can't make a class accurately reflect the underlying API can they?
|
|
|
|
|
I've been writing some code to write audio tracks to a CD using IMAPI. This works fine except Windows Media Player tries to determine the Album name and artist and gets it completely wrong.
Is there anyway of writing the artist / album / track info to the CD?
Where does Media Player store its cache of album info?
How is the album info stored on the CD and is there any utility that will extract the info?
|
|
|
|
|
The feature is called CD Text, but take care: it is not supported by older cd drives.
An alternative is CDDB, but I don't know exactly how it works. It does read some identification code from the cd and uses webservers to get the track list.
Don't try it, just do it!
|
|
|
|
|
the artist info and track info are not stored on the CD, and that's shame if you ask me.
the only thing that is stored, is a CD ID; once retrieved, your software must search the web for the artist and track info on sites like cddb.com ( or the free one but I can't remember the name ); I think those sites offers SDK to use their service.
Maximilien Lincourt
Your Head A Splode - Strong Bad
|
|
|
|
|
How do you set the CD ID? I can't see anything from IMAPI.
Is it a value in the cda file?
|
|
|
|
|
I took a quick look through the IMAPI docs but I didn't see anything about support for CD Text.
CDDB doesn't use any metadata on the CD. All that is is the client taking a hash of the number of tracks + their lengths, and doing a database lookup for CDs whose contents have the same hash.
--Mike--
Visual C++ MVP
LINKS~! Ericahist | 1ClickPicGrabber | CP SearchBar v2.0.2 | C++ Forum FAQ
Strange things are afoot at the U+004B U+20DD
|
|
|
|
|
Hi there,
I'm looking for a C++ or .NET class library to create a surface or 3D graph.
Thanks.
|
|
|
|
|
I think this will help u....
http://sharptoolbox.com/Categorybf83036c-33f4-429e-b6c3-bdca40021dd5.aspx
****************************************************************************
http://www.dotnet247.com/247reference/msgs/40/203674.aspx
keep smilling.....b'coz smile is the shortest distance between people....
|
|
|
|