Questions tagged [data-binding]
A general technique that binds two data/information sources together and maintains them in sync.
23,077
questions
0
votes
0
answers
8
views
Data binding in custom WPF controls
I'm completely stuck trying to bind an image to my custom WPF Expander.
I found an examle for creating expander template here: https://www.codeproject.com/Articles/248112/Templating-WPF-Expander-...
0
votes
0
answers
13
views
Android data binding - visible if state is instanceOf Sealed Class
I have different states for my fragment as below
sealed class AccountState {
object Fetching : AccountState()
object ErrorFetching : AccountState()
data class NewUser(val url: String) : ...
-1
votes
1
answer
20
views
WPF Bind item source for ListBox through xaml
<Grid>
<ListBox x:Name="phonesList" SelectionChanged="phonesList_SelectionChanged" ItemsSource="{Binding Phones}">
<ListBox....
0
votes
1
answer
17
views
Why this why to update Binding value work and second option don't work
I'm try to delate and modify some "project" data in my view,
The view have a @Binding property Project, which is passed across different view.
In this current view I need to delate a picture ...
0
votes
1
answer
21
views
I don't know why this app is shutting down(because of databinding,setOnClickListener)
class day_1 : Fragment() {
// TODO: Rename and change types of parameters
private var param1: String? = null
private var param2: String? = null
private var _binding: FragmentDay1Binding? = null
...
0
votes
1
answer
17
views
knockout.js can you access the binding context from a script?
I have a javascript object graph, an HTML form, and knockout bindings connecting the two. The form is complex, and sometimes the form needs to add some computed observables to some sub-object in our ...
0
votes
0
answers
23
views
WPF user control binding dynamic combobox
I have a select list called Printers which is filled by default, after selecting a value from this select list the list called Trays should be filled but it doesn't. I've tried various methods but it ...
0
votes
0
answers
13
views
WPF C# - Select Rows in DataGrid when they are grouped
I'm working on a plugin. I need the user to be able to make a selection in the main application, and those objects become highlighted in the datagrid. I currently do this by having the application's ...
0
votes
2
answers
59
views
How to change a whole column value in ListView in WPF (C# or VB)
Recently I’ve been working on a project where I need to change the column value of a listview
like when the user clicks on the start button, it changes the whole column text to ‘Searching,’ and after ...
-2
votes
2
answers
39
views
WPF How to find a specific control in an ItemsControl with data binding
I have an ItemsControl which is bound to a list:
<ItemsControl x:Name="icFiles" ItemsSource="{Binding Path=files}">
<ItemsControl.ItemTemplate>
<...
0
votes
1
answer
26
views
knockout and applyBindings - how to control the scope?
I am new to knockout, so going to fire a lot of questions. But I'm not new to data binding. So I am knocking my head on the difference between my expectations and reality. Here is a very basic ...
0
votes
1
answer
43
views
Bind the Z position relative to the scene in JavaFX
I currently have a project I am working on in JavaFX that simulates our solar system. The way it is made, a planet (which extends the Sphere class) orbits on a 2D plane, meaning the Z never gets ...
1
vote
2
answers
55
views
WPF MVVM Parent View/ViewModel with child UserControl/ViewModel Data Binding Issue
I have been trying to implement a WPF UserControl with some common functionality between a few different views without success. The UserControl is essentially a ListBox with some Previous & Next ...
0
votes
1
answer
27
views
knockout write binding without observable
In knockout, say we have something like this:
var person = {
name: "The H. Dude",
telecom: [
"mailto:dude@host.com",
"tel:+1-987-654-3210"
]
}
and I have a ...
-1
votes
1
answer
30
views
Databind ObservableCollection<Object> to DataGrid WPF C#
i have a xaml page in namespace Dca.KnxPanel.View with a Datagrid defined as
<DataGrid Grid.Row="2" Grid.Column="2" Name="GroupAddressDataGrid" ItemsSource="{...
0
votes
0
answers
13
views
Binding UserControl property in DataGridTemplateColumn [duplicate]
Within my DataGrid I'm using a DataGridTemplateColumn to implement a custom UserControl (NumberValueIndicator). I'm struggling to bind an item property to a user control property. I'm getting a ...
0
votes
1
answer
23
views
Two way binding with the download of data in an array
I want to program a two ways binding in angular so that when I choose something it can be displayed without me refreshing the page.
My code looks like this:
markup
<div *ngFor="let container ...
-1
votes
0
answers
24
views
Set DataContext in VB.net for XAML Binding
I'm by far not an experienced programmer, but I try my best to get the things working for my own needs. I'm trying to convert a older piece of software that I wrote from Windows Forms to a modern ...
1
vote
1
answer
35
views
How can I bind categories page to categories list depending on the category in xamarin
I have 2 json files, 1 with categories and one with products. How do I bind the data so when I click on for example fashion it shows me only the products within that category. The jsons are not local ...
0
votes
1
answer
30
views
Binding of volume to Docker Container via Kubernetes
I'm new to the area, sorry if my question sounds dumb.
What I'm looking for: I have a containers pod, where one of the containers (alpine based) should read/write from/to the customer's provided file. ...
0
votes
0
answers
6
views
Why Itemscontrol is inconsistent with item source in datagrid wpf?
When First time I open the form, datagrid shows data but when I open other form and again open this form this it gives error Itemscontrol is inconsistent with item source
This is my Datagrid in which ...
0
votes
1
answer
38
views
WPF bind list box Selected item into textbox
I'm trying to put any selected item's name in my list box in the textbox next to it. But I've got trouble doing so.
Here's a little bit of my code:
<DockPanel Margin="10">
...
0
votes
0
answers
35
views
how to call struct into my post Request and how to bind the data
struct LogIn: Codable {
let data: DataClass
let success: Bool
let successCode, httpstatusCode: Int
let developerMessage, userMessage, header: String
}
struct DataClass: Codable {
...
-4
votes
1
answer
41
views
WPF Label or Textblock Display Member by selected ID
How to accomplish this easy?
First of all, I know I can - but I don't want to add additional property string to my viewmodel.
If I make this:
<ComboBox
IsEnabled="False"
IsReadOnly="...
0
votes
2
answers
65
views
in Xamarin form for collection view items how to set button base on item's value? (conditional binfing)
I am doing a Xamarin form project, I have a list of tasks that can be completed or in completed. I want to add a button to display "Mark as completed" for in completed tasks and "Mark ...
0
votes
0
answers
48
views
How does this For To loop work in this context
This line of code was written by another dev:
bindingSet.Bind(_imageViewLoader).For(i => i.ImageUrl).To(vm => vm.ImageTextImagePath);
Some data (this is not an image) also resids within the ...
0
votes
1
answer
73
views
How do I await an async Task from the oninput event of a textbox in Blazor?
My Blazor component looks like this:
<input type="text" @bind-value="@MyText" @bind-value:event="oninput" />
@code {
private String myText;
protected ...
0
votes
1
answer
46
views
Databind Object to Winforms DatagridView with ComboBox
Currently I'm trying to databind object properties to a datagridview. The thing is that the datagridview should have a combobox column, where the user has to choose between two values.
The class in ...
-1
votes
2
answers
55
views
Accessing a static object from Style/template in Generic.xml?
I have a double called LoadAnimAngle which simply holds the angle of a spinning loading icon, which gets rotated over time. This variable is defined in my MainViewModel class. I'm using this same ...
0
votes
2
answers
31
views
How to import data-binding in Android app (Java)?
I had imported data-binding package in another application but, now I am trying to copy paste the same file in another project its showing an error!
I have enabled dataBinding in android in build....
0
votes
0
answers
29
views
Is there an easier way to refresh a datasource in VS2022 than deleting it and re-creating it?
If I change the structure of an object that is used in a datasource of a bindingsource then I need to refresh the datasource so the bindingsource is "aware" of the altered structure.
For ...
0
votes
0
answers
28
views
Why does RelativeSource binding randomly fail to find source?
I need someone to explain to me why two bindings randomly fail to find the binding Source. They switch between failing and working even when I precisely repeat the exact same 2 steps over and over: ...
0
votes
3
answers
50
views
Bind viewmodel property to property in custom view
I created a custom view (NavProgressbar) which has a step property.
private static readonly BindableProperty ProgressStepProperty = BindableProperty.Create(
nameof(ProgressStep), typeof(...
0
votes
1
answer
27
views
WPF progress bar doesn't update [duplicate]
Hi I am trying to set up a progress bar with some text and a button to cancel, so I used a user control. I created properties to this user control (Min,Max,Value) to pass them to the internal progress ...
-1
votes
3
answers
85
views
Input Values are not going to the database?
I'm super new to PHP mysql database, can someone help me out how can I make my input appear on the database. This is just a sample I'm testing. I don't know what I'm doing wrong I have all the ...
0
votes
0
answers
41
views
Why is my data binding not working? (WPF/vb.net)
I want to bind each property of my class "Artikelstammdaten" to a textbox, but my textbox stays empty. This is what the class looks like:
Public Class Artikelstammdaten
Private _Artikel As ...
0
votes
2
answers
38
views
I cant solve this error "lateinit property dataBinding has not been initialized"
I have base activity< T : ViewDataBinding , VM : ViewModel > extends AppCompatActivity()
and i initialize view binding and view model but when run the app i get this error "lateinit ...
0
votes
1
answer
29
views
Parsing Xaml string using XamlServices fails if Xaml contains bindings [duplicate]
I'm trying to build out some WPF components using LINQPad as a test bench. Building it out using a Xaml string and instantiating the classes using XamlServices. This works fine with simple Xaml but I ...
0
votes
0
answers
30
views
Dynamic list of custom items each with edit button. How to button binding?
I tried importing ObjLargeBinding, but idk what to do from there. Do I have to dynamically setOnClickListeners for each objective on screen?
'''
import android.content.ClipData.Item
import android.os....
-1
votes
0
answers
34
views
C# Prism WPF cant populate DataGridComboBoxColumn
I cannot wrap my head arround why my combobox is not populated.
Xaml in qustion
<DataGrid ItemsSource="{Binding Path=ChooseSession}" IsReadOnly="False">
<...
-2
votes
0
answers
18
views
WPF User Control - Binding to a custom DepedencyProperty [duplicate]
I've created a very simply repo that demonstrates the problem I'm having, it's available here: https://github.com/thomasrea0113/wpf-DependencyProperty-bind/tree/simplest-demonstration.
Basically, I ...
-3
votes
0
answers
25
views
What's the best way to make a WPF window with multiple text box fields with data binding [duplicate]
I'm trying to make a simple window with multiple textboxes for user1 to edit information about (some) user2, in simple terms a manager app.
Example of the window (just fields with a hint like (name, ...
0
votes
0
answers
49
views
How to get selected value on SelectionChanged event of ComboBox in ViewModel (WPF-MVVM)?
I am new in WPF Application with pattern MVVM and I have a particular situation that I do not know how to solve it.
I builted a system to switch environments (Productive, WorkDebug and HomeDebug) with ...
0
votes
1
answer
27
views
My Xamarin app keeps crashing due to Databinding(Basic Databinding)
I was trying to use Databinding in my Xamarin app. After implementing, just like the many instructions suggest, it just always crashes while loading the app. Without any real error message.
I guess I ...
1
vote
1
answer
39
views
Addig User And Role to my UserRole table - Never used column name is missing
I am trying to add Role to my User and store the UserID and the RoleID in the UsersRoles table.
var userRole = await _roleManager.FindByNameAsync("User");
...
0
votes
3
answers
97
views
Binding not updating WinUI 3
I'm using WinUI in combination with the microsoft MVVM toolkit.
However im experiencing some issues with Binding and can't figure out where the problem lies.
The ViewModel and models used within the ...
0
votes
1
answer
52
views
Binding elements into a DataTemplate in WPF Window
I have five definitions of DataTemplate in my window, according with a CantidadLlantas property, I choose one of these to show it. Until here all works fine.
But, in each DataTemplate there are some ...
0
votes
1
answer
19
views
table datasource updating but not displaying the content
i'm trying to build a movie watchlist table for a project. The problem is that, when i get my array of data from firebase, i create a MatTableDataSource and attribute it the array i received, but i ...
0
votes
1
answer
25
views
WPF TreeViewItem template (icon+text)
I have this TreeView where every item contains an icon + a text:
<TreeView x:Name="myTreeView" Height="153" VerticalAlignment="Top" Width="215">
...
0
votes
2
answers
24
views
Initial Item in Data bound Combobox is not selected. Even though the Bound Object has a Value
I have a class which is creating a Combobox with a Databinding to an Object.
The Object has a Value for an enum. But when the ComboBox is loaded it doesnt Contain a Value. The Following is the part ...