mibuso.com

Microsoft Business Solutions online community
It is currently Thu May 23, 2013 6:48 am

All times are UTC + 1 hour [ DST ]




Post new topic Reply to topic  [ 11 posts ] 
Author Message
 Post subject: Retrieving specified fields from NAV tables using Web Servic
PostPosted: Wed Feb 18, 2009 3:51 pm 
Offline

Joined: Tue Jul 29, 2008 11:36 am
Posts: 19
Location: HYD
Country: India (in)
Hi everyone,

Using web services, I am displaying Customer (accessing NAV data) details in ASP.Net application using GridView control. Here problem is I don’t want to display all fields from Customer table. I can put filters on customer data. But, I am unable to retrieve specified fields from customer table.
Can anyone tell the solution for this issue?
Code: Select all
protected void Button1_Click(object sender, EventArgs e)
    {
        CustWS.CustomerPage_Service CustServices = new CustomerPage_Service();
        CustServices.UseDefaultCredentials = true;
        CustServices.Url = "http://b2bxpprof247:7047/DynamicsNAV/WS/CRONUS_India_Ltd./Page/CustomerPage";
        CustWS.CustomerPage CustRec = new CustomerPage();

        List<CustomerPage_Filter> filterArray = new List<CustomerPage_Filter>();
        CustomerPage_Filter CustFilter = new CustomerPage_Filter();
        CustFilter.Field = CustomerPage_Fields.Name;
        CustFilter.Criteria = "@s*";
        filterArray.Add(CustFilter);
        GridView1.DataSource = CustServices.ReadMultiple(filterArray.ToArray(), null, 100);
        GridView1.DataBind();

    }

_________________
Shiv


Top
 Profile  
 
 Post subject: Re: Retrieving specified fields from NAV tables using Web Servic
PostPosted: Wed Feb 18, 2009 4:35 pm 
Offline
MVP Microsoft Dynamics NAV

Joined: Wed Dec 15, 2004 6:11 pm
Posts: 8700
Location: 3rd rock from sun
Country: United States (us)
Oops Never mind.

_________________
Rashed.

blog: http://mibuso.com/blogs/ara3n/


Top
 Profile  
 
 Post subject: Re: Retrieving specified fields from NAV tables using Web Servic
PostPosted: Wed Feb 18, 2009 7:08 pm 
Offline
MVP Microsoft Dynamics NAV
NAV TechDays 2013 attendee

Joined: Thu Oct 16, 2003 8:50 am
Posts: 12265
Location: Brno
Country: Czech Republic (cz)
If you mean something like "dynamic" WebService which will return you just somehow selected fields, you will need to use some codeunit and programming. You cannot do it only by publishing page.

_________________
Kamil Sacek
MVP - Dynamics NAV
My BLOG
NAVERTICA a.s.


Top
 Profile E-mail WWW  
 
 Post subject: Re: Retrieving specified fields from NAV tables using Web Servic
PostPosted: Wed Feb 18, 2009 7:42 pm 
Offline
MVP Microsoft Dynamics NAV

Joined: Wed Dec 15, 2004 6:11 pm
Posts: 8700
Location: 3rd rock from sun
Country: United States (us)
Have you tried to create a new page with only the fields you want to display.

_________________
Rashed.

blog: http://mibuso.com/blogs/ara3n/


Top
 Profile  
 
 Post subject: Re: Retrieving specified fields from NAV tables using Web Servic
PostPosted: Thu Feb 19, 2009 7:03 am 
Offline

Joined: Tue Jul 29, 2008 11:36 am
Posts: 19
Location: HYD
Country: India (in)
Thanks for ur replay,
I'll work on this.

_________________
Shiv


Top
 Profile  
 
 Post subject: Re: Retrieving specified fields from NAV tables using Web Servic
PostPosted: Thu Feb 19, 2009 12:16 pm 
Offline

Joined: Tue Jul 29, 2008 11:36 am
Posts: 19
Location: HYD
Country: India (in)
Hi Rashed,
I have created one page with specified fields from customer table. By using this page am getting the same fields in my application but, still one unknown key it’s displaying.
How can I restrict this?

_________________
Shiv


Top
 Profile  
 
 Post subject: Re: Retrieving specified fields from NAV tables using Web Servic
PostPosted: Thu Feb 19, 2009 1:29 pm 
Offline
MVP Microsoft Dynamics NAV
NAV TechDays 2013 attendee

Joined: Thu Oct 16, 2003 8:50 am
Posts: 12265
Location: Brno
Country: Czech Republic (cz)
Quote:
still one unknown key


??? Can you be more specific?

_________________
Kamil Sacek
MVP - Dynamics NAV
My BLOG
NAVERTICA a.s.


Top
 Profile E-mail WWW  
 
 Post subject: Re: Retrieving specified fields from NAV tables using Web Servic
PostPosted: Fri Feb 20, 2009 6:14 am 
Offline

Joined: Tue Jul 29, 2008 11:36 am
Posts: 19
Location: HYD
Country: India (in)
What I feel, this key (Unique identifier) is might be generating by Web service for getting current record from NAV database.

The key is like : 300;EgAAAACJDAxEyAAAAAAAAAAAAAAAAA……….AAAAAAAAAA=4;49920

_________________
Shiv


Top
 Profile  
 
 Post subject: Re: Retrieving specified fields from NAV tables using Web Servic
PostPosted: Fri Feb 20, 2009 7:26 am 
Offline
MVP Microsoft Dynamics NAV
NAV TechDays 2013 attendee

Joined: Thu Oct 16, 2003 8:50 am
Posts: 12265
Location: Brno
Country: Czech Republic (cz)
Yes, it is. This key must be part of the dataset to be able to identify the record...

_________________
Kamil Sacek
MVP - Dynamics NAV
My BLOG
NAVERTICA a.s.


Top
 Profile E-mail WWW  
 
 Post subject: Re: Retrieving specified fields from NAV tables using Web Servic
PostPosted: Fri Feb 20, 2009 8:41 am 
Offline

Joined: Tue Jul 29, 2008 11:36 am
Posts: 19
Location: HYD
Country: India (in)
Then, how can I display the data with out this key in Web Page?
any suggestions?

_________________
Shiv


Top
 Profile  
 
 Post subject: Re: Retrieving specified fields from NAV tables using Web Servic
PostPosted: Fri Feb 20, 2009 9:25 am 
Offline
MVP Microsoft Dynamics NAV
NAV TechDays 2013 attendee

Joined: Thu Oct 16, 2003 8:50 am
Posts: 12265
Location: Brno
Country: Czech Republic (cz)
Define which columns you want to dsiplay, displaying all data you read is not the correct way for any web application...

_________________
Kamil Sacek
MVP - Dynamics NAV
My BLOG
NAVERTICA a.s.


Top
 Profile E-mail WWW  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 11 posts ] 

All times are UTC + 1 hour [ DST ]


Who is online

Users browsing this forum: No registered users and 4 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum


Search for:
Jump to: