Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / New Users / December 2005

Tip: Looking for answers? Try searching our database.

The parameter is incorrect error

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
radha0809@gmail.com - 28 Dec 2005 17:47 GMT
I have a VB6 COM object. The COM object is working fine when I use it
in VB.net. But when I use the same code in ASP.net 1.1 I am getting
"The parameter is incorrect" error.
I have the AspCompat="True" on my web page. Any help on this would be
appreciated.

Thanks in Advance
Anu
Rob Schieber - 28 Dec 2005 18:18 GMT
> I have a VB6 COM object. The COM object is working fine when I use it
> in VB.net. But when I use the same code in ASP.net 1.1 I am getting
[quoted text clipped - 4 lines]
> Thanks in Advance
> Anu

I think we need a little more information to solve this problem.  But
parameter is incorrect implies that an API call failed.

Signature

Rob Schieber

radha0809@gmail.com - 28 Dec 2005 19:54 GMT
I am not calling any API functions.
I have a com object which is created in VB6.
Now we are trying to migrate to ASP.net. I am trying to use the same
code. I migrated the com object to .net. Trying to use it in the
ASP.net application. It is giving parameter incorrect error. I tried
using the same code which i used in ASP.net in VB.net for testing
purpose and it works fine.

My questions is why the COM object is not working in ASP.net when it is
working fine in VB.net?

Here is the code which I am using on the web form.

   Inherits System.Windows.Forms.Form
   Public fobjXtrac As XTRACCOM.XTRACApplication
   Public pobjWI As XTRACCOM.XTRACWorkItem

Private Sub Page_Load(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Load

    Dim str As String
    Dim strWI As String

       fobjXtrac = New XTRACCOM.XTRACApplication

       pobjWI = fobjXtrac.GetActiveWorkItem(&HDEADBEEF, False)

       str = (pobjWI.WorkItemID)

       Label1.Text = str
End Sub

XTRACCOM is my COM object.

I am using the same code in a button click event in the VB.net
application.

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.