Click here to Skip to main content
15,914,905 members
Home / Discussions / C#
   

C#

 
GeneralRe: Reading an Xml file into a jagged array need help Pin
OnlyTaz9-May-05 18:58
OnlyTaz9-May-05 18:58 
GeneralRe: Reading an Xml file into a jagged array need help Pin
Christian Graus10-May-05 12:42
protectorChristian Graus10-May-05 12:42 
GeneralAddress Filter Pin
Duong Tien Nam9-May-05 14:23
Duong Tien Nam9-May-05 14:23 
GeneralRe: Address Filter Pin
leppie9-May-05 14:34
leppie9-May-05 14:34 
GeneralRe: Address Filter Pin
Dave Kreskowiak9-May-05 17:09
mveDave Kreskowiak9-May-05 17:09 
GeneralHelp - PlaySound only plays default sound in C# Pin
Magela9-May-05 13:15
Magela9-May-05 13:15 
GeneralRe: Help - PlaySound only plays default sound in C# Pin
Christian Graus9-May-05 15:27
protectorChristian Graus9-May-05 15:27 
GeneralRe: Help - PlaySound only plays default sound in C# Pin
Heath Stewart9-May-05 21:34
protectorHeath Stewart9-May-05 21:34 
Your problem is that the second parameter should be declared as an IntPtr, which is a 32-bit integer in 32-bit Windows and a 64-bit integer under 64-bit Windows (not under the WOW64 subsystem). This is the size of a pointer, which an HMODULE (in the native declaration) is.

A long (System.Int64) is always 64 bits. So, unless this only runs on 64-bit Windows as a 64-bit application (support for which starts in .NET 2.0 when compiled with the right flags) your parameters are pushed onto the stack (or into registers, since .NET uses FastCall by default) incorrectly. The third parameter would always be zero because the low-order bits would not be read by the callee (PlaySound).

This posting is provided "AS IS" with no warranties, and confers no rights.

Software Design Engineer
Developer Division Customer Product-lifecycle Experience
Microsoft

[My Articles] [My Blog]
GeneralSelectable SubItem in a Listview Pin
Anonymous9-May-05 12:06
Anonymous9-May-05 12:06 
GeneralRe: Selectable SubItem in a Listview Pin
MoustafaS9-May-05 12:35
MoustafaS9-May-05 12:35 
GeneralRe: Selectable SubItem in a Listview Pin
rudy.net9-May-05 18:15
rudy.net9-May-05 18:15 
GeneralRe: Selectable SubItem in a Listview Pin
mav.northwind9-May-05 19:57
mav.northwind9-May-05 19:57 
GeneralRe: Selectable SubItem in a Listview Pin
Anonymous10-May-05 4:47
Anonymous10-May-05 4:47 
GeneralSelection colors in an extended RichTextBox Pin
methodincharge9-May-05 11:35
methodincharge9-May-05 11:35 
GeneralRe: Selection colors in an extended RichTextBox Pin
leppie9-May-05 14:40
leppie9-May-05 14:40 
GeneralAutomate Microsoft Access Pin
sinnen9-May-05 10:36
sinnen9-May-05 10:36 
GeneralMarshalling structs with two different char sets Pin
Anonymous9-May-05 9:13
Anonymous9-May-05 9:13 
GeneralDetecting a FileDrop event on an external program Pin
TofuBug249-May-05 7:40
TofuBug249-May-05 7:40 
GeneralRe: Detecting a FileDrop event on an external program Pin
Christian Graus9-May-05 12:31
protectorChristian Graus9-May-05 12:31 
GeneralPassing command line options to msi installer created as .NET deployment project Pin
StormShearon9-May-05 7:00
StormShearon9-May-05 7:00 
GeneralRe: Passing command line options to msi installer created as .NET deployment project Pin
mav.northwind9-May-05 20:01
mav.northwind9-May-05 20:01 
GeneralRe: Passing command line options to msi installer created as .NET deployment project Pin
StormShearon10-May-05 5:09
StormShearon10-May-05 5:09 
GeneralRe: Passing command line options to msi installer created as .NET deployment project Pin
mav.northwind10-May-05 20:14
mav.northwind10-May-05 20:14 
GeneralRe: Passing command line options to msi installer created as .NET deployment project Pin
StormShearon12-May-05 4:56
StormShearon12-May-05 4:56 
GeneralRe: Passing command line options to msi installer created as .NET deployment project Pin
StormShearon12-May-05 4:56
StormShearon12-May-05 4:56 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.