|
Have you tried using Prism V2 (CompositeWPF)? There is a TabRegaion Adapter that you can use.
Thanks and Regards,
Michael Sync ( Blog: http://michaelsync.net)
Microsoft MVP (Silverlight), WPF/Silverlight Insiders
|
|
|
|
|
Hi,
I am creating a Windows application (WPF) and C#. In my view, I have to add few layouts like browsing a folder, displaying the files in the folder in a list view...etc
My requirement is :
The panels mentioned above should be collapsible panels, I guess, we dont have option of collapsible panel in wpf.
I have to create a custom control for this? If so, Please suggest me how to do this?
Thank You,
Ramm
|
|
|
|
|
You could always use an Expander.
<Expander Header="Folders" IsExpanded="false">
..
</Expander>
"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
|
|
|
|
|
Is there a way to have the expander bump other elements out of the way? for instance if your collapsed expander is next to a list view, can you move the listview over when you expand? probably not possible but thought id ask
|
|
|
|
|
Hi everybody.
Could we use UDP protocol in WCF ?
Thanks.
|
|
|
|
|
If only there existed some mechanism for searching for information on the internet based on keywords. Why, this invention could make somebody very rich indeed. Clickety[^]
"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
|
|
|
|
|
Hi
I'm using a wcf service to get the data from the database and bind it silverlight control. And below is the code sample that i've written.
Problem here is WCF service that i've created is on basichttpbinding. Silverlight supports only this binding I think. So I changed the end point in my WCF service from default (wsHTTPbining ) to basic. when i add the service reference to the silverlight application the following is the silverlight clientconfig I'm getting with the error that i got when i build the application.
<configuration>
<system.serviceModel>
<bindings>
<basicHttpBinding>
<binding name="BasicHttpBinding_ITestWCF" maxBufferSize="2147483647"
maxReceivedMessageSize="2147483647">
<security mode="None" />
</binding>
</basicHttpBinding>
</bindings>
<client>
<endpoint address="http://localhost:8731/TestWCFLib/basic" binding="basicHttpBinding"
bindingConfiguration="BasicHttpBinding_ITestWCF" contract="testService.ITestWCF"
name="BasicHttpBinding_ITestWCF" />
</client>
</system.serviceModel>
</configuration>
Unhandled Error in Silverlight 2 Application An exception occurred during the operation, making the result invalid. Check InnerException for exception details. at System.ComponentModel.AsyncCompletedEventArgs.RaiseExceptionIfNecessary() at MNetMetricSystem.testService.GetBugCountCompletedEventArgs.get_Result() at MNetMetricSystem.OrganizationBaseLine.obj_GetBugCountCompleted(Object sender, GetBugCountCompletedEventArgs e) at MNetMetricSystem.testService.TestWCFClient.OnGetBugCountCompleted(Object state)
public partial class OrganizationBaseLine : UserControl
2 {
3 ServiceReference1.MNetMetricsServiceClient Metrics = new MNetMetricSystem.ServiceReference1.MNetMetricsServiceClient();
4 public OrganizationBaseLine()
5 {
6 InitializeComponent();
7 Loaded += new RoutedEventHandler(OrganizationBaseLine_Loaded);
8 }
9
10 void OrganizationBaseLine_Loaded(object sender, RoutedEventArgs e)
11 {
12
13 Metrics.GetAllDepartmentsCompleted += new EventHandler(Metrics_GetAllDepartmentsCompleted);
14 Metrics.GetAllDepartmentsAsync();
15
16 }
17
18 void Metrics_GetAllDepartmentsCompleted(object sender, MNetMetricSystem.ServiceReference1.GetAllDepartmentsCompletedEventArgs e)
19 {
20 cmdDepartMent.ItemsSource = e.Result;
21 }
22
23 }
24
25 This is the Service class from Interface
26
27 public class MNetMetricsService : IMNetMetricsService
28 {
29
30 DLMetrics objMetrics = new DLMetrics();
31
32 List mlist = new List();
33
34 List IMNetMetricsService.GetAllDepartments()
35 {
36
37 DataTable dt = objMetrics.DLGetAllDepartments();
38
39 mlist.Add(new MYList() { MyTable=dt});
40
41 return mlist;// List That i've return at the Silverlight application
42 }
43 }
I didn't use any LINQ to SQL to retrieve data from the database. Without LINQ is it possible? If possible what is the solution? Pls give some links on this......
|
|
|
|
|
I'm missing something here....where is the problem?
Is this a WCF problem or a database access problem?
You showed WCF configuration....is that from the client side or the server side?
What does the other end's configuration look like?
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
Thanks Mark for the reply.
Problem is while adding service reference to the silverlight application in ServiceReference.ClientConfig file it shows the end points properly. That means no problem with WCF Service. In the WCFTESTCLIENT also I tested, It works very well.
But when I bind the service method in the pageloading event to a silverlight combobox control, It is showing the following error.....
Unhandled Error in Silverlight 2 Application An exception occurred during the operation, making the result invalid. Check InnerException for exception details. at System.ComponentModel.AsyncCompletedEventArgs.RaiseExceptionIfNecessary() at MNetMetricSystem.Metrics.GetAllDepartmentsCompletedEventArgs.get_Result() at MNetMetricSystem.OrganizationBaseLine.Met_GetAllDepartmentsCompleted(Object sender, GetAllDepartmentsCompletedEventArgs e) at MNetMetricSystem.Metrics.MNetMetricsServiceClient.OnGetAllDepartmentsCompleted(Object state)
|
|
|
|
|
I can only guess with the given information.
Looks like you need to debug your server so you can get more meaningful
exception info. WHERE the exception is occurring would be helpful too.
The exception message you posted mentions checking the inner exception...
what's there?
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
Are you using DataTable? (From the looks of it your WCF returns DataTable)
Silverlight does not support DataSet and DataTable, therefore your WCF has to return the result as an ICollection, e.g. List, ArrayList.
Edbert
Sydney, Australia
|
|
|
|
|
Thanks for the reply Ebert,
I returned list only from the wcf service. Is there any alternative way to get data from the database without WCF service?
Ravi Vellanki,
AP,India.
|
|
|
|
|
Is there something special I have to do to get the direction arrows to show up in the DataGrid that comes with the WPFToolkit? The columns sort okay, but I don't get any direction arrows...
"Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997 ----- "...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001
|
|
|
|
|
John,
The arrows will always show after the column header is clicked.
To get them to show on form open, in your XAML set the SortDirection property.
<toolkit:DataGridTextColumn Binding="{Binding FirstName}" SortDirection="Descending" Header="First Name" />
modified 27-Feb-21 21:01pm.
|
|
|
|
|
I'm observing significant scrolling/sorting performance problems with a RadGridView object, and I wanted to try manually populating the grid instead of using data binding to see if that would solve the issue. However, I'm stuck.
Exactly how would I go about adding the rows from the dataset to the Items collection in the grid? I tried this:
dataGridRad.Items.Add(dt.Rows[rowNumb]);
but I get no rows in the grid.
"Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997 ----- "...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001
|
|
|
|
|
I suspect you have to follow the steps laid out here[^].
"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
|
|
|
|
|
Hi
When the button is clicked it changes to another page (UserControl), but
if they click the button fast a couple of times it crashes. That is because the service isn't finished with getting data from the database, which the other pages need. I don't want to use IsEnabled=false, is there another way?
Thanks
Fia
|
|
|
|
|
Why do you not want to do IsEnabled=false? An alternative could be to set a flag when you click the button the first time and reset it when the service has finished getting data; then it wouldn't matter whether or not the user multipresses the button, you won't make the call until the flag says it's okay to do so.
"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
|
|
|
|
|
Hi Thanks for your reply
But it doesn't work with IsEnabled, I use that button to navigate to a different page, and the button is the same for every page. In one page the user writes the his username and password. If It's right I get the data from that user and move on to a different page when that button is clicked. In another page the users can choose someting from a combobox, when that is choosen and the button is clicked, the data is fetched regarding what was choosen in the combobox. I tried to use IsEndabled=false, but if the user clicks several times, it navigates several pages. It seems like the the button clicks are saved and when the button's IsEnabled=true, it moves the count that the button was clicked.
Please help
Fia
|
|
|
|
|
You could always change it's visibility so that it can't be clicked, and only make it visible when it's the right time to do so.
"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
|
|
|
|
|
Easiest way is just to mask the button. Put a rectangle in the same container that is the width/height of the button and make it transparent. When inside grids, etc, order matters - the rectangle should be represented AFTER the button so it is in the foreground. By default, set the visibility to collapsed. When the user clicks, set it to visible until you are done initializing, then collapse it again. It will mask any clicks or UI events but not fudge the UI.
<Grid>
<Button/>
<Rectangle Fill="Transparent"/>
</StackPanel>
<div class="ForumSig">Jeremy Likness
Latest Article: <a href="http://www.codeproject.com/KB/cs/Collections_Part_1.aspx">Whats in Your Collection? Part 1 of 3: Interfaces</a>
Blog: <a href="http://csharperimage.jeremylikness.com/" target="_blank" title="CSharper Image">C#er : IMage</a></div>
|
|
|
|
|
Does anyone know how to do this? I've looked on every website i could possibly think of and still haven't found what I'm looking for. Basically this is what i want to do/accomplish:
1. I have a pretty big project(around 70k lines ) that I'm trying to add a universal ribbon bar to the top of, each app being able to click through the tabs to get to the common functionality that will be available to that app
2. I have already created the ribbon(thanks to the walkthroughs of uxpassion.com ) that has a nice look and feel for what i want, but it is a WPF application(per the walkthrough) with XAML and a .cs file for all the method calls and functionality the XAML and ribbon require to work
3. I would like to know(if it's possible because i haven't found it anywhere on the web ) if i can use what i have now for my ribbon bar(code and all) and somehow place it at the top of all my different projects' pages so as to have the 2007 Office look no matter what you're looking at
I know this may be a noobie question that i just have overlooked or missed somewhere, but I would really appreciate anything that could help me acheive this(kind of on a deadline) so that my project will look professional
Thanks in advance!
|
|
|
|
|
I'm a bit confused as to what you're actually asking. Are you asking whether you can host none-WPF windows inside the application so that they appear to be running inside a ribbon enabled WPF application? If you are, then yes you can - as long as you add the WindowsFormsIntegration and System.Windows.Forms assemblies as in the following:
<Window x:Class="WpfForm.Window1"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:wfi="clr-namespace:System.Windows.Forms.Integration;assembly=WindowsFormsIntegration"
xmlns:wf="clr-namespace:System.Windows.Forms;assembly=System.Windows.Forms"
xmlns:myForm="clr-namespace:MyFormsNamespace;assembly=MyFormsApp"
Title="Host in WPF" Height="400" Width="300"
>
<Grid>
<wfi:WindowsFormsHost>
<myForm:MyWindowForm />
</wfi:WindowsFormsHost>
</Grid>
</Window> In this sample, you can see that I've added the windows form inside the WindowsFormsHost .
"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
|
|
|
|
|
Thanks Peter for your reply, but I'm guessing that when you said "host none-WPF windows" you meant NON-WPF windows, and the answer is no. All of the projects that have been coded already are in WPF(with a c# back code), and what I would like to do is have a ribbon bar(which I've already created as a WPF application per uxpassion.com) at the top of each of my apps as to give the Office 2007 impression and functionality but with my own code of course I have it set up right now in my ribbon for taking the functions to call from each app, but I haven't got the ribbon to act as a resource ontop of each app's GUI. Does this make sense or clear what I would like to do? Thanks again
|
|
|
|
|
trey white wrote: host none-WPF windows" you meant NON-WPF windows, and the answer is no
No - I meant the UK English language version which is none. The simplest way to achieve what you want is to implement the other applications as user controls.
"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
|
|
|
|