logo

Live Production Software Forums


Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Options
Go to last post Go to first unread
knbPixels  
#1 Posted : Tuesday, August 20, 2024 11:32:35 PM(UTC)
knbPixels

Rank: Advanced Member

Groups: Registered
Joined: 2/7/2024(UTC)
Posts: 71
United States

Thanks: 7 times
Was thanked: 5 time(s) in 5 post(s)
Our show operates on eastern timezone, trying to incorporate a clock into the show and show it on air. It cannot rely on the local computer clock at all, because we have operators in other time zones as well, and we are trying to accomplish this without using different time offsets and therefore different show file versions.

Anyone know of a way to pull the time of day from perhaps a website, as a data feed into a title, or something like that? We don't need to display seconds, just the hour and minute.
doggy  
#2 Posted : Tuesday, August 20, 2024 11:48:59 PM(UTC)
doggy

Rank: Advanced Member

Groups: Registered
Joined: 12/27/2012(UTC)
Posts: 5,216
Belgium
Location: Belgium

Thanks: 291 times
Was thanked: 955 time(s) in 790 post(s)
Originally Posted by: knbPixels Go to Quoted Post
Our show operates on eastern timezone, trying to incorporate a clock into the show and show it on air. It cannot rely on the local computer clock at all, because we have operators in other time zones as well, and we are trying to accomplish this without using different time offsets and therefore different show file versions.

Anyone know of a way to pull the time of day from perhaps a website, as a data feed into a title, or something like that? We don't need to display seconds, just the hour and minute.


Maybe this might help (google help ;-) ) in a script to display ( sorry Retrieve) eastern time from any computer anywhere
Code:
Dim eastern As DateTime = TimeZoneInfo.ConvertTimeBySystemTimeZoneId(DateTime.UtcNow, "Eastern Standard Time")
knbPixels  
#3 Posted : Tuesday, August 20, 2024 11:55:07 PM(UTC)
knbPixels

Rank: Advanced Member

Groups: Registered
Joined: 2/7/2024(UTC)
Posts: 71
United States

Thanks: 7 times
Was thanked: 5 time(s) in 5 post(s)
Originally Posted by: doggy Go to Quoted Post
Originally Posted by: knbPixels Go to Quoted Post
Our show operates on eastern timezone, trying to incorporate a clock into the show and show it on air. It cannot rely on the local computer clock at all, because we have operators in other time zones as well, and we are trying to accomplish this without using different time offsets and therefore different show file versions.

Anyone know of a way to pull the time of day from perhaps a website, as a data feed into a title, or something like that? We don't need to display seconds, just the hour and minute.


Maybe this might help (google help ;-) ) in a script to display eastern time from any computer anywhere
Code:
Dim eastern As DateTime = TimeZoneInfo.ConvertTimeBySystemTimeZoneId(DateTime.UtcNow, "Eastern Standard Time")


I know nothing about scripting but I'll give it a shot, thanks!
doggy  
#4 Posted : Wednesday, August 21, 2024 12:03:56 AM(UTC)
doggy

Rank: Advanced Member

Groups: Registered
Joined: 12/27/2012(UTC)
Posts: 5,216
Belgium
Location: Belgium

Thanks: 291 times
Was thanked: 955 time(s) in 790 post(s)
Originally Posted by: knbPixels Go to Quoted Post
Originally Posted by: doggy Go to Quoted Post
Originally Posted by: knbPixels Go to Quoted Post
Our show operates on eastern timezone, trying to incorporate a clock into the show and show it on air. It cannot rely on the local computer clock at all, because we have operators in other time zones as well, and we are trying to accomplish this without using different time offsets and therefore different show file versions.

Anyone know of a way to pull the time of day from perhaps a website, as a data feed into a title, or something like that? We don't need to display seconds, just the hour and minute.


Maybe this might help (google help ;-) ) in a script to display eastern time from any computer anywhere
Code:
Dim eastern As DateTime = TimeZoneInfo.ConvertTimeBySystemTimeZoneId(DateTime.UtcNow, "Eastern Standard Time")


I know nothing about scripting but I'll give it a shot, thanks!


to actually get that time on an input you will have to use a title and put the data from the script in the title and layer it on the input

"Scripting for dummies" Post in the forum should help you along
doggy  
#5 Posted : Wednesday, August 21, 2024 12:16:15 AM(UTC)
doggy

Rank: Advanced Member

Groups: Registered
Joined: 12/27/2012(UTC)
Posts: 5,216
Belgium
Location: Belgium

Thanks: 291 times
Was thanked: 955 time(s) in 790 post(s)
Here you go

Code:

Do while True
  Dim eastern As DateTime = TimeZoneInfo.ConvertTimeBySystemTimeZoneId(DateTime.UtcNow, "Eastern Standard Time")
  API.Function("SetText",Input:="Text Middle Centre Left Right Sharp.gtzip",SelectedName:="Message.Text",Value:=eastern.ToString("HH:mm"))
  Sleep(250)
Loop

'where "Text Middle Centre Left Right Sharp.gtzip" is the name of a standard vMix title input 


Copy code into a script, save and run it
thanks 1 user thanked doggy for this useful post.
knbPixels on 8/21/2024(UTC)
knbPixels  
#6 Posted : Wednesday, August 21, 2024 12:17:31 AM(UTC)
knbPixels

Rank: Advanced Member

Groups: Registered
Joined: 2/7/2024(UTC)
Posts: 71
United States

Thanks: 7 times
Was thanked: 5 time(s) in 5 post(s)
Originally Posted by: doggy Go to Quoted Post
Here you go

Code:

Do while True
  Dim eastern As DateTime = TimeZoneInfo.ConvertTimeBySystemTimeZoneId(DateTime.UtcNow, "Eastern Standard Time")
  API.Function("SetText",Input:="Text Middle Centre Left Right Sharp.gtzip",SelectedName:="Message.Text",Value:=eastern.ToString("HH:mm"))
  Sleep(250)
Loop

'where "Text Middle Centre Left Right Sharp.gtzip" is the name of a standard vMix title input 


Copy code into a script, save and run it


Thanks I'll try that!
knbPixels  
#7 Posted : Wednesday, August 21, 2024 6:43:10 AM(UTC)
knbPixels

Rank: Advanced Member

Groups: Registered
Joined: 2/7/2024(UTC)
Posts: 71
United States

Thanks: 7 times
Was thanked: 5 time(s) in 5 post(s)
Originally Posted by: doggy Go to Quoted Post
Here you go

Code:

Do while True
  Dim eastern As DateTime = TimeZoneInfo.ConvertTimeBySystemTimeZoneId(DateTime.UtcNow, "Eastern Standard Time")
  API.Function("SetText",Input:="Text Middle Centre Left Right Sharp.gtzip",SelectedName:="Message.Text",Value:=eastern.ToString("HH:mm"))
  Sleep(250)
Loop

'where "Text Middle Centre Left Right Sharp.gtzip" is the name of a standard vMix title input 


Copy code into a script, save and run it


Made an input from a standard vMix title input, left it as it comes standard....then I added the script and ran it, but I get nothing happening in the input I created. I also made sure the input name matches that same name of the title I selected, and nothing happens.
doggy  
#8 Posted : Wednesday, August 21, 2024 6:50:03 AM(UTC)
doggy

Rank: Advanced Member

Groups: Registered
Joined: 12/27/2012(UTC)
Posts: 5,216
Belgium
Location: Belgium

Thanks: 291 times
Was thanked: 955 time(s) in 790 post(s)
Originally Posted by: knbPixels Go to Quoted Post


Made an input from a standard vMix title input, left it as it comes standard....then I added the script and ran it, but I get nothing happening in the input I created. I also made sure the input name matches that same name of the title I selected, and nothing happens.


You say a standard vMix title , not all titles contain a fieldname that is called "Message.Text" , maybe check that

or maybe a screenshot of the title editor and of the script
knbPixels  
#9 Posted : Wednesday, August 21, 2024 6:57:44 AM(UTC)
knbPixels

Rank: Advanced Member

Groups: Registered
Joined: 2/7/2024(UTC)
Posts: 71
United States

Thanks: 7 times
Was thanked: 5 time(s) in 5 post(s)
Originally Posted by: doggy Go to Quoted Post
Originally Posted by: knbPixels Go to Quoted Post


Made an input from a standard vMix title input, left it as it comes standard....then I added the script and ran it, but I get nothing happening in the input I created. I also made sure the input name matches that same name of the title I selected, and nothing happens.


You say a standard vMix title , not all titles contain a fieldname that is called "Message.Text" , maybe check that

or maybe a screenshot of the title editor and of the script



I actually just used the standard title that you chose as an example

image (14).png (33kb) downloaded 1 time(s). image (15).png (32kb) downloaded 0 time(s).
doggy  
#10 Posted : Wednesday, August 21, 2024 7:06:39 AM(UTC)
doggy

Rank: Advanced Member

Groups: Registered
Joined: 12/27/2012(UTC)
Posts: 5,216
Belgium
Location: Belgium

Thanks: 291 times
Was thanked: 955 time(s) in 790 post(s)
Originally Posted by: knbPixels Go to Quoted Post

I actually just used the standard title that you chose as an example


Strange as i can asure you that it works here

add: console.writeline(eastern) between the line Dim.. and API... and see what it says in the console when you run the script (= keeping the settings-script window open/ the black part )
knbPixels  
#11 Posted : Wednesday, August 21, 2024 7:08:28 AM(UTC)
knbPixels

Rank: Advanced Member

Groups: Registered
Joined: 2/7/2024(UTC)
Posts: 71
United States

Thanks: 7 times
Was thanked: 5 time(s) in 5 post(s)
Originally Posted by: doggy Go to Quoted Post
Originally Posted by: knbPixels Go to Quoted Post

I actually just used the standard title that you chose as an example


Strange as i can asure you that it works here

add: console.writeline(eastern) between the line Dim.. and API... and see what it says in the console when you run the script (= keeping the settings-script window open/ the black part )


The console returns the date and time in Eastern TZ
knbPixels  
#12 Posted : Wednesday, August 21, 2024 7:11:21 AM(UTC)
knbPixels

Rank: Advanced Member

Groups: Registered
Joined: 2/7/2024(UTC)
Posts: 71
United States

Thanks: 7 times
Was thanked: 5 time(s) in 5 post(s)
Originally Posted by: doggy Go to Quoted Post
Originally Posted by: knbPixels Go to Quoted Post

I actually just used the standard title that you chose as an example


Strange as i can asure you that it works here

add: console.writeline(eastern) between the line Dim.. and API... and see what it says in the console when you run the script (= keeping the settings-script window open/ the black part )


When I start a new project file I can get the time to appear in the input, although it's in 24 hour format. Maybe I have an errant input that it's affecting in my main file, let me check
knbPixels  
#13 Posted : Wednesday, August 21, 2024 7:15:10 AM(UTC)
knbPixels

Rank: Advanced Member

Groups: Registered
Joined: 2/7/2024(UTC)
Posts: 71
United States

Thanks: 7 times
Was thanked: 5 time(s) in 5 post(s)
Ok yeah, I already had a title created that was called that same title name and it was being affected instead of the new one....got that sorted out. It's in 24 hour format
doggy  
#14 Posted : Wednesday, August 21, 2024 7:18:52 AM(UTC)
doggy

Rank: Advanced Member

Groups: Registered
Joined: 12/27/2012(UTC)
Posts: 5,216
Belgium
Location: Belgium

Thanks: 291 times
Was thanked: 955 time(s) in 790 post(s)
Originally Posted by: knbPixels Go to Quoted Post
Ok yeah, I already had a title created that was called that same title name and it was being affected instead of the new one....got that sorted out. It's in 24 hour format


see change at end for AM/PM time display

API.Function("SetText",Input:="Text Middle Centre Left Right Sharp.gtzip",SelectedName:="Message.Text",Value:=eastern.ToString("HH:mm tt"))
thanks 1 user thanked doggy for this useful post.
knbPixels on 8/21/2024(UTC)
knbPixels  
#15 Posted : Wednesday, August 21, 2024 7:21:04 AM(UTC)
knbPixels

Rank: Advanced Member

Groups: Registered
Joined: 2/7/2024(UTC)
Posts: 71
United States

Thanks: 7 times
Was thanked: 5 time(s) in 5 post(s)
Originally Posted by: doggy Go to Quoted Post
Originally Posted by: knbPixels Go to Quoted Post
Ok yeah, I already had a title created that was called that same title name and it was being affected instead of the new one....got that sorted out. It's in 24 hour format


see change at end for AM/PM time display

API.Function("SetText",Input:="Text Middle Centre Left Right Sharp.gtzip",SelectedName:="Message.Text",Value:=eastern.ToString("HH:mm tt"))


Got it, thanks! fully functional now! you rock!
Users browsing this topic
Guest (4)
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.