|
Nope, I think I saw something similar a couple weeks ago... and I will reply the same, if you don't know how to do it, I'll be more than happy to do it for you... I can send you my rates if you're interested
I want to die like my grandfather- asleep, not like the passengers in his car, screaming!
|
|
|
|
|
|
|
Sadly this can get quite complex. There's a project here on the site that implemented something similar.
The best option is to search for MyXaml. It's an opensource XAML parser that contains code to do this.
I hope this helps.
|
|
|
|
|
I'm not sure what you're asking.
Do you need to dynamically load the mydll Assembly?
|
|
|
|
|
No. I can load my assembly.
What i need is to load the values of my properties from the xml file.
I'm serializing the values of my properties, but if the property is a basic type (int, float, string...) there is no problem, the problem is when my property is the type Myclass, I can not load again my values.
|
|
|
|
|
|
Sorry, but the ploblem is not with the serialization, is loading the data.
The error always says that is not possible to load the assembly.
Any way, thank you
|
|
|
|
|
billy_iii wrote: No. I can load my assembly.
billy_iii wrote: the ploblem is not with the serialization, is loading the data.
Now which way is it?
I know the language. I've read a book. - _Madmatt
|
|
|
|
|
I have a winforms application (C# 2008 Express Edition), and I want the user to be able to drag and drop the columns to a different position in the DataGridView.
The DataGridView is unbound, and is populated with data on opening of the form, the columns are programmatically set.
I have "AllowUserToOrderColumns" set to true, but i can't reposition the columns.
Is it possible to reposition columns, and if so how do I accomplish this.
TIA,
Rob
|
|
|
|
|
|
Paw Jershauge wrote: Try display this in the PropertyGrid.
I've tried using your code, and it seems to work;
public partial class MainForm : Form
{
PropertyGrid grid = new PropertyGrid();
Demo myDemo = new Demo();
public MainForm()
{
InitializeComponent();
grid.Dock = DockStyle.Fill;
grid.SelectedObject = myDemo;
Controls.Add(grid);
}
}
public class Demo
{
[Category("Behavior")]
public int Total
{
get;
set;
}
} Are you inheriting from Object , as the snippet suggests?
I are Troll
|
|
|
|
|
What kind of OS er you using ??? also Windows 7 64bit ???
I have made a screendump. take a look here ScreenDump
With great code, comes great complexity, so keep it simple stupid...
|
|
|
|
|
Paw Jershauge wrote: What kind of OS er you using ??? also Windows 7 64bit ???
Windows XP, 32 bit. I'm getting a category-heading as expected, both with .NET 3.5 as with 4.0.
Is it only reproducable on 64-bit Weven?
I are Troll
|
|
|
|
|
|
Paw Jershauge wrote: Dont know, will look into it tomorrow on work... but its kind of funny dont you think ?
That it is - I'm curious what caused it.
Paw Jershauge wrote: i have asked microsoft, but still no answer...
Over Microsoft Connect?
|
|
|
|
|
Yes over Connect... the reason I posted it here, was to see if others had the same experience.
When i get the answer i will post it here.
With great code, comes great complexity, so keep it simple stupid...
|
|
|
|
|
Just a short follow up: The same happens on a Vista 64 bit.
So the error/bug is now confirmed on the following OS:
- Windows 7 (64 bit)
- Vista (64 bit)
Its running correctly on (No bug):
- Windows 7 (32 bit)
- Vista (32 bit)
- Xp (32 bit)
With great code, comes great complexity, so keep it simple stupid...
|
|
|
|
|
Thanks, good to have a future reference
I are Troll
|
|
|
|
|
Ok so heres the real bug, although its not really a bug, its more a culture thing.
When running the propertygrid in the danish language, the following CategoryAttribute will be translated:
Category("Appearance") = Udseende
Category("Behavior") = Type (the correct word for this would be "adfærd" or "opførsel" and NOT Type)
Category("Data") = Data
Category("Font") = Skrifttype
Category("List") = Oversigt (the correct word for this would be "List" or "Liste" and NOT Oversigt)
Category("Misc") = Diverse
Category("Position") = Placering
Category("Scale") = Skalering
Category("Text") = Tekst
I didnt consider the culture thing because translating Behavior to danish is not Type
I've posted the information on my blog here: C# and I[^]
With great code, comes great complexity, so keep it simple stupid...
|
|
|
|
|
Cool, good to have it logged. Let's hope it'll be rectified in the next update
I are Troll
|
|
|
|
|
Well I found since I just downloaded the VS 2010 RTM, that its corrected in the framework 4.0, but having thats said, I dont know if danish version will be corrected... hehe lets see when that come out.
With great code, comes great complexity, so keep it simple stupid...
|
|
|
|
|
|
The first thing that comes to mind. Store the connection string in a config file.
"WPF has many lovers. It's a veritable porn star!" - Josh Smith As Braveheart once said, "You can take our freedom but you'll never take our Hobnobs!" - Martin Hughes.
My blog | My articles | MoXAML PowerToys | Onyx
|
|
|
|
|
Have you considered a Web Service?
|
|
|
|