Questions tagged [valueconverter]

Value converters are culture-aware. Both the Convert and ConvertBack methods have a culture parameter that indicates the cultural information.

Value converters are culture-aware. Both the Convert and ConvertBack methods have a culture parameter that indicates the cultural information.

Ref: IValueConverter

216 questions
-1
votes
1 answer

Bixby command for currency converter

I wanted to try the currency converter feature of bixby where i ask it to convert the value from lets say USD to INR. This feature was in earlier updates of bixby. But when i tried it now, it wont work. If anyone could help me that would be…
-1
votes
1 answer

ValueConverter method is hit but not showing on UI

I a have list containing invoices. These invoices have a direction value represented by an int (incoming = 0, issued = 1). I want to differentiate these invoices by color in the list. I tried to use ValueConverter, but when I populate the list with…
-1
votes
1 answer

MVVMCross WPF ValueConverter has invalid cast

I am trying to bind a foreground color to a WPF Textblock. The property in the view model is a color, as directed by MvvmCross documentation: private System.Drawing.Color _setValueColor; public System.Drawing.Color SetValueColor { …
-1
votes
3 answers

Python Decimal to Binary Converter: "unsupported operand type(s) for /: 'str' and 'int'"

For a class project I have to make a Decimal to Hexadecimal or Binary Converter, and I keep on receiving unsupported operand type(s)for /: 'str' and 'int' and have no clue how to fix it This is the rest of my code: strOut = "" def…
dts
  • 11
-1
votes
1 answer

Calculate the time in Java (Android Studio)

I got one time from the server. This time saved in a array and I show this time in TextView with this code in adapter: txttime.setText(time[position]); I have current time with System.currentTimeMillis() and I want to calculate Different between…
mohammad
  • 33
  • 1
  • 1
  • 7
-1
votes
2 answers

How do I change visibility using a Converter with MenuItem

I need help as i've a UserControl, "myUC" and i want change its visibility when i press a MenuItem. I've following class BoolToVisibilityConverter : [ValueConversion(typeof(bool), typeof(Visibility))] public sealed class BoolToVisibilityConverter…
Dansi
  • 41
  • 4
-1
votes
1 answer

How to convert NSArray object to double

I'm retrieving a value from JSON in NSArray format. It's temperature. However it is in Celsius and I wish to convert it to Kelvin. All I need to do is add 274.15. I'm not really able to do that since it's NSArray and I can't add directly. I tried…
-1
votes
2 answers

How to convert decimal to date?

I have a problem. I have a field START_VALUE where the data type is decimal. I want to convert Decimal to Date. The data type START_VALUE is Decimal.The data of START_VALUE is : START_VALUE |=========| | 240368 | | 198448 | | 197396 | | 126743 | I…
cindy
  • 35
  • 1
  • 3
  • 7
-1
votes
1 answer

Can smbd help me to convert some values from real to virtual

I have very strange but very important question for me. So if you have some free minutes - read next sentences. My mission is: generate values (times) for incoming and outcoming cars on the road. And, from real world I have some variables: length…
Maria
  • 77
  • 1
  • 9
-1
votes
1 answer

Displaying data from Cryptocoin charts API with PHP

Hey Stackoverflow, I've set myself a little project to celebrate the rise of cryptocurrency (having just been stitched up by a conventional bank myself with some incredibly 'un-Christmassy' charges, the growing use of a decentralized currency was a…
Cameron
  • 1
  • 1
  • 2
-1
votes
2 answers

Converting JS output to PHP variable

Here is the code that I am currently using... (javascript injection) Date.prototype.getWeek = function() { var onejan = new Date(this.getFullYear(),0,1); return Math.ceil((((this - onejan) / 86400000) + onejan.getDay()+1)/7); } var imgList = [ …
user2284703
  • 367
  • 3
  • 15
-2
votes
1 answer

Highlight all text blocks that have the same text

I have a rather complex form containing several text blocks. I'd like to add a binding to these block so that, when the mouse is hovered over them, all of the other blocks whose text match the run I'm hovering over get highlighted. This is the same…
Robert Harvey
  • 178,213
  • 47
  • 333
  • 501
-2
votes
3 answers

How can i convert this string to integers & other strings in Python

I got this string... String = '-268 14 7 19 - Fri Aug 3 12:32:08 2018\n' I want to get the first 4 numbers (-268, 14, 7, 19) in integer-variables and Fri Aug 3 12:32:08 in another string-variable. Is that possible?
Quotenbanane
  • 263
  • 1
  • 6
  • 16
-2
votes
2 answers

Convert Text String to Value

I want to convert text strings to numerical values using Javascript in order to create custom variables for a survey link. For example, I have the following possible values for the variable Q14: Inland Great Lakes Rivers Coastal N/A How can I…
-2
votes
1 answer

Changing a unix timestamp to a formatted date?

I currently have a unix timestamp and would like to change it into something more user friendly like instead of "1389317006" I would want "Jan. 10, 2014 13:45". I looked into strtotime() but the PHP Manual said it returns a timestamp which isn't…
user3015565
  • 393
  • 3
  • 6
  • 16
1 2 3
14
15