Jump to content

Translate from vb6 to autoit HOW ?


Recommended Posts

and i read the UDF and object i just need a START point

CODE

Private Sub Play_Click()

'Set IP Address

LiveX1.IpAddress = "62.90.2.144"

'Set Command,Data,Audio Port

LiveX1.CommandPort = "4550"

LiveX1.DataPort = "5550"

LiveX1.AudioDataPort = "6550"

'Set Login UserName and Password

LiveX1.DisablePWD = True

LiveX1.UserName = "dany"

LiveX1.Password = "1234"

'Connect

LiveX1.PlayX

End Sub

Link to comment
Share on other sites

You would have to create an object to the COMObject using ObjCreate Then use ObjEvent for events that the COMObject might have.

So something like the following:

$LiveX1 = ObjCreate("LIVEX COMOBJECT HERE")
$LiveX1.IpAddress = "62.90.2.144"

'Set Command,Data,Audio Port
$LiveX1.CommandPort = "4550"
$LiveX1.DataPort = "5550"
$LiveX1.AudioDataPort = "6550"

'Set Login UserName and Password
$LiveX1.DisablePWD = True
$LiveX1.UserName = "dany"
$LiveX1.Password = "1234"

'Connect
$LiveX1.PlayX
Edited by DarkMatter

[sub]Quantum mechanics: The dreams stuff is made of[/sub]

Link to comment
Share on other sites

You would have to create an object to the COMObject using ObjCreate Then use ObjEvent for events that the COMObject might have.

So something like the following:

$LiveX1 = ObjCreate("LIVEX COMOBJECT HERE")
$LiveX1.IpAddress = "62.90.2.144"

'Set Command,Data,Audio Port
$LiveX1.CommandPort = "4550"
$LiveX1.DataPort = "5550"
$LiveX1.AudioDataPort = "6550"

'Set Login UserName and Password
$LiveX1.DisablePWD = True
$LiveX1.UserName = "dany"
$LiveX1.Password = "1234"

'Connect
$LiveX1.PlayX

listen i try this :

$LiveX1 = ObjCreate("LiveX_V8200")

cause there is NO "VersionIndependentProgID" so i think its the right one BUT not its not work

"The requested action with this object has failed."

$LiveX1.IpAddress = "62.90.2.144" here

there is file included "OLE/COM object viewer" So.. the question is what the name of the object or i use it the right way

post-32286-1209559841_thumb.jpg

Link to comment
Share on other sites

Is "$LiveX1.IpAddress" valid for that OCX? I suspect that it is because it looks like you are converting this from VBS. The OCX file may have to be registered using Regsrvr32

You need to check it with a good object browser.

Also this script (as posted) is doomed anyway. All of the lines that begin with ' are commented tines and you have to replace those apostrophes with semi-colons.

'Set Command,Data,Audio Port

becomes

;Set Command,Data,Audio Port

George

Question about decompiling code? Read the decompiling FAQ and don't bother posting the question in the forums.

Be sure to read and follow the forum rules. -AKA the AutoIt Reading and Comprehension Skills test.***

The PCRE (Regular Expression) ToolKit for AutoIT - (Updated Oct 20, 2011 ver:3.0.1.13) - Please update your current version before filing any bug reports. The installer now includes both 32 and 64 bit versions. No change in version number.

Visit my Blog .. currently not active but it will soon be resplendent with news and views. Also please remove any links you may have to my website. it is soon to be closed and replaced with something else.

"Old age and treachery will always overcome youth and skill!"

Link to comment
Share on other sites

Is "$LiveX1.IpAddress" valid for that OCX? I suspect that it is because it looks like you are converting this from VBS. The OCX file may have to be registered using Regsrvr32

You need to check it with a good object browser.

Also this script (as posted) is doomed anyway. All of the lines that begin with ' are commented tines and you have to replace those apostrophes with semi-colons.

'Set Command,Data,Audio Port

becomes

;Set Command,Data,Audio Port

Man 10nx But i know that..... Its 1- Vaild 2 - Reg (U know this was a Lame questions) 3 - ' and ; (no commet ) and Last - the OLE/COM object viewer is Just Fine

BTW its regsvr32.exe not Regsrvr32

Edited by dorit30
Link to comment
Share on other sites

You seem to have it covered. No help required here.

George

Question about decompiling code? Read the decompiling FAQ and don't bother posting the question in the forums.

Be sure to read and follow the forum rules. -AKA the AutoIt Reading and Comprehension Skills test.***

The PCRE (Regular Expression) ToolKit for AutoIT - (Updated Oct 20, 2011 ver:3.0.1.13) - Please update your current version before filing any bug reports. The installer now includes both 32 and 64 bit versions. No change in version number.

Visit my Blog .. currently not active but it will soon be resplendent with news and views. Also please remove any links you may have to my website. it is soon to be closed and replaced with something else.

"Old age and treachery will always overcome youth and skill!"

Link to comment
Share on other sites

2 - Reg (U know this was a Lame questions)

No such thing as a stupid or lame question, we don't know you, we don't know how much you know and we don't know how much you have tried already...its not lame its called covering all the bases to get the easy stuff and obvious stuff out of the way in case you are a newbie.

BTW its regsvr32.exe not Regsrvr32

You have never made a typo ?

You seem to have it covered. No help required here.

Have to agree here...
Link to comment
Share on other sites

No such thing as a stupid or lame question, we don't know you, we don't know how much you know and we don't know how much you have tried already...its not lame its called covering all the bases to get the easy stuff and obvious stuff out of the way in case you are a newbie.

You have never made a typo ?

Have to agree here...

hi mikeyr U DONT KNOW NOTHING ITS OK FOR ME - - - BUT WHEN U C MY NAME PLZ DONT POST I HATE GUYZ WHO PUT THEIR tongue in other ass like u do with GEO

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...