Xtreme Visual Basic Talk

Xtreme Visual Basic Talk (http://www.xtremevbtalk.com/)
-   .NET File I/O and Registry (http://www.xtremevbtalk.com/-net-file-i-o-and-registry/)
-   -   Markercount problems (http://www.xtremevbtalk.com/-net-file-i-o-and-registry/200469-markercount.html)

jpdiazg 12-02-2004 12:21 PM

Markercount problems
Hi everybody,

I have this problem and I'm very confuse :confused:

I'm trying (with a WMP object called Player) to know how many Markers has a WMV file. I have the following code but always returns 0 :(
There is something that I am forgetting to do?
Thanks a lot

Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Player.URL = "C:\a.wmv"
Dim a As Integer
a = Player.currentMedia.markerCount
End Sub

MKoslof 12-02-2004 04:44 PM

The file has to be open before you can retrieve marker count. Look into the OpenStateChange event and the MediaOpen event

Circe 03-30-2015 02:56 PM

Yes.... I know it`s a bit late to write about this. But... Have you got a very tiny example to solve this question ? It would be helpfull to me !

Thanks a lot !

Gruff 03-30-2015 04:06 PM


Yes it is way too late to dig up this old post.
Never dig them up.

I seriously doubt if jpdiazg or MKoslof are active on this form anymore so your talking to the wind.

The forum policy is to start a new post and create a link to the old post.
You will be much more likely to get help.

Cerian Knight 03-31-2015 03:00 PM

I don't have markers to test against, but in the openstatechange event check if e.newState = 13 'wmposMediaOpen before reading markerCount.

All times are GMT -6. The time now is 10:36 AM.

Powered by vBulletin® Version 3.8.9
Copyright ©2000 - 2018, vBulletin Solutions, Inc.
Search Engine Optimisation provided by DragonByte SEO v2.0.15 (Lite) - vBulletin Mods & Addons Copyright © 2018 DragonByte Technologies Ltd.
All site content is protected by the Digital Millenium Act of 1998. Copyright©2001-2011 MAS Media Inc. and Extreme Visual Basic Forum. All rights reserved.
You may not copy or reproduce any portion of this site without written consent.