• Welcome to Valhalla Legends Archive.
 

[Pascal] CreateWindow Missing Parameters?

Started by Yegg, December 12, 2005, 02:53 PM

Previous topic - Next topic

Yegg

I'm having an issue with the Windows CreateWindow() function. I'm using Pascal and here is my code:

   hRichEdit := CreateWindow ('richedit_class',
      nil,
      WS_VISIBLE or WS_CHILD or WS_VSCROLL or ES_MULTILINE,
      0, 0,
      200, 150,
      lhWindow, 0, system.MainInstance, nil);


All of the values in this block of code are of the correct type that they should be in. However, my compiler (FreePascal 2.0.2) is tells me the following:

Wrong number of parameters specified!

It directs this statement to the above code. However, I have absolutely no idea what could possibly be wrong. Any ideas?

Edit: I think I know what's wrong. I just remembered that I overloaded this function when I should not have, this is probably what has affected the code. I'll check right now and update my post again with the results.

Edit2: This was the issue. Problem solved.