no overload for method takes 2 arguments
CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3

Thread: no overload for method takes 2 arguments

  1. #1
    Join Date
    Mar 2014
    Posts
    3

    no overload for method takes 2 arguments

    I tested Navision webservices with WebFormAppi But....
    Error on this line (no overload for method takes 2 arguments) : label1.Text = MyGlavaImport.ImportGlavaNew(ref, MyRoothElement);

    Thanks for help

    Code:

    using System;
    using System.Collections.Generic;
    using System.ComponentModel;
    using System.Data;
    using System.Drawing;
    using System.Linq;
    using System.Text;
    using System.Windows.Forms;

    namespace MyTestNet
    {
    public partial class Form1 : Form
    {
    public Form1()
    {
    InitializeComponent();
    }

    private void button1_Click(object sender, EventArgs e)
    {
    string[] strArray = new string[1] { "kkk"};
    ImportGlavaCU.MyImportGlava MyGlavaImport = new ImportGlavaCU.MyImportGlava();
    MyGlavaImport.UseDefaultCredentials = true;
    MyGlavaImport.Url = "http://win2003navision:7047/DynamicsNAV/ws/Codeunit/MyImportGlava";
    ImportGlavaCU.RooetElement MyRoothElement = new ImportGlavaCU.RooetElement();
    List<ImportGlavaCU.GlavaTabelaElement> GLLIST = new List<ImportGlavaCU.GlavaTabelaElement>();
    ImportGlavaCU.GlavaTabelaElement GlavaHE = new ImportGlavaCU.GlavaTabelaElement();
    GlavaHE.GlavaPoljefield = strArray[0];
    GLLIST.Add(GlavaHE);
    MyRoothElement.GlavaTabelaElement = GLLIST.ToArray();

    try
    {
    label1.Text = MyGlavaImport.ImportGlavaNew(ref, MyRoothElement);



    }
    catch (Exception ex)
    {
    label1.Text = ex.ToString();
    }
    }
    }
    }

  2. #2
    Arjay's Avatar
    Arjay is offline Moderator / MS MVP Power Poster
    Join Date
    Aug 2004
    Posts
    11,359

    Re: no overload for method takes 2 arguments

    It depends on how ImportGlavaNew(...) is defined but most likely you meant to type...
    Code:
    MyGlavaImport.ImportGlavaNew(ref MyRoothElement);

  3. #3
    Join Date
    Mar 2014
    Posts
    3

    Re: no overload for method takes 2 arguments

    Thanks - works

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Windows Mobile Development Center


Click Here to Expand Forum to Full Width

This is a CodeGuru survey question.


Featured


HTML5 Development Center