All Questions
Tagged with visibility c#
297
questions
0
votes
1
answer
50
views
C# When I open Panel first time it doesnt trigger VisibilityChanged WinForms
I have a UserPanel class that has Controls in it buttons,Labels ect. When the Panel is created at runtime it passes to the Constructor of Form1 (this) so I can use some methods and I have a ...
0
votes
1
answer
20
views
Issue WPF Datagrid maybe bug?
I am generating a datagrid dynamically and the only problem I have is that it creates an extra row at the end, it is something visual because when I delete by code the last row continues to appear.
&...
0
votes
0
answers
69
views
Unity setactive() not working because of object name
So I have a sort of item system in my game and it opens a savefile to see what items the player has at the time, when it loads it enables and disables objects based on the savefile information. Which ...
0
votes
1
answer
322
views
Make element visible when Validation.HasError is true
I have the following xaml markup:
<GroupBox Margin="10" Padding="20" Header="Case 5 - Custom Error Object">
<GroupBox.DataContext>
...
-2
votes
1
answer
373
views
How do i make it so that if a key is pressed, an action is done permanently?
I've got into game development, and I decided to choose Godot as the game engine because C# was supported, and I knew the language.
I've been working on a simple game, and at some point, I ran into a ...
1
vote
1
answer
140
views
TreeViewItem IsVisible property always true
I have a TreeView control in my application that is populated (in the XAML) by binding its ItemsSource to an ObservableCollection of strings in my view model.
There are many more nodes that can be ...
2
votes
3
answers
750
views
WPF change visibility based on Items in Observable-Collection
I have the Following Collection:
ObservableCollection<CheckedFileObject> Files
A CheckedFileObject contains a FileObject and a bool isChecked.
Now when a user selects a File the isChecked Value ...
-2
votes
1
answer
219
views
Visual Studio C# Get sheet visible property
I'm trying to fill a dictionary with name as key, and an array with codename and if sheet is visible. This is where I ran into a conversion issue with sheet.visible
If I use == true I get this error:
...
0
votes
1
answer
725
views
How to create a heartbeat using MassTransit when consuming a message from AWS SQS
Using MassTransit with AWS SQS (simple queue service), we would like to implement a heartbeat, as advised in the AWS docs:
If you don't know how long it takes to process a message, create a heartbeat ...
8
votes
2
answers
690
views
C# public members visibility of a class with no namespace
I have a project that I publish as MyNuget package in a local feed. The project references a ThirdPartyNuget that has ThirdPartyExtensions public static class with public extension methods over ...
0
votes
1
answer
255
views
Button does not want to stop being visible
So, I'm trying to make simple screenshot app in Window Forms, but i would like my button to dissapear whenever I take a shot. Unfortunately, it does not want to be invisible, even after setting ...
0
votes
1
answer
107
views
Dynamic change of binded visibility of flipview's item template
I am making UWP desktop app using c# and xaml.
I need to change visibility of two text blocks(let's say TextBlock1 and TextBlock2) which is a part of FlipView's item template, depending on user input (...
0
votes
1
answer
194
views
How to disable validation of a combox element when visibility is collapsed?
I want to disable the validation of a ComboBox or a TextBox when their visibility is collapsed. Can I realize this within the XAML code?
<ComboBox Name="XYZCb" ItemsSource=&...
1
vote
1
answer
1k
views
C# class can't see static method of another class
I've run into some accessibility problem with one of my Unity projects. I created a class that does NOT inherit from MonoBehaviour. It has a method public static void LoadScene(string sceneName).
When ...
3
votes
1
answer
116
views
Is the documentation wrong for Graphics.IsVisible(Rectangle rect)?
Microsoft's online documentation says that this Graphics method returns "true if the rectangle specified by the rect parameter is contained within the visible clip region of this Graphics; ...
1
vote
1
answer
723
views
How can I hide datagridview row whenever a column value equals specific value
So for example,
I have this datagridview which is bounded to a datatable:
A
B
C
1
4
7
2
5
8
3
6
9
And B is the column I want to check the value for, for example I have a saved int value of 5. The ...
0
votes
0
answers
116
views
Why does calling MessageBox.Show() affects the visibility of other Forms (and threads)?
From a console app which has no window (ProcessWindowStyle.Hidden) I need to start and display a Form (yes - I know this is bad design which should be avoided).
My first intent was the following code:
...
1
vote
1
answer
115
views
Making Elements not possible to manipulate Visibility
I have a ASP-WebForm-Application with several User-Rights.
In CodeBehind I am hiding some Elements if the specific Rights aren't given. But with F12 the User could manipulate the Code the get some ...
0
votes
1
answer
202
views
Hide/show section based on buttonclick
I'm working with Blazor HTML and I have a <section class="showContent"> containing a form that I only want to show to those who click the "yes" option, I want to hide the ...
0
votes
2
answers
1k
views
WPF visibility collapse keep space
i have 3 columns, while using a specific converter i succeed to change visibility of the middle and right column to visibility collapse or visible.
My problem is that when those columns should be ...
0
votes
0
answers
181
views
XAML MVVM: How to make items visilibity grey out based on a bool condition from view model
I'm new for XAML and MVVM. I need to add a control to freeze/greyed out to disable user to click/select buttons/combobox once the device is connected successfully. For below, i need to freeze the ...
0
votes
0
answers
843
views
WPF C# Set visibility binding in code behind for framework element
i have a problem binding the visibility property in code behind and really hope, you can help me.
I create a data grid column with a button. The tag property of the button is already binded to the ...
-1
votes
2
answers
74
views
How can I bind the visibility of a StackPane to a property?
I have a few StackPanes that I only want to display for a specific value of a ComboBox. I've gotten the property to change as I want it to, but for some reason, the StackPane visibility doesn't update ...
0
votes
1
answer
115
views
Variable not detected to binding visibility properties in UWP
I have three buttons and I would like to condition their visibility with a variable.
But I have the impression that my variable is not detected.
MainPage.xaml :
<Button
Margin="0,0,0,50"
...
0
votes
1
answer
286
views
WPF Multiple dialogs, Visibility property issue
I have a login form which starts a dialog of a lecturerWindow
When swapping windows it looks like that:
//LoginWindow to LecturerClient
this.Visibility = Visibility.Collapsed;
LecturerWindow ...
0
votes
2
answers
348
views
Grid is not changing after child elements are switched to collapsed or hidden
I have a grid with 4 buttons. All 4 buttons are visible when starting my application. After a user action, buttons 1 to 3 are switch to collapsed/hidden. My goal is that the 3 buttons are no longer ...
1
vote
1
answer
1k
views
WPF: Trying to change visibility based on selection in combobox
I would like to display a different stackpanel based on the selection made in a combobox.
Idea is to collapse any stackpanels that aren't needed.
The combobox looks something like this:
<...
1
vote
1
answer
357
views
Hide SVG element from C#
I have a svg which contains two groups.
<svg viewBox="0 0 150 150" xmlns="http://www.w3.org/2000/svg">
<g id="gr1" fill="white" stroke="green" stroke-width="5">
<circle cx="40" ...
0
votes
1
answer
193
views
DataGrid RowDetails Visibility on RowDoubleClick
In my Datagrid xaml I set the rowdetailsvisibilitymode to collapsed.
Then I created an event on RowDoubleClick to collapse and expand the details of a row when the row is double clicked:
private ...
0
votes
0
answers
93
views
How to move a non-Visible Application
This is a follow up question to one of the answers provided for post Quit() causes Access to become visible for a moment.
The answer recommends that I move the window off screen so that the ...