mibuso.com

Microsoft Business Solutions online community
It is currently Tue May 21, 2013 9:08 pm

All times are UTC + 1 hour [ DST ]




Post new topic Reply to topic  [ 3 posts ] 
Author Message
 Post subject: [Solved] WebServices: where to update data in asp.net page
PostPosted: Fri Jun 08, 2012 2:19 pm 
Offline

Joined: Thu Dec 15, 2011 9:41 am
Posts: 31
Country: Spain (es)
Hello. I'm starting with web services and I'm facing a problem I can't solve or find documentation anywhere.

I'm developing a web page and showing a Job Card. I want the users to update data, and I want data to be saved in Nav database, but I don't know how to do it. I'm using TextBox to show the fields, and I've tried the Update method from the WebService with fixed values, but I don't know where I have to execute this Update method, because when I call it, the data has disappeared because of the PostBack. I've even tried with CustomValidators, but I don't get any positive result.

I've also search for help on the internet but I can't find an example for doing that, and I think it has to be some easy way to do that but it's only I can't find it.

Where should I put the Update?


Last edited by Goyo on Sat Jun 09, 2012 7:53 pm, edited 1 time in total.

Top
 Profile E-mail  
 
 Post subject: Re: WebServices: where to update data in asp.net page
PostPosted: Fri Jun 08, 2012 3:46 pm 
Offline

Joined: Thu Feb 12, 2009 9:22 am
Posts: 251
Country: Singapore (sg)
Hi Goyo,

I think your problem is not related with NAV Ws. :)

Quote:
I've tried the Update method from the WebService with fixed values, but I don't know where I have to execute this Update method, because when I call it, the data has disappeared because of the PostBack.


It depend on you. Because of when you want to update back to nav. Eg. Button Click Event, textbox chaged Event.
Here is example.

Code: Select all
aspx

<asp:TextBox ID="txt" runat="server" EnableViewState="false" AutoPostBack="true"
            ontextchanged="txt_TextChanged"></asp:TextBox>
    <asp:Button ID="btn" runat="server" Text="Btn" onclick="btn_Click" />

CB
protected void btn_Click(object sender, EventArgs e)
    {
        //Do something for WS
        Response.Write(txt.Text);
    }
    protected void txt_TextChanged(object sender, EventArgs e)
    {
        //Do something for WS
    }



You can find with this word in Google "asp.net sample projects with source code"

WS Example
http://blogs.msdn.com/b/freddyk/

Asp.net
http://forums.asp.net/

Best Regards,
Yukon

_________________
Make Simple & Easy


Top
 Profile E-mail  
 
 Post subject: Re: WebServices: where to update data in asp.net page
PostPosted: Sat Jun 09, 2012 7:52 pm 
Offline

Joined: Thu Dec 15, 2011 9:41 am
Posts: 31
Country: Spain (es)
Thank you so much for your help. With AutoPostback and OnTextChanged it finally works \:D/ . Despite all my efforts looking for a way to do that, I haven't found anything until your help. It has been very frustrating not finding anything about anything that I supossed was so common ](*,) . Thanks again.


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

All times are UTC + 1 hour [ DST ]


Who is online

Users browsing this forum: No registered users and 11 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: