Solved

WPF Application and WPF Browser app

Posted on 2010-08-20
9
499 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

Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

Question has a verified solution.

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

Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
Whether you've completed a degree in computer sciences or you're a self-taught programmer, writing your first lines of code in the real world is always a challenge. Here are some of the most common pitfalls for new programmers.
An introduction to basic programming syntax in Java by creating a simple program. Viewers can follow the tutorial as they create their first class in Java. Definitions and explanations about each element are given to help prepare viewers for future …
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 …

770 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