using System; using System.Text; using System.Collections.Generic; using System.Windows.Forms; using ScriptPortal.Vegas; public class EntryPoint { public void FromVegas(Vegas vegas) { foreach (Track track in vegas.Project.Tracks) { // only the selected tracks if (!track.Selected) continue; foreach (TrackEvent trackEvent in track.Events) { //This method works - but it does not show special characters string MiniActiveTakeName = trackEvent.ActiveTake.Name.Substring(20); //This method don't work !! // PlugInNode node = vegas.Generators; // Media media = media.Generator.OFXEffect; // OFXStringParameter txtparam = (OFXStringParameter) ofxEffect.FindParameterByName("Text"); // string MiniActiveTakeName = txtparam.Value; Region region = new Region(trackEvent.Start, trackEvent.Length, MiniActiveTakeName); try { vegas.Project.Regions.Add(region); } catch (Exception e) { MessageBox.Show(String.Format("Couldn't place Region at {0}\nThe error message: {1}", trackEvent.Start.ToString(), e.Message)); } } } } }
Hi, can anyone help me figure out a method to get text from a text media event and put it in region. With ActiveTake it does not show special character like " ș ț ". In other words the name of the region is "ăîâ??./" and it should be "ăîâșț./".