|
Change these lines
if (w.ShowDialog() == true)
ContactList.Add(_contact); to
if (w.ShowDialog() == true)
{
if (ContactList == null)
ContactList = new List<Contact>();
ContactList.Add(_contact);
}
|
|
|
|
|
HI Pete,
thanks to reply me,
i changed there lines:
if (w.ShowDialog() == true)
ContactList.Add(_contact);
to
if (w.ShowDialog() == true)
{
if (ContactList == null)
ContactList = new BindingList<contact>();
ContactList.Add(_contact); }
because it doesn't allow me to insert List<> so i insert BindingList <t>...
after i will debug and see what happen..
Thanks again.
i wish you happy work.
See you later
|
|
|
|
|
Yes Pete,
that's all right,
now i can play with the project...
i will test it if there are error.
Thanks so much for your help.
I wish you happy life.
Bye for now
|
|
|
|
|
Nice message - good luck for the future.
|
|
|
|
|
Hi ,
Please try to help me
Can you figure out what the problem could be,
I am building a Carousel in WPF , I have a MediaContent control in the carousel.
When I have the wmv video assigned as the source to the Media content and then when I build and debug the application, It is taking a while before the video starts . The player shows a black screen before its starts the video, It is also occuring in an asp.net website!!
Is it a known issue. Wat is the best solution?
Please let me know asap.
Thanks.
Happy Programming!
Regards,
ctrlnick !
|
|
|
|
|
Hi,
I'm learning how Silverlight/WPFapplication/Direct3D interact between themselves...
Sorry but I haven't a lot experience about this issues, so my question is:
- IS IT POSSIBLE, WITH SILVERLIGHT, TO RENDER WPF FILES IN A DIREC3D/WIN32 APPLICATION? HOW CAN DO IT?
Thanks a lots,
bye,
Carmelo.
|
|
|
|
|
Please do not cross post in the forums. This particular forum is probably the best one for your question.
viashivan wrote: TO RENDER WPF FILES
"The clue train passed his station without stopping." - John Simmons / outlaw programmer
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
"Not only do you continue to babble nonsense, you can't even correctly remember the nonsense you babbled just minutes ago." - Rob Graham
|
|
|
|
|
|
No worries. As Pete has said, you cannot really do what you are asking about.
"The clue train passed his station without stopping." - John Simmons / outlaw programmer
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
"Not only do you continue to babble nonsense, you can't even correctly remember the nonsense you babbled just minutes ago." - Rob Graham
|
|
|
|
|
Could you clarify what you mean please? I can't answer this question because I don't really understand it.
|
|
|
|
|
Hi Pete,
you're right, I try to be clearer
Silverlight is a CROSS PLATFORM, right?
I can create a Direct3D content for hosting in WPF, right?
If I want to work with Direct3D I'll be able to do it only on Windows platform, right?
If I lose the plot please correct me.
So I'd like to know if is it possible to render WPF files in a D3D/Win32 app. with Silverlight.
Can I consider also Moonlight and OpenGL for to do this?
I hope I've been fulfilling,
Thanks,
regards,
Carmelo.
|
|
|
|
|
OK - the answer is no. You can't create DirectX stuff in Silverlight - as you've rightly identified this is because of cross platform issues.
|
|
|
|
|
Hi there,
maybe now I've clearer ideas...
So my question is:
How can I capture WPF content/output from Silverlight App and render it in a Direct3D App ?
Thank you,
bye,
Carmelo.
|
|
|
|
|
This is related to a post I made yesterday, but after researching I think I found where my problem lies, and nevertheless am stuck again. The problem I have is the following. I read from a file data, this data consists of rows of 'x' columns (x changes from file to file).
I want to display these rows in a list in my WPF application. Seems simple enough, might be simple, but as I am a beginner in WPF I might have chosen the most difficult possible way to get there...
Since the row-makeup is completely file specific there's not much in the xaml file, just the declaration of the table-header:
<StackPanel x:Name="MyGridViewList" Orientation="Vertical">
<GridViewHeaderRowPresenter x:Name="grdViewHeader" ColumnHeaderContainerStyle="{StaticResource MyHeaderStyle}"/>
</StackPanel>
In the code behind I read the column specific data and put it in the header.
GridViewColumnCollection colCollection = new GridViewColumnCollection();
for(int i=0;i<mydatacollection.columns.count;> {
GridViewColumn viewCol = new GridViewColumn();
viewCol.Header = MyDataCollection.Columns[i].Name;
viewCol.Width = 100;
colCollection.Add(viewCol);
}
grdViewHeader.Columns = colCollection;
The column-header is displayed correctly. Afterwards I create
GridViewRowPresenter objects for each row, and to the Content property I assign an array of objects. The object at position 0 should be data for 1st column, object at pos 1 for 2nd etc... Right now the number of rows that's displayed is correct but the data in each cell is displayed as: "Object[] Array"
So now I found out that the GridViewRowPresenter does not know how to 'bind' each value to the right column. So in the commented out code above I need to mention somehow to bind to a specific position in the array.
Can anyone tell me how to do this? Or am I doing it completely wrong here?
Thanks for any help,
Davy
|
|
|
|
|
How about using the new datagrid in the wpf toolkit?
http://www.codeplex.com/wpf[^]
This can autogenerate columns, not sure if it will solve your problem though!
|
|
|
|
|
Hey Guys,
I am attempting to drop a WPF User Control onto a Windows Form, and I am getting a weird black border that only shows up on the left hand side of the control. It seems like it is coming from the ElementHost, but it does not have any border properties. Has anyone else experienced this? Anyone know how I can fix it?
|
|
|
|
|
I am using C#, Visual Studio 2008, and the 3.0 framework.
|
|
|
|
|
Hi,
I have a WPF custom created "color palette control" like in office 2007(If you want , you can see how the color palette control looks like my control in the following location http://blog.actiprosoftware.com/post/Ribbon-for-WPF-Adds-Mini-Toolbar.aspx )
I need to implement various features on color palette by adding properties.I can create those properties,if you people provide suggestions regarding the properties(i.e)what are all the properties we can add to give different look to the color palette control.What ever you like to have on the color palette,you can suggest.So,Please suggest me the ideas whatever you think,it will be more useful to proceeed my work.
modified on Tuesday, November 4, 2008 11:58 PM
|
|
|
|
|
I might be missing something basic here, but I am new to WPF ...
Anyway, I am trying to create a dynamic list (nr of columns and data depends on content of a file).
I used the GridViewHeaderRowPresenter for the header (displays fine) and am trying to use the GridViewRowPresenter to add rows to the list.
The problem I have is that the columns of my GridViewRowPresenter all show Object[] Array in stead of the actual data.
Since the makeup of the list is dynamic the xaml part of the list is actually only this:
<stackpanel x:name="MyGridViewList" orientation="Vertical" >
<gridviewheaderrowpresenter x:name="grdViewHeader" columnheadercontainerstyle="{StaticResource MyHeaderStyle}" />
</stackpanel>
In C# behind I do the following
GridViewColumnCollection colCollection = new GridViewColumnCollection();
grdViewHeader.Columns = colCollection;
object rowObj;
while( null != (rowObj = RowParser.GetNextRow()) )
{
GridViewRowPresenter rowPresenter = new GridViewRowPresenter();
rowPresenter.Columns = colCollection;
rowPresenter.Content = rowObj;
MyGridViewList.Children.Add(rowPresenter);
}
The object array that the GetNextRow returns is an array that can contain a mix of both strings and integers. It was my impression that automatically the rowPresenter would convert each member to a string value. This is not the case however.
Can someone guide me to what is wrong here?
Thanks in advance,
Davy
|
|
|
|
|
Hi!
I've created a small application, a WPF client which is talking to a WCF service. My app is self-hosted.
Now, I'd like to run this outside the IDE (Visual C# 2008 Express Edition). That is, to deploy/install my app. I'd really appreciate some advice or links on how to do this. I've been looking around, but I still need some entrance to this somewhat fuzzy area.
Thanks a lot!
|
|
|
|
|
This is a little off topic for the WPF list really ...
Once you have built the release versions of your .exe and/or your dll files those are ready for prime-time ... including bugs!!
At present I'm using Inno Setup to produce my installers and I'd say this is a good place to start. The bigger versions of Visual Studio include a Setup project type but since your on Express you don't have that option. At to be frank I don't think your missing out since I hate that feature!
Just to bullet point it:
1. Get your release versions built (try running the release version on your machine and some other machines as a test).
2. Grab Inno Setup http://www.innosetup.com/isinfo.php[^]
3. Work through the example install scripts that are supplied with Inno Setup (there are some nice tools to help you like http://www.istool.org/[^])
4. Compile your setup and deply ...
This is hugely reduced list but should get you started.
Once your comfy here move onto WixEdit ...
|
|
|
|
|
Thank you!
|
|
|
|
|
How to set One Window inside the Area of another window?WPF.
i.e
The First window is containing Only the Ribbon Control and open in windows maximized state. And when we click any button or TabItem in The Ribbon Control A new Window is opend. I Need to set the newly opend window inside the MainWindow's Area excluding Ribbon.
Thanks.
----------------------------------------------------------------
MainWindow
-----------------------------------------------------------------
RibbonControl
-----------------------------------------------------------------
NewWindow
------------------------------------------------------------------
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|----------------------------------------------------------------
|
|
|
|
|
When you talk about creating one window inside another, what you are normally talking about is creating an MDI window. Now, WPF does not provide native support for MDI because Microsoft is trying to deprecate this technique, preferring Multiple SDI applications. However, to achieve the affect you are after, I would normally create the item you call NewWindow as a UserControl - and then I would make it a child of the MainWindow, stacked below the RibbonControl.
|
|
|
|
|
Dear Pete O'Hanlon
Thank you very much for the replying to my query. Very Sure it is MDI appliaction. In Windows form application we can do this by simply making an MDI application. As i have to display The windows based on the choices made by the User.I.e Find a record,Add,Update,Delete etc. So we have to display each window for each specific task and all the windows should have ChildWindow(top,left) just at the intersection of Ribbons(bottom.left).
Can i do this manually.If Yes how?
Thanks.
|
|
|
|