|
OK, have just been reading a couple of articles that refer to the Platfrom SDK and that I can get it with MSDN, purchase it from Microsoft on CD or download it from here.
The first two are out while the third kept giving me error messages about not having the correct authorty to access it.
So I did a quick search on Google and was taken to the Platform SDK download page. As I was working from home today and there is no way in hell I would download the SDK over a dial-up line I took control of a server in the office and proceeded to download the ~840KB executable.
I assumed that I was to then run it, tell if I wanted typical/custom/what ever install and download the relevant (read all) bits like I can with the Internet Explorer download. Problem is it gives me an error message about not being a valid msi file.
Is it possible to get my hands on the SDK without having to resort to buying it (yes I'm a shameless cheapskate)? And if so how?
Michael Martin
Pegasystems Pty Ltd
Australia
martm@pegasystems.com
+61 413-004-018
|
|
|
|
|
|
Markuk
I am running Windows 2000 on my laptop and on the Server I attempted to perform the download from. According to the instructions I do not require the Microsoft Installer update. I thought the problem might have been that the server did not have Visual Studio installed and that the SDK only installs from the web and does not download the installation files.
It also could have been a corrupt downloaded file, which I will test when I get in to the office tomorrow.
Michael Martin
Pegasystems Pty Ltd
Australia
martm@pegasystems.com
+61 413-004-018
|
|
|
|
|
ftp.microsoft.com is down at the moment. The Platform SDK is FTP-able, the path is something like /developer/platformsdk - it's obvious once you see it. However, you should use a dedicated FTP client to get it (I use LeechFTP), since IE is woefully inadequate for mass FTP downloading.
--Mike--
http://home.inreach.com/mdunn/
#include "buffy_sig"
|
|
|
|
|
Mike
that two for two. Tried ftp.microsoft.com earlier but only used IE, I have LeechFTP but for some strange reason didn't fire it off. Also tried /developer/platformsdk and /developer/platformsdk/feb2001 but couldn't get anything to work.
Will wait till I'm in the office tommorow and give it ago with LecchFTP. I assume Anonymous login is OK.
Michael Martin
Pegasystems Pty Ltd
Australia
martm@pegasystems.com
+61 413-004-018
|
|
|
|
|
Hi,
What is performance this code ? What doing ?
void DoEvents()
{
MSG msg;
while(::PeekMessage(&msg, NULL, 0, 0, PM_NOREMOVE))
{
if(!AfxGetThread()->PumpMessage()) return;
}
}
My month article: Game programming by DirectX by Lan Mader.
Please visit in: www.geocities.com/hadi_rezaie/index.html
Hadi Rezaie
|
|
|
|
|
I think what it is doing is translating and dispatching all the messages that are in the current thread's message queue -- if there are any. I've seen something similar before; I think it was a trick used to update a dialog box's controls during a supper lengthy operation.
Sort of like this;
...
for ( int i = 0; i < 10000000000000000; ++i ) {
wndListBox.AddString ( arrayOfWayToManyStrings[i] );
DoEvents ();
}
...
I'm not really sure if this is good practice or not... but if you find that your using it frequently, you might consider doing the UI processing in a separate thread.
Someone correct me if I'm wrong.
-Ben
---------
On the topic of code with no error handling -- It's not poor coding, it's "optimistic"
|
|
|
|
|
Thank you very much ...
I'm very very beginner in Thread programming, i mean i'm very beginner in using functions that work by Messages, if possible please write FULL for me about SendMessage and GetMessage and DispatchMessage and PostMessage and ... and explain about Thread, what mean Thread ? how can i use of it ?
Thanks again.
My month article: Game programming by DirectX by Lan Mader.
Please visit in: www.geocities.com/hadi_rezaie/index.html
Hadi Rezaie
|
|
|
|
|
Hey,
Hey,
I don’t think I can tell you any more than what MSDN would.
SendMessage - Sends a message to a specified window, and does not return until the window processes it.
PostMessage - places a message in the specified window's message queue, and returns immediately.
GetMessage - looks at the thread's message queue and waits till a posted message appears, all the while dispatching any incoming messages.
DispatchMessage - Dispatches a message to a window procedure, letting it take the appropriate action. All the message handlers you add to your application get called because of this function.
As for threads you’d be better of looking through MSDN or better yet a beginner book on the subject. The book that helped me out the most was ‘Beginning Windows NT Programming’ – by Julian Templeman… it has a great section on threads and processes.
-Ben
---------
On the topic of code with no error handling -- It's not poor coding, it's "optimistic"
|
|
|
|
|
Hi Ben,
Thanks alot for your helps,
I got very notices from your reply.
If i'll find any other question i ask you ...
My month article: Game programming by DirectX by Lan Mader.
Please visit in: www.geocities.com/hadi_rezaie/index.html
Hadi Rezaie
|
|
|
|
|
Hi Mr.Ben,
Thanks alooot for your reply ...
You said DispatchMessage, dispatch message to a window procedure, i want to know does SendMessage and PostMessage don't dispatch message to a window precedure ?!!!
So, where does SendMessage or PostMessage, dispatch messages ?
And in last, what is different between PostMessage and PeekMessage ???
Thanks again ...
Best Regards
My month article: Game programming by DirectX by Lan Mader.
Please visit in: www.geocities.com/hadi_rezaie/index.html
Hadi Rezaie
|
|
|
|
|
SendMessage and PostMessage don't dispatch messages, they insert messages into a message queue. The thread that receives the message is responsible for dispatching the message. PeekMessage checks if there are any incoming messages in the queue and always returns immediately, unlike GetMessage which blocks until a message is received.
|
|
|
|
|
Thanks alooot, you really solved my problem ...
My month article: Game programming by DirectX by Lan Mader.
Please visit in: www.geocities.com/hadi_rezaie/index.html
Hadi Rezaie
|
|
|
|
|
Basically, that code permits that the system process another messages.
In other words, that permits that the system attends to other systems.
It causes that it lowers the resources of the CPU consumed by the Application. I use constantly that code, in my NT services.
Cheers!!!
Carlos Antollini.
|
|
|
|
|
How can I create dynamic controls? eg: I want to create an edit box or radio button based on what user input. If user want one edit box so I have to create one edit box. If two edit box, the application should have two edit boxes. Anyone know how to do it?
Thanks in advance.
FMansor
|
|
|
|
|
I need to implement a system which times video spots for playout. For example, each spot will have a specified duration in a list of spots. Each spot should start after the previous one has finished.
I will worry about access time considerations, but I was wondering what the accuracy of a waitable timer or wait function is ( ie, would you trust it to do a real job for you? ).
Also, is it poor form to simply use WaitForSingleObject as follows ? :
CreateEvent( .........)
SetEvent( hEvent ) // Create a dummy event
for( i=spotListLength-1; i>=0; i-- ) {
Play( spot[i] ) // start playing spot[i] in its own thread somewhere else
WaitForSingleObject( hEvent, spot[i].duration ); // wait for timeout
}
// The loop is just for the sake of this question - Not used as is
Thank you,
Brad
|
|
|
|
|
Wait infinitly in the WaitForSingleObject() until WaitForSingleObject() != STILL_ACTIVE.
Put the WaitForSingleObject() into a loop, for ask about the value that it returns.
When the thread finished you will know that the sopt is finish.
Cheers!!!!
Carlos Antollini.
|
|
|
|
|
Good point and thank you. However with past experience using events as above, the time from initiating the signal to the time the WaitFor.. acknowledges it is often indeterminant - it may or may not happen on time.
I guess I should have explained further that I am actually triggering a video server remotely and I don't want to wait for serial handshaking, etc. My question lead us to believe that I was running viz locally. Sorry
What I want to do timing-wise is to ever so slightly cut off the end of the previous clip and force a guaranteed start time for each - not really dependant on exactly when the previous one ends. My stipulation is that the entire block of spots takes up exactly X amount of time (+ or - some ?). This is why I need to get an accurate timing scheduler.
Thank you,
Brad
|
|
|
|
|
Basically, you can only trust that the timer will not be signalled before the specified time. Windows isn't a real-time OS, so don't expect it to work like one. However, the multimedia timers are supposed to give better accuracy than regular timer messages or WaitForSingleObject timeouts. See the documentaion for timeSetEvent(), TimeProc(), timeKillEvent() in the Graphics and Multimedia services of the Platform SDK docs.
|
|
|
|
|
I'm trying to write a program which captures the scrollable portion of a window (Wordpad, Paint, IE, etc) and save it as one big bitmap. Actually making a window scroll down line by line isn't a problem but the difficulty I've been having is getting the scrollinfo from the window of concern. Applications seem to simply ignore the message SBM_GETSCROLLINFO and the API GetScrollInfo(...) plain doesn't work. So, unless I can get the scrollinfo, I never know how many times to scroll the window down and I also don't know how much of the window was scrolled down ( my plan is to scroll the window, make the image capture, append to "finished" image, and repeat to finished. If anybody can figure this one out I can pad your wallet with some cash.
|
|
|
|
|
While I was debugging a new version of SAWZip I create some files with invalid filenames. The filename was pointing to an invalid memory block. The name of the file looks like this &çàçàééjkl. I tried to delete them with Explorer and with the command-box but they both say I'm trying to delete an invalid file. I also tried to delete the entire directory. But that doens't work either.
How can I get rid of them?
|
|
|
|
|
did you try:
DeleteFile(pFilename);
?
------------------------------
Smaller Animals Software, Inc.
http://www.smalleranimals.com
|
|
|
|
|
The problem is that it's not possible to know what the name of the file is. Maybe I've to try findfirst, findnext, ... There are some files with only spaces in the name and I can't delete them either.
|
|
|
|
|
Odd that the OS let you create such a file in the first place. I'd try running ScanDisk, Norton Disk Doctor, or whatever disk repair tool you have. Those should find the invalid filename and correct it.
--Mike--
http://home.inreach.com/mdunn/
#include "buffy_sig"
|
|
|
|
|
Yes it's weird that the OS allows creating files with invalid names. I used the CreateDirectory and CreateFile api. It's even possible to create a file with a name that only contains spaces. I'll try to run scandisk this evening and I hope I get rid of these stupid files.
|
|
|
|