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
Fabiano  
#1 Posted : Tuesday, February 8, 2022 4:00:49 AM(UTC)
Fabiano

Rank: Newbie

Groups: Registered
Joined: 2/24/2021(UTC)
Posts: 8
Brazil
Location: São Paulo

Thanks: 9 times
Was thanked: 1 time(s) in 1 post(s)
I'm trying to capture these values ​​and add to the timer does anyone have an idea how to do it?

dim txA as string = Input.Find("vMIX_VARIAVEIS.xaml").Text("COUNTHORA01")
dim txB as string = Input.Find("vMIX_VARIAVEIS.xaml").Text("COUNTHORA02")
dim txC as string = Input.Find("vMIX_VARIAVEIS.xaml").Text("COUNTHORA03")

API.Function ("ChangeCountdown",Input:=1,Value:="txA:txB:txC")
doggy  
#2 Posted : Tuesday, February 8, 2022 4:29:19 AM(UTC)
doggy

Rank: Advanced Member

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

Thanks: 284 times
Was thanked: 920 time(s) in 759 post(s)
Originally Posted by: Fabiano Go to Quoted Post
I'm trying to capture these values ​​and add to the timer does anyone have an idea how to do it?

dim txA as string = Input.Find("vMIX_VARIAVEIS.xaml").Text("COUNTHORA01")
dim txB as string = Input.Find("vMIX_VARIAVEIS.xaml").Text("COUNTHORA02")
dim txC as string = Input.Find("vMIX_VARIAVEIS.xaml").Text("COUNTHORA03")

API.Function ("ChangeCountdown",Input:=1,Value:="txA:txB:txC")


slapping something together what looks like code is not going to work

I advice you to do some research on vb.net programming

the timer is one string like 00:00:00
In your case based on the little information given you need to build a string from your element you retrieved first before one can use it as a value for the function ( or build the string within the function Value detail)

As it stands you value is exactly this: txA:txB:txC instead of something like 02:15:32 ( if txA=02 ; txB = 15 and txC = 32)
Kristoph  
#3 Posted : Tuesday, March 1, 2022 2:40:10 AM(UTC)
Kristoph

Rank: Member

Groups: Registered
Joined: 7/6/2020(UTC)
Posts: 15
United Kingdom

Thanks: 4 times
Was thanked: 2 time(s) in 2 post(s)
What values are you actually trying to capture??
doggy  
#4 Posted : Tuesday, March 1, 2022 3:20:48 AM(UTC)
doggy

Rank: Advanced Member

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

Thanks: 284 times
Was thanked: 920 time(s) in 759 post(s)
Originally Posted by: Kristoph Go to Quoted Post
What values are you actually trying to capture??


Pretty obvious ;-)

3 different string values from a title to combine into a (time)string for a countdownchange but missing the concept of Concatenation of string variables with strings into one string.
Hence the advice to do some research on vb.net programming (giving a fish versus teaching to fish).
WaltG12  
#5 Posted : Tuesday, March 1, 2022 4:03:11 AM(UTC)
WaltG12

Rank: Advanced Member

Groups: Registered
Joined: 7/4/2021(UTC)
Posts: 198
United States

Thanks: 6 times
Was thanked: 24 time(s) in 24 post(s)
Originally Posted by: doggy Go to Quoted Post
giving a fish versus teaching to fish


In this scenario, you're doing neither.
thanks 1 user thanked WaltG12 for this useful post.
Fabiano on 3/4/2022(UTC)
doggy  
#6 Posted : Tuesday, March 1, 2022 4:16:50 AM(UTC)
doggy

Rank: Advanced Member

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

Thanks: 284 times
Was thanked: 920 time(s) in 759 post(s)
Originally Posted by: WaltG12 Go to Quoted Post
Originally Posted by: doggy Go to Quoted Post
giving a fish versus teaching to fish


In this scenario, you're doing neither.


Yes i am sorry i forgot some links

https://forums.vmix.com/...86-Scripting-for-Dummies (has examples in use)

https://thedeveloperblog...bnet/string-concat-vbnet
Kristoph  
#7 Posted : Tuesday, March 1, 2022 5:58:20 PM(UTC)
Kristoph

Rank: Member

Groups: Registered
Joined: 7/6/2020(UTC)
Posts: 15
United Kingdom

Thanks: 4 times
Was thanked: 2 time(s) in 2 post(s)
Mate not sure if you realise it, but 90% of your answers on this forum start with rude comments.

Sort it out.

KMA

Originally Posted by: doggy Go to Quoted Post
Originally Posted by: Kristoph Go to Quoted Post
What values are you actually trying to capture??


Pretty obvious ;-)

3 different string values from a title to combine into a (time)string for a countdownchange but missing the concept of Concatenation of string variables with strings into one string.
Hence the advice to do some research on vb.net programming (giving a fish versus teaching to fish).


thanks 1 user thanked Kristoph for this useful post.
Fabiano on 3/4/2022(UTC)
Roy Sinclair  
#8 Posted : Thursday, March 3, 2022 8:24:31 AM(UTC)
Roy Sinclair

Rank: Advanced Member

Groups: Registered
Joined: 11/23/2020(UTC)
Posts: 153
United States
Location: Wichita

Thanks: 9 times
Was thanked: 21 time(s) in 17 post(s)
Originally Posted by: WaltG12 Go to Quoted Post
Originally Posted by: doggy Go to Quoted Post
giving a fish versus teaching to fish


In this scenario, you're doing neither.


Concatenation in VB is done using "+"

So txA + txB + txC will concatenate those three variables.
thanks 1 user thanked Roy Sinclair for this useful post.
Fabiano on 3/4/2022(UTC)
Travis9577  
#9 Posted : Thursday, March 3, 2022 10:22:14 PM(UTC)
Travis9577

Rank: Newbie

Groups: Registered
Joined: 3/3/2022(UTC)
Posts: 1
United States
Location: 3067 Wood Street Saginaw, MI 48607

3 different string values from a title to combine into a (time)string for a countdownchange but missing the concept of Concatenation of string variables with strings into one string.
doggy  
#10 Posted : Thursday, March 3, 2022 10:47:17 PM(UTC)
doggy

Rank: Advanced Member

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

Thanks: 284 times
Was thanked: 920 time(s) in 759 post(s)
Originally Posted by: Travis9577 Go to Quoted Post
3 different string values from a title to combine into a (time)string for a countdownchange but missing the concept of Concatenation of string variables with strings into one string.


Same link as above (see step 3) https://thedeveloperblog.com/vbnet/string-concat-vbnet
Fabiano  
#11 Posted : Friday, March 4, 2022 4:28:11 AM(UTC)
Fabiano

Rank: Newbie

Groups: Registered
Joined: 2/24/2021(UTC)
Posts: 8
Brazil
Location: São Paulo

Thanks: 9 times
Was thanked: 1 time(s) in 1 post(s)
excuse my ignorance, I graduated in programming technician around the year 1999 but I didn't work in the area, I did it because I like programming

But I don't work in the area, I'm in civil engineering, in the pandemic I moved to a company that uses Vmix, so I've already done a lot of automation with the little knowledge I have and with the help here.

I studied the topics, which led me to do a lot of things.

I'm not looking for FISH, I'm asking for help to solve a problem and an idea that I had here at work, that's all.

If anyone can help, great, I'm grateful, but if you don't have the availability or desire, just say nothing, sending me to study programming is not helping at all.

I AM VERY GRATEFUL TO EVERYONE WHO TRYING TO HELP...

THANK YOU VERY MUCH
Fabiano  
#12 Posted : Friday, March 4, 2022 4:34:30 AM(UTC)
Fabiano

Rank: Newbie

Groups: Registered
Joined: 2/24/2021(UTC)
Posts: 8
Brazil
Location: São Paulo

Thanks: 9 times
Was thanked: 1 time(s) in 1 post(s)
Originally Posted by: Kristoph Go to Quoted Post
What values are you actually trying to capture??


I can capture the values that are in a gt title, example: txA=01 txB=15 txC=00

What I need is to take these values and transform into
txA:txB:txC = 01:15:00

Take these values and format as time

I can capture these values, I just can't join them in time format
Fabiano  
#13 Posted : Friday, March 4, 2022 7:05:01 AM(UTC)
Fabiano

Rank: Newbie

Groups: Registered
Joined: 2/24/2021(UTC)
Posts: 8
Brazil
Location: São Paulo

Thanks: 9 times
Was thanked: 1 time(s) in 1 post(s)
Consegui. Obrigado pela atenção de todos

I achieved. Thank you all for the attention

API.Function("SetText",Input:="65",SelectedName:="Message",Value:=txA+":" + txB+":" + txC)
Users browsing this topic
Guest
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.