473,657 Members | 2,426 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

treeview text highlighted after a video clicked

2. Header << Play Video (a) [Duration 0:00 to 0:030] and (b) [Duration 0:30 to 0:41] on click

a) sub header 1 << Play Video (a) only on click
b) sub header 2 << Play Video (b) only on click

When I click 2. Header it was default highlighted blue background with white foreground.
So 2. Header is playing videos on (a) and (b) after I click on 2. Header. There will be a slider to detect the duration.
So now, I want a) sub header 1 to be highlighted when the slider is at part A video [2. Header is still showing video (a)]
Same for b) sub header 2 to be highlighted when slider is at part B video.[ 2. Header is still showing video (b)]



And I did this code...

Expand|Select|Wrap|Line Numbers
  1. private void SeekToMediaPosition(object sender, RoutedPropertyChangedEventArgs<double> args)
  2.   {
  3.    _timer.Stop();
  4.    TimeSpan t = TimeSpan.FromSeconds(VideoTime.Value);
  5.    Video.Position = t;
  6.    _timer.Start();
  7.  
  8.    if (t.TotalSeconds < 30)
  9.                 {
  10.                     twoA.IsSelected = true;
  11.                 }
  12.                 else if( t.TotalSeconds <41)
  13.                 {
  14.                     twoB.IsSelected = true;
  15.                 }
  16.  
  17.       else
  18.     {
  19.      threeB.IsSelected = true;
  20.     }
  21.    }
  22.   }
  23. And I didn't get what I wanted because, at only the
  24.  
  25. if (two.IsSelected == true)
  26.             {
  27.                 if (t.TotalSeconds < 30)
  28.                 {
  29.                     twoA.IsSelected = true;
  30.                 }
  31.                 else
  32.                 {
  33.                     twoB.IsSelected = true;
  34.                 }
  35.             }
i already dun see the isSelected function to go to twoB after 30sec later... Any clue? ):
--------------------------------------------------------------------------------
Nov 15 '10 #1
0 1036

Sign in to post your reply or Sign up for a free account.

Similar topics

2
1821
by: Julian Jordan | last post by:
Hi I'm trying to write a system in which you can highlight some text in a form box, click a button (or press a key combination) and the text highlighted gets surrounded by a given html tag. The following works fine in IE on a PC: txt = document.selection.createRange().text;
2
5981
by: Derrick | last post by:
I have a windows form, many combo boxes, i create items and add to the items collection in code. When viewing form, many combos have their text selected, highlighted. Is there a preferred way to pre-select the first item in a combo without highlighting text all the time? I am using Combo.SelectedIndex = 0; after populating the items collection. Thanks in advance! Derrick
2
1444
by: Bernie Yaeger | last post by:
I have an mdi app that has a main menu on the parent form. I would like to use a treeview in place of one of the menu options, so that instead of a menu option - say, 'reports' - it would have 'reports' but the second level would not be menu items for each report but rather a treeview control which, when clicked, would produce the appropriate report. Essentially, then, what I want to do is use a treeview where a sub menu list ordinarily...
1
3468
by: namanhvu | last post by:
Hi everyone, I'm trying to create a form where the radio button is automatically selected when the input text field beside it is clicked. I know I need to use "onClick" somewhere but I don't know how. With links I found it it would work like this: <SCRIPT LANGUAGE="JavaScript"> function click(which) {
0
1285
by: gav1972 | last post by:
Working on this piece of code but when i click on my add button in the form the text boxes that i am using do not clear and so i can't add a new record any help would be great. The code for my data tier and app is below thanks. Data tier Public Class VideoData Public Function getMovies(ByVal strName As String) As DataSet Select Case strName Case "Video" daMovies.Fill(Ds1)
4
3711
by: Milkstr | last post by:
Hi I have a asp page that shows usernames in a reapeating region so it lists all the users of my site, i want to be able to click on the user and the page then to bring up their details that or store in a database. so once the list is clicked it displays the relivent info, the click page been the same for all users but just change the filter. So how do i pass information from one page to another when a hyperlink is clicked?????
3
1635
by: rbunn83815 | last post by:
Hello Everyone! I saw a few discussions on saving highlighted text in a text box. I am interested in saving text highlighted anywhere on a web page and to save that text as a string in C#. I know C# fairly well, but I'm a newbie with JavaScript and ASP.NET. If anyone knows a simple elegant way to do this I would really appreciate it, but I'll take any solution at this point. Even if you can point me in the right directions that would...
2
2247
by: Manikandan | last post by:
Hi, I'm using .NET1.1. I have a windows form with two controls 1.Treeview 2.Checkbox I added the items into tree view, the user selects the item in treeview. When i click the item in treeview it get selected(highlighted in blue color) .
4
2990
by: Xenomorph | last post by:
I have a program where you click an item on the TreeView on the left, and then work with whatever pops up on the right. There are many entries on the TreeView, and when you click something on the right, the item on the TreeView is no longer highlighted, making it hard to keep track of which item you clicked on the TreeView. I want the item clicked on in the TreeView to turn BOLD, or get underlined, or change color or something. Just so...
1
3218
by: jonc1 | last post by:
I am attempting to write some simple video playback code. This is easy I am using Microsoft.DirectX.AudioVideoPlayback which works fine. I want to overlay some text on the video. To do this I need the famed transparent control that everyone sems to struggle with. I have overiden createparams and now have a transparent textbox/rich text box. If I place this over a picture it works fine, but over a video the text disapears. Could...
0
8315
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8829
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
8508
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8608
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7341
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6172
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4323
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
1962
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1627
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.