Solved

WPF Application and WPF Browser app

Posted on 2010-08-20
9
502 Views
Last Modified: 2013-11-27
Hi Experts,
I am getting into WPF but are struggling with databinding from dataset to WPF designer as follows;
When I drag & drop a datset from datasources onto the grid (WPF application project) all code is  generated correctly, XAML and code behind and data is displayed correctly when you run the app.
When I do the same using WPF browser app, the XAML is created correctly but with no code behind. When you run it, the controls are displayed in the browser but no data.
If I use similar code behind (for the connection string, etc.) as was generated in the WPF windows app (that works) the same result. Controls are displayed but no data
What am I missing?
Please help!
I am using Visual Studio 2010 (VB)
0
Comment
Question by:esps
  • 3
9 Comments
 
LVL 29

Expert Comment

by:Gautham Janardhan
ID: 33652672
Its probably a permissions or trust issue..There were so many things that you couldnt do because of trust problems.. How are you getting the data from your SQL database to the dataset in the XBAP, is it passed through a web service or WCF service or something like that or are you just trying to directly pull data from SQL in the XBAP?..
0
 
LVL 29

Expert Comment

by:Gautham Janardhan
ID: 33652675
To add to that, i would use the dataset so generously in the WPF/Silver light world.. i would rather retrieve the data from SQL as objects(though EF or using some ORM) which is way more easier to handle w.r.t binding to the controls.
0
 

Author Comment

by:esps
ID: 33688770
Being new to WPF, I will use any method to get data from SQL and to be able to have the data available as a dataset or any other metod that I can link the data fields to text boxes, etc.
Would appreciate some guidelines and/or code snippet.
In your previous post you mentioned sQL as object(through EF or using some ORM) would you please give more detail
regards
0
 
LVL 29

Accepted Solution

by:
Gautham Janardhan earned 500 total points
ID: 33689031
this would be a best place to start with if you are using EF (which i would recommend)

http://msdn.microsoft.com/en-us/library/bb896242.aspx
0

Featured Post

Space-Age Communications Transitions to DevOps

ViaSat, a global provider of satellite and wireless communications, securely connects businesses, governments, and organizations to the Internet. Learn how ViaSat’s Network Solutions Engineer, drove the transition from a traditional network support to a DevOps-centric model.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
Although it can be difficult to imagine, someday your child will have a career of his or her own. He or she will likely start a family, buy a home and start having their own children. So, while being a kid is still extremely important, it’s also …
In this fifth video of the Xpdf series, we discuss and demonstrate the PDFdetach utility, which is able to list and, more importantly, extract attachments that are embedded in PDF files. It does this via a command line interface, making it suitable …

733 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question