Click here to Skip to main content
15,906,766 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: waveOutGetDevCaps Pin
mivey417-Aug-04 7:38
mivey417-Aug-04 7:38 
GeneralRe: waveOutGetDevCaps Pin
Dave Kreskowiak17-Aug-04 10:22
mveDave Kreskowiak17-Aug-04 10:22 
GeneralRe: waveOutGetDevCaps Pin
mivey418-Aug-04 5:52
mivey418-Aug-04 5:52 
GeneralRe: waveOutGetDevCaps Pin
Dave Kreskowiak18-Aug-04 6:27
mveDave Kreskowiak18-Aug-04 6:27 
GeneralRe: waveOutGetDevCaps Pin
Dave Kreskowiak18-Aug-04 12:21
mveDave Kreskowiak18-Aug-04 12:21 
GeneralRe: waveOutGetDevCaps Pin
Anonymous17-Aug-04 6:34
Anonymous17-Aug-04 6:34 
GeneralRe: waveOutGetDevCaps Pin
Anonymous17-Aug-04 6:53
Anonymous17-Aug-04 6:53 
GeneralRe: waveOutGetDevCaps Pin
mivey417-Aug-04 9:11
mivey417-Aug-04 9:11 
Okay! That nipped the problem in the bud.

Now for enlightenment for the initial issue. The additional lines of code that obviously made all the difference between success and failure were:

a. Imports System.Runtime.InteropServices
b. StructLayout(LayoutKind.Sequential, CharSet:=CharSet.Auto)
c. MarshalAs(UnmanagedType.ByValTStr, SizeConst:=MAXPNAMELEN)

Why must these additional parameters be set in order for the API function to properly work but there isn't any direct or immediately obvious documentation for it? I have used other API structures and passed them receiving the expected results without addition of these parameters. Are there any resources available for VB.NET programmers that provide a good sound source of information for implementing API calls?

My apologies for the oversight of an additional member of the WAVEOUTCAPS structure that was mentioned earlier to me.
----> Public wReserved1 As Short

I use an API Generator utility to generate the Declarations and constants and apparently this additional member wasn't added until after the release of the utility. But I do realize the importance of providing the API calls with everything they expect or there will be problems.

Thanks Big Grin | :-D

"For God so loved the world...." John 3:16
I only have one boss, J.C.
GeneralRe: waveOutGetDevCaps Pin
Anonymous17-Aug-04 9:34
Anonymous17-Aug-04 9:34 
GeneralRe: waveOutGetDevCaps Pin
Anonymous17-Aug-04 9:59
Anonymous17-Aug-04 9:59 
GeneralRe: waveOutGetDevCaps Pin
Anonymous17-Aug-04 10:24
Anonymous17-Aug-04 10:24 
GeneralRe: waveOutGetDevCaps Pin
mivey418-Aug-04 6:25
mivey418-Aug-04 6:25 
GeneralNeed to switch between Applications Pin
awhucks17-Aug-04 4:49
awhucks17-Aug-04 4:49 
GeneralRe: Need to switch between Applications Pin
Pablo.ar17-Aug-04 6:48
Pablo.ar17-Aug-04 6:48 
GeneralRe: Need to switch between Applications Pin
awhucks17-Aug-04 7:36
awhucks17-Aug-04 7:36 
GeneralRe: Need to switch between Applications Pin
awhucks17-Aug-04 7:51
awhucks17-Aug-04 7:51 
GeneralRe: Need to switch between Applications Pin
Pablo.ar17-Aug-04 16:16
Pablo.ar17-Aug-04 16:16 
Generaltransactions causing exceptions Pin
kowplunk17-Aug-04 4:45
kowplunk17-Aug-04 4:45 
GeneralRe: transactions causing exceptions Pin
Dave Kreskowiak17-Aug-04 5:29
mveDave Kreskowiak17-Aug-04 5:29 
GeneralRe: transactions causing exceptions Pin
kowplunk17-Aug-04 10:23
kowplunk17-Aug-04 10:23 
Questionreload datagrid? Pin
Lisana17-Aug-04 4:40
Lisana17-Aug-04 4:40 
Questionrecieving data in a network stream?? Pin
ineedhelp17-Aug-04 0:04
ineedhelp17-Aug-04 0:04 
AnswerRe: recieving data in a network stream?? Pin
Dave Kreskowiak17-Aug-04 4:16
mveDave Kreskowiak17-Aug-04 4:16 
QuestionSlow retrieval of records??? Pin
pry50416-Aug-04 22:07
pry50416-Aug-04 22:07 
GeneralConvert Hex to Decimal Pin
sumiko16-Aug-04 22:02
sumiko16-Aug-04 22:02 

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.