vMix Forums
	 » 
	General
	 » 
	GT
	 » 
	Change Text Colour as WebRequest
	 
	
        
            
            
    
        
	Rank: Advanced Member
  Groups: Registered
 Joined: 11/20/2020(UTC) Posts: 74   Thanks: 13 times Was thanked: 9 time(s) in 9 post(s)
  
	 
	
     | 
    
        
            
		      
                Hi Folks, I have a piece of working code: Code:request2 = HttpWebRequest.Create("http://127.0.0.1:8088/api/?function=SetTextColour&Input=Videotimer&value=red")
//I cut out response etc...
; 
 as soon as I try to call the colour via hex e.g. #FF0000 it is not working. wether it throws an exception or the text gets transparent? colour value in title editor then is "00000000" I tried $"....value={#FF0000}" (transparent) ;  $"....value='{#FF0000}'" (exception) and what not anybody a clue?  
            
	  
         
     | 
    | 
         
             
     | 
    
         
            
         
     | 
    | 
        
	
     | 
        
        
        
            
        
            
            
    
        
	Rank: Advanced Member
  Groups: Registered
 Joined: 12/27/2012(UTC) Posts: 5,453  Location: Belgium Thanks: 311 times Was thanked: 1008 time(s) in 830 post(s)
  
	 
	
     | 
    
        
            
		      
                Originally Posted by: Chris Daum  Hi Folks, I have a piece of working code: Code:request2 = HttpWebRequest.Create("http://127.0.0.1:8088/api/?function=SetTextColour&Input=Videotimer&value=red")
//I cut out response etc...
; 
 as soon as I try to call the colour via hex e.g. #FF0000 it is not working. wether it throws an exception or the text gets transparent? colour value in title editor then is "00000000" I tried $"....value={#FF0000}" (transparent) ;  $"....value='{#FF0000}'" (exception) and what not anybody a clue?  See the helpfiles "URL encoding may need to be used when using special characters in the Value parameter" https://tvcrew.ch/wiki/d...ers_in_urls_api_via_httphttps://www.w3schools.com/tags/ref_urlencode.ASP 
            
	  
         
     | 
    
        
              1 user thanked doggy for this useful post.  
     | 
    
        
     | 
    | 
        
	
     | 
        
        
        
    
        
            
            
    
        
	Rank: Advanced Member
  Groups: Registered
 Joined: 11/20/2020(UTC) Posts: 74   Thanks: 13 times Was thanked: 9 time(s) in 9 post(s)
  
	 
	
     | 
    
        
            
		      
                cool, thanks Doggy ...%23... who thought about something like that... you were right format problem... and thanks for the links. I mean over the years I did a lot of research but never found these two sites!!! 
            
	  
         
     | 
    | 
         
             
     | 
    
         
            
         
     | 
    | 
        
	
     | 
        
        
        
    
                           
	vMix Forums
	 » 
	General
	 » 
	GT
	 » 
	Change Text Colour as WebRequest
	 
	
    
        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.
	
	
    
    
        Important Information:
        The vMix Forums uses cookies. By continuing to browse this site, you are agreeing to our use of cookies.
        
        
More Details
        Close