.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Register
 
Win Surprise Gifts!!!
Congratulations!!!


Post New Web Links

Consume WCF Data service in client application

Posted By:      Posted Date: September 07, 2010    Points: 0   Category :ASP.Net
 
Hi All, I am working on WCF Data service which imported stored procedure, as below.         [WebGet]        public List<GetMTSearchResultTest_Result> GettMTSearchResultTest()        {            MediaMarketResearch_PRODEntities ent = new MediaMarketResearch_PRODEntities();            return ent.GetMTSearchResultTest().ToList();        } when i consuming this in my client application it says error as "The closed type MMRClient.MMRServiceReference.GetMTSearchResultTest_Result does not have a corresponding element settable property." I am getting this error while bind to the grid view as below. DataServiceContext context = new DataServiceContext(new Uri("http://localhost:4131/MMRDataService.svc/"));IEnumerable<GetMTSearchResultTest_Result> empResult = context.Execute<GetMTSearchResultTest_Result>(new Uri("http://localhost:4131/MMRDataService.svc/GettMTSearchResultTest"));             GridView1.DataSource = empResult;            GridView1.DataBind(); Note: I imported this sto


View Complete Post


More Related Resource Links

Consume WCF Data service in client application throws error

  
Hi All, I am working on WCF Data service which imported stored procedure, as below.         [WebGet]         public List<GetMTSearchResultTest_Result> GettMTSearchResultTest()         {             MediaMarketResearch_PRODEntities ent = new MediaMarketResearch_PRODEntities();             return ent.GetMTSearchResultTest().ToList();         }   when i consuming this in my client application it says error as "The closed type MMRClient.MMRServiceReference.GetMTSearchResultTest_Result does not have a corresponding element settable property." I am getting this error while bind to the grid view as below. DataServiceContext context = new DataServiceContext(new Uri("http://localhost:4131/MMRDataService.svc/")); IEnumerable<GetMTSearchResultTest_Result> empResult = context.Execute<GetMTSearchResultTest_Result>(new Uri("http://localhost:4131/MMRDataService.svc/GettMTSearchResultTest"));             GridView1.DataSource = empResult;             GridView1.DataBind(); Note: I im

Consume WCF Data service in client application throws error

  
Hi All, I am working on WCF Data service which imported stored procedure, as below.         [WebGet]         public List<GetMTSearchResultTest_Result> GettMTSearchResultTest()         {             MediaMarketResearch_PRODEntities ent = new MediaMarketResearch_PRODEntities();             return ent.GetMTSearchResultTest().ToList();         }   when i consuming this in my client application it says error as "The closed type MMRClient.MMRServiceReference.GetMTSearchResultTest_Result does not have a corresponding element settable property." I am getting this error while bind to the grid view as below. DataServiceContext context = new DataServiceContext(new Uri("http://localhost:4131/MMRDataService.svc/")); IEnumerable<GetMTSearchResultTest_Result> empResult = context.Execute<GetMTSearchResultTest_Result>(new Uri("http://localhost:4131/MMRDataService.svc/GettMTSearchResultTest"));             GridView1.DataSource = empResult;             GridView1.DataBind(); Note: I im

Need to create a service to allow client application to update their data

  

Hi,

I want to create a  WCF Service to transfer data to our clients application(WPF).

The Data I am trying to send is as follows.

ID  Code          Description   unit    Rate

1   104200000   LIVE GOAT      NOS     25

2   104200000   LIVE GOAT2    NOS    25

3   104200030   LIVE GOAT3    KGS     10

4   104202030   Water             LTR      5

and so on till ~ 11000 records.

What I have done so far is. Created a service which return a list of data.

-----------

 public List<Classes.TariffData> GetTariffData()
{
var currentTariffData = new List<Classes.TariffData>();

using (var myConnection = new SqlConnection(ConfigurationManager.ConnectionStrings["ConnectionString"].ConnectionString))
{
const string query = "select a.ID,a.Code,a.Description,a.unit,a.rate,a.rate3 from tariff.dbo.tariffdata a, tariff.dbo.code_history b where a.id = b.id and b.endofvalidity is null";
using (var myCommand = new Sq

How to Consume WCF service In My CLient Application After Installing the WCF service at Production E

  

Hi,

 I ahve created the WCF service and Client Application To consume that Service and Everything Tested and working perfectly.

But to Giv that Application to the Client we have give the 2 Installer

1)Server Instller(WCF  Service Installer)

2) Client Installer having Some forms and Logic to consume WCF service.

 

My question is that..

While Installing the Service(WCF) service at production evnironment if they gives some name.

How my client Application Knows that Service?Is there any way to do that

Please Help me

--Regards,

Amar


Thanks&Regards, -Amar.

User Profiles Service Application and Import of SharePoint 2007 SSP data

  
I have setup a test SharePoint 2010 Farm. I will be using this as a test upgrade of a current live SharePoint 2007 Farm. The database attach method will be used. I have replicated the web application and AAM settings of the SharePoint 2007 Farm to the SharePoint 2010 Farm and have made the 2010 Farm a DC in a new Forest. I don't want to join this to the current domain at the moment. It also has SQL server 2005 with SP3 and cumulative update 3 installed. I have just setup the User Profiles Serice Application and when I go to Manage it, I get this. Error An unexpected error has occurred.   Troubleshoot issues with Microsoft SharePoint Foundation. Correlation ID: a1760e87-372f-4711-afac-3ceba34bc599 Date and Time: 8/31/2010 4:22:56 PM I have verified and configured the following. Created the Managed Metadata Service. The status is started via Service Applications and Services on Server. Created the User Profiles Service Application and ensured status is started via Service Applications. I started the User Profile Service and User Profile Synchronisation Service via Manage Services on Server.      

Error selecting "Business Data Connectivity" service application in MSS 2010 with WCF hotfix on W8R

  
I'm getting "BDC Metadata Store is Currently Unavailable" when navigating to the External Content Types object in SPD 2010. Hot fix is installed.  No errors in the eventlog? 

Client Application Services - Role service cache time out bug

  
Hi All, For people using Client Application Services with WPF, be aware of this bug. You can configure the "cache time out" for roles to be fetched again from the service. (In the visual studio dialog, Properties -> Services -> Advanced) This means the roles are cached on the client (in a file). If the application asks for roles again, they are not fetched again for "cache time out" time. When you set this value, it goes into your App.config, transformed into seconds. So if you choose 1 minute, the App.config has: cacheTimeout="60".   However, when using the ClientRoleProvider (for instance to do something like clientRoleProvider.GetRolesForUser("SomeUser")), this cacheTimeOut is interpreted in Minutes, not seconds! To prove my point, check ClientRoleProvider.Initialize method:   string temp = config["cacheTimeout"]; if (!string.IsNullOrEmpty(temp)) _CacheTimeout = int.Parse(temp, CultureInfo.InvariantCulture);   Later on, in ClientRoleProvider.GetRolesFromDBUser (what's in a name?), you see: _CacheExpiryDate = cd.RolesCachedDateUtc.AddMinutes(_CacheTimeout);   Testing also shows this behavior. So be aware, and always put the value in minutes in your App.Config!   Regards, Koen

consuming wcf Data service in different format in client - SOAP (including a WDSL), XML, JSON, etc.

  
Hi I have implemented wcf data service with entity framework with the following steps, i want to know i can we consume this WCF Data service in different format like (SOAP, JSON, XML, PLIST). it will be helpfull if some one help on this. - Created web application with VS2010 and added edmx file and selected tables,views and SPs that i want to use - imported SP with complex type by using function import. - Created WcfDataservice (.svc File). - in SVC File i have added [webget] method as follows.         [WebGet]        public List<GetSearchResultWithComplextype_Result> GetSearchResultComplextype(string email, string Title, string Color)        {            Entities db = new Entities();            var query = db.GetSearchResultWithComplextype(email, Title, Color);            List<GetSearchResultWithComplextype_Result> caseList = query.ToList<GetSearchResultWithComplextype_Result>();            return caseList;        } - created one more client application and added service reference. here i want to cons

consuming wcf Data service in different format in client - SOAP (including a WDSL), XML, JSON, etc.

  
Hi  I have implemented wcf data service with entity framework with the following steps, i want to know i can we consume this WCF Data service in different format like (SOAP, JSON, XML, PLIST). it will be helpfull if some one help on this. - Created web application with VS2010 and added edmx file and selected tables,views and SPs that i want to use - imported SP with complex type by using function import. - Created WcfDataservice (.svc File). - in SVC File i have added [webget] method as follows.         [WebGet]         public List<GetSearchResultWithComplextype_Result> GetSearchResultComplextype(string email, string Title, string Color)         {             Entities db = new Entities();             var query = db.GetSearchResultWithComplextype(email, Title, Color);             List<GetSearchResultWithComplextype_Result> caseList = query.ToList<GetSearchResultWithComplextype_Result>();             return caseList;         } - created one more client application and added service reference. here i wan

Can sharepoint desinger consume wcf data service?

  

I am thinking to change my wcf data service based on ado.net data service because It seems that sharepoint designer does not understand.

I can use VS 2010 to develop it external list but I just want my clients to use sharepoint designer to do themself so I can only take care of the service

However If I do not use wcf data service, it look like that I have to do a lot of coding for the service itself

Could anyone please tell me how to use sharepoint designer to talk to the wcf data service, or other alternative approach?

Thank you in advance

 


Consume WCF Service Host from client thru WAN.

  

i try to host a wcf service thru console by giving the external ip in uri for client consume it as endpoint, but i had this error :

Could not connect to http://115.133.x.x:8000/GetMsg/GetMsgC. TCP error code 10060: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond 115.133.x.x:8000.


Host 

static void Main(string[] args)
        {
            using (host = new ServiceHost(typeof(GetMsgC), new Uri("http://115.133.x.x:8000/GetMsg")))
            {
                host.AddServiceEndpoint(typeof(IGetMsg), new BasicHttpBinding(), "GetMsgC");
                host.Open();

                Console.WriteLi

Consume the Siebel On Demand web service in .Net console application.

  

Hi,

I have Siebel On demand web service wsdl, I want to consume Siebel OD web service in my .Net console application.

I want to update Siebel On Demand picklist(Table) from .Net client

I can implement this from below 2 ways.

1. Add web reference and VS will automatically create proxy class.

2. Dynamically create input soap message and pass soap message across with help web service extension’s webrequest and webresponse methods.

Please advice which one of above process will be good in performance, scalability of client, lightness of invocation of web service.

 And also let me know other way for performance enhance

Client Application Service

  

 

Hi,

we are in the process of architecting a security framework for our applications and we are looking at the Client Application Services availbale i .NET.

 

If I decide to use the ASPNETSQLMemebrshiprovider would i be able to use a single application service for all my applications.

 

if so when an application uses the the application service to authenticate how will it identofy which applicatio to authenticate against.

 

Any suggestions will be grealty appreciated.

 

Jothi

 


Return ReadOnlyCollection from WCF service and use it in Silverlight 3 client application

  
Hi all!

I have a solution containing of 3 parts: wcf service, wpf app and silverlight 3 app.
Both wpf app and silverlight app use wcf service to get a collection of objects.

The point is that my business requirements insistently tell me to return ReadOnlyCollection<T> from wcf service.
When I try to do it I have Serialization exception in silverlight client app. But it's ok in wpf app.

Then, I haven't started the investigation for such strange thing (different behavior in wpf and silverlight) and decided to implement custom serialization, returning the ICollection interface and trying to get ReadOnlyCollection on deserializing.  But wcf service proxy class in silverlight app returned Array of T, not ReadOnlyCollection<T> as proxy in wpf did.


So, the question is: Is it possible to return ReadOnlyCollection<T> from WCF service?



Any help is appreciate.

Thanks,
Dmitry
Categories: 
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend