|
You don't need to initialize the class in the method - all you need to do is have a method that accepts the relevant IList(s) that you are interested in, and work with it there. For instance:
private void MyMethod(IList addedItems, IList removedItems)
{
} Then all you need do in your event handler is call
MyMethod(addedItems, removedItems);
|
|
|
|
|
Hi Pete thanks for your answer. This looks good. Just 1 question. Say I have a listview with 5 items in it and that the 2nd item is selected then "addedItems" is the 2nd item and "removedItems" are the rest of the 4 items. Am I right on this part?
Regards,
Samar
|
|
|
|
|
Not quite. AddedItems refers to the items that were added to the selection since the last time the event was fired, and RemovedItems refers to the items that were removed from the selection since the last time the event was fired. This means that the changes effectively represent deltas and are cumulative.
|
|
|
|
|
Hi friends,
I have made a small application using WPF. Now I want to obfuscate so that no one can steal my algorithms. Also so that no one can break my licensing mechanism.
I did try trial/free versions of some tools like Dotfuscator, Eazfuscator, Babel etc. But in these trial versions, my application get crashed while executing its one or other functionality. It might be because vendor don't want us to use application obfuscated with their free/trial versions.
Can anybody suggest me a free Obfuscator which provide reasonable/moderate security but no crash or serious bugs in obfuscated assemblies?
Thanks in Advance
Aseem
|
|
|
|
|
Hi,
A free one : NET NamesObfuscator
Take a look over there : http://pipiscrew.com/ in 'Freewares 4 developers' section.
Best regards.
neojudgment
|
|
|
|
|
Hi Neojudgment,
Thanks for the reply. Today I'll try to use NET NamesObfuscator and will get back to you with my findings. Hope it will work for me.
Best Regards
Aseem
|
|
|
|
|
Hi Friend,
I found the same problems with NET NamesObfuscator what I found with others. Then I tried Babel. Its trial version is also causing crash to my application. But it has some option which we can turned ON/OFF. It served my purpose. I think Babel is a very good obfuscator. One problem with it is that it has a command line UI not GUI.
Regards
Aseem
|
|
|
|
|
Aseem Sharma wrote: Now I want to obfuscate so that no one can steal my algorithms. Also so that no one can break my licensing mechanism.
I'm sorry to tell you this, but if you have .NET code then it can be read - the obfuscated code makes it harder, but not impossible to break your algorithms.
|
|
|
|
|
Hi Pete,
Thanks for the reply. I know that I cannot do anything other than just making it harder to read and understand my code. But for my small application, it would be enough. Can you suggest me a free Obfuscator that can obfuscate the WPF code and providing reasonable security?
Regards
Aseem
|
|
|
|
|
|
Hi Friend,
I found the same problems with Eazfuscator what I found with others. Then I tried Babel. Its trial version is also causing crash to my application. But it has some option which we can turned ON/OFF. It served my purpose. I think Babel is a very good obfuscator. One problem with it is that it has a command line UI not GUI.
Regards
Aseem
|
|
|
|
|
|
Hi,
I just started a silverlight 4 application in VS2010, enabling RIA services. Installed the Silverlight 4 Tools. and as i debug, i am finding this exception.
an unhandled win32 exception occurred in plugin-container.exe
please help me get throught this as its quite annoying as my VS2010 keeps on crashing. and also the browser reports, the silverlight plugin has crashed. I tried reinstalling VS2010 and SL tools. doesnt work.
Thanks,
Manu
|
|
|
|
|
Hello.
I'm new on WPF. I'm trying to use a Path as content of a button. The problem is that using the same path on different buttons, the path is only visible on the last one created.
This is the declaration of the path on a ResourceDictionary
<Path x:Key="CloseGeometry" Fill="{StaticResource DefaultForeground}" Stroke="Transparent"
Data="M 4,4 L 4,16 L 16,14 L 16,20 L 30,10 L 16,0 L 16,6 Z">
</Path>
And this is how I try to use it like button content.
<Button Name="dataEndavantButton" Style="{StaticResource AppButtonStyle}" Content="{StaticResource CloseGeometry}"></Button>
What I'm doing wrong?
Thanks in advance.
modified on Tuesday, September 28, 2010 5:49 AM
|
|
|
|
|
This article[^] should help you out.
The funniest thing about this particular signature is that by the time you realise it doesn't say anything it's too late to stop reading it.
My latest tip/trick
Visit the Hindi forum here.
|
|
|
|
|
Thx a lot for the link. It goes beyond what I expected as answer. It gives me a wider look to the button design...
Best regards, Xavier
|
|
|
|
|
Does Silverlight 4 (VS2010) allow editing code while debugging?
The funniest thing about this particular signature is that by the time you realise it doesn't say anything it's too late to stop reading it.
My latest tip/trick
Visit the Hindi forum here.
modified on Tuesday, September 28, 2010 12:21 AM
|
|
|
|
|
Great question. If you are using 64Bit machine. It won't allow. Like you, I'm also having the same problem. I haven't checked it with 32-bit machine.
|
|
|
|
|
|
Thanks.
The funniest thing about this particular signature is that by the time you realise it doesn't say anything it's too late to stop reading it.
My latest tip/trick
Visit the Hindi forum here.
|
|
|
|
|
|
|
Hi,
I have the following deceleration of a rich text box:
<RichTextBox
x:Key="rtfBox"
SpellCheck.IsEnabled = "False"
ContextMenuService.ShowOnDisabled="True"
ContextMenu="{StaticResource rtfBoxContextMenu}">
</RichTextBox>
And the context menu is defined as a resource on the same xaml as follows:
<ContextMenu x:Key="rtfBoxContextMenu">
<MenuItem Command="Copy"/>
<MenuItem Command="Cut"/>
<MenuItem Command="Paste"/>
<Separator/>
<MenuItem Command="My:MyCommands.ToggleSpellChecker" IsCheckable="true"/>
</ContextMenu>
I would like to bind the check box of the menu item to the state of the spellcheck isenabled property.
Please help. What minimal xaml/code is needed for that?
10x
|
|
|
|
|
You could name the CheckBoxMenuItem and bind it via property path. Like
<ContextMenu x:Key="rtfBoxContextMenu">
<MenuItem Command="Copy"/>
<MenuItem Command="Cut"/>
<MenuItem Command="Paste"/>
<Separator/>
<MenuItem Command="My:MyCommands.ToggleSpellChecker" IsCheckable="true" Name="menuItemCheckBox"/>
</ContextMenu>
<RichTextBox
x:Key="rtfBox"
SpellCheck.IsEnabled = "{Binding Source={StaticResource rtfBoxContextMenu}, Path=menuItemCheckBox}"
ContextMenuService.ShowOnDisabled="True"
ContextMenu="{StaticResource rtfBoxContextMenu}">
</RichTextBox>
|
|
|
|
|
Hi,
I have a wpf rich text box that I open and show in a win32 application.
I declare the rtf box in a resource dictionary like so:
<RichTextBox
x:Key="rtfBox"
HorizontalScrollBarVisibility="Auto"
VerticalScrollBarVisibility="Auto"
HorizontalAlignment="Stretch"
VerticalAlignment="Stretch"
/>
In another place, I have a wpf window which I use as a floating tool bar. I declare it in its own xaml, similar to the following:
<Window x:Class="BidiFix.SandBox.Window1"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
mc:Ignorable="d"
Title="Window1" AllowsTransparency="True" Focusable="False" ShowActivated="False" ShowInTaskbar="False"
SizeToContent="Width" Height="24" Topmost="True" Padding="2"
WindowStyle="None" Background="Transparent" >
<Border>
<StackPanel Orientation="Horizontal" HorizontalAlignment="Right" Margin="2">
<Button Command="Copy" Context="Copy"/>
<Button Command="Cut" Context="Cut"/>
<Button Command="Paste" Context="Paste"/>
</StackPanel>
</Border>
</Window>
I instantiate and show the window using the following code:
RichTextBox rtfBox = GetTheBox();
Window1 win = new Window1();
win.Show();
Now, as you can see I have both the rtf box and window available. But the window is not an ancestor of the rtfBox, nor do they share the same xaml.
What minimal markup and/or code is needed to connect the Clipboard commands and button states to the rtf box, such that they will reflect their availability based on the selection state in the rich text box and when click will operate on the rich text box.
Please help.
10x.
|
|
|
|