|
Dear friend,
Better way is use a context menu for the list & click on the list.
Onn click event of the list
ContextMenuService.GetContextMenu(listname).IsOpen = true;
List_MouseRightButtonDown
e.Handled = true;
Hope this may help u
Regards,
Satish
|
|
|
|
|
hi guy's
I want to develop an application(control pc via wp7 ) but the WP7's screen show the PC's screen.
So how I can do it? what I need (protocol RDP, TCP/IP)???
and how can I do a connection between WP7 and PC?
|
|
|
|
|
|
what r u mean ??????????????????/
|
|
|
|
|
Ignore him. He's been reported as a spammer.
Why is common sense not common?
Never argue with an idiot. They will drag you down to their level where they are an expert.
Sometimes it takes a lot of work to be lazy
Please stand in front of my pistol, smile and wait for the flash - JSOP 2012
|
|
|
|
|
Hi I am working on Win 8 metro app buid in silverlight.
I have two controls Control1 and Control2
Control2 is inside Control1
Control2 has a listview and Control1 has buttons. Clicking on listview has to disable buttons in Control1.
I tried to achieve this from code behind by using
public bool OverriddenFlag
{
get { return _overriddenFlag; }
set
{
_overriddenFlag= value;
NotifyPropertyChanged("OverriddenFlag");
}
}
and
in xaml
<Button x:Name="ShowDetails"
FontWeight="bold" FontSize="12"
Content="+" Click="ShowDetails_Click"
IsEnabled="{Binding OverriddenFlag, Mode=OneWay}"
/>
but it didn't have the desired effect.
How can I disable buttons. Any idea?
|
|
|
|
|
nitin_ion wrote: but it didn't have the desired effect
What does that mean? The click event for the listview did not fire? The property did not get set? Property got set but button was still enabled?
Why is common sense not common?
Never argue with an idiot. They will drag you down to their level where they are an expert.
Sometimes it takes a lot of work to be lazy
Please stand in front of my pistol, smile and wait for the flash - JSOP 2012
|
|
|
|
|
It did not disabled the button. button was still in enabled state.
|
|
|
|
|
AND?
Did the click event on the listbox not fire? Did the property not get set? What have you done to debug this?
Why is common sense not common?
Never argue with an idiot. They will drag you down to their level where they are an expert.
Sometimes it takes a lot of work to be lazy
Please stand in front of my pistol, smile and wait for the flash - JSOP 2012
|
|
|
|
|
Yes everything fired
but
PropertyChanged event in
private void NotifyPropertyChanged shows null.
Here is the code behind in Control2 to change button state in Control1
public void Somemethod()
{
Control1 ng = new Control1();
ng.EnabAdd =false;
}
and this is the property in codebehind in Control1
public bool EnabAdd
{
get { return _en; }
set
{
_en = value;
NotifyPropertyChanged("EnabAdd");
}
}
|
|
|
|
|
Sorry I do not think you have a good grasp of what it is that you are doing.
nitin_ion wrote: public void Somemethod()
{
Control1 ng = new Control1();
ng.EnabAdd =false;
}
This will do exactly nothing except create a new control1 and then disable it before going out of scope.
Your button is not being disabled because you have bound it to a property and not changing the property value. I suspect that your NotifyPropertyChanged is null because you have not set the DataContext. "Somemethod" is not a click event handler for a listbox.
Why is common sense not common?
Never argue with an idiot. They will drag you down to their level where they are an expert.
Sometimes it takes a lot of work to be lazy
Please stand in front of my pistol, smile and wait for the flash - JSOP 2012
|
|
|
|
|
Well yes i am new to Silverlight
SomeMethod is what i call on listviewitem click event.
I just want to changes the state of button when item is clicked. Is there any tutorial which can help me to do this?
|
|
|
|
|
finally got it like this
FrameworkElement fe = (FrameworkElement)this.Parent;
while (fe.GetType().Name != "parent")
fe = (FrameworkElement)fe.Parent;
var tyui=(Button)fe.FindName("controlintheparent");
|
|
|
|
|
Make you property as dependecny property as you code look ok may be binding is not workig as its not a depedency property.
|
|
|
|
|
Good day!
I have XamDataGrid control with option AutoGenerateFields set to False. When i switch this option to True i see all available colums.
I show my code:
<igDP:XamDataGrid
DataSource="{Binding AllProduction}"
Theme="Office2010Blue"
>
<igDP:XamDataGrid.FieldLayoutSettings>
<igDP:FieldLayoutSettings AutoGenerateFields="False"
HighlightAlternateRecords="True"
SelectionTypeCell="Single"
SelectionTypeField="Single"
SelectionTypeRecord="Single"/>
</igDP:XamDataGrid.FieldLayoutSettings>
<igDP:XamDataGrid.FieldSettings>
<igDP:FieldSettings x:Name="FieldSettings"
AllowCellVirtualization="True"
AllowEdit="True"
AllowGroupBy="True"
AllowLabelVirtualization="True"
AllowRecordFiltering="True"
AllowResize="True"
FilterClearButtonVisibility="Visible"
AllowFixing="Near"
AllowHiding="ViaFieldChooserOnly" />
</igDP:XamDataGrid.FieldSettings>
<igDP:XamDataGrid.FieldLayouts>
<igDP:FieldLayout >
<igDP:Field Name="Article" Label="Article" Width="45" IsScrollTipField="True"/>
<igDP:Field Name="Condition" Label="Condition" Width="50" />
<igDP:Field Name="Description" Label="Description" Width="50" />
<igDP:Field Name="Standartprice" Label="St. price" Width="50" IsScrollTipField="True"/>
<igDP:Field Name="Listprice" Label="List price" Width="50" >
</igDP:Field>
</igDP:FieldLayout>
</igDP:XamDataGrid.FieldLayouts>
<igDP:XamDataGrid.ViewSettings>
<igDP:GridViewSettings UseNestedPanels="True" />
</igDP:XamDataGrid.ViewSettings>
</igDP:XamDataGrid>
In FieldLayout section i defined some columns, but there are no columns when i run application.
Any suggestions ?
|
|
|
|
|
Make sure your datasource is populated.
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
Datasource is populated - 100%
|
|
|
|
|
hi
i want ask how i can connect my desktop with wp7 ?
wcf to control my pc via wp7 it possible in wcf?
|
|
|
|
|
You can connect WCF to WP7. Go through this[^] as an example.
However, I'm not sure I understand what you mean by connecting desktop to WP7.
|
|
|
|
|
i mean if i can use wcf to control my desktop( i mean control mouse and to read any files on my desktop via wp7 ) that i mean ?
|
|
|
|
|
hi there. Thats what I want. I want to build WPF UI to allow users to intuitively edit XMl.
My XML is as simple as this:
<publishers>
<publisher>
<name>Wiley</name>
<weblink>http://www.wiley.com</weblink>
<books>
<book>
<name>Project Management</name>
<price>10.00</price>
</book>
</books>
</publisher>
<publisher>
:
:
<books>
:
:
</books>
</publisher>
</publishers>
So how can I build one such UI. Please help. Thank you.
|
|
|
|
|
That's rather a broad question, to which there is not a simple answer. Assuming you have a basic knowledge of WPF applications you should take a look at some of the articles[^] here on CodeProject for sample code that may help you.
Binding 100,000 items to a list box can be just silly regardless of what pattern you are following. Jeremy Likness
|
|
|
|
|
Don't think in terms of XML; think classes and objects.
Create a WPF app that manages instances of publishers and books:
List<Publisher> Publishers;
Class Publisher {
...
List<Book> Books;
...
}
Class Book {
...
}
Use the .Net XmlSerializer class to write and read the object graph to and from XML.
|
|
|
|
|
i am trying to develop a WPF application, i have a mainwindow composed with 3 tabitems, i want to show Wpfpage when i click on bouton in tabitem3, how can i use "mdi container" in WPF application to show WPFpage
|
|
|
|
|
Hi!
I've added a Scrollviewer to my Screen. Inside the scrollviewer, I've added a scrollpanel and inside which a set of images. I've added the functionality for the tap event of the scrollpanel. I've to add two more sets of scrollviewer, scrollpanel and images(different ones from the first set of images) to the same screen. The functionality for the second and third set of scrollviewer is same with the first one. How to add these two more new scrollviewers? I can't use the same name for these three scrollpanels. How to design so that the existing code can be used for the new scrollviewer and scrollpanel sets also?
|
|
|
|