How to Convert this VB6 UserControl source code for VB.NET OCX, please help me
Dear VBFormers,
I am looking to have this usercontrol i wrote in VB6, to then be convertered into VB.NET 2019, please help me
!! Thanks in advance !!
I have a huge free products range, of computer software in which you can download using any kind of 64-Bit Web Browser. Also there is coming a Social Networking section that I am making on my Website...
|Ambra Productions Inc. | The Black Sun Society | The Black Shield | Ambra College | Church of the Black Sun | Ambra Productions Inc's Homepage | Boomtick Venues: Ambar Nightclub, Jack Rabbit Slim's, Villa Nightclub and Lucy's Love Shack | Pasta Ambra | Fish Feast Company | Wallet Wizard | Ambrose Liquor | Ambar Tavern | Ambra University | Ambra Cheese |
Do you wish to do unpaid work for me??? If so, the PM me on this Forum, and then we can get to work, programming for the future of computers go by the name of ThEiMp. This is my ghost writers name. Also my nickname, means that I am: The Imperial of the Technology Industry, so then to make it really short, I just then wrote: The Imp, which is where I get the nickname from...
Re: How to Convert this VB6 UserControl source code for VB.NET OCX, please help me
What does the user control do? Also, looking at the code, I see several things I don't like such as "On Error Resume Next" and hard coded file handles to name a few. I think you're better off rewriting the whole thing.
Re: How to Convert this VB6 UserControl source code for VB.NET OCX, please help me
-- Sorry it's far too big for posting here, or even anywhere else, then so. the resource file, is the biggest i have ever so seen, as one of them
I have a huge free products range, of computer software in which you can download using any kind of 64-Bit Web Browser. Also there is coming a Social Networking section that I am making on my Website...
|Ambra Productions Inc. | The Black Sun Society | The Black Shield | Ambra College | Church of the Black Sun | Ambra Productions Inc's Homepage | Boomtick Venues: Ambar Nightclub, Jack Rabbit Slim's, Villa Nightclub and Lucy's Love Shack | Pasta Ambra | Fish Feast Company | Wallet Wizard | Ambrose Liquor | Ambar Tavern | Ambra University | Ambra Cheese |
Do you wish to do unpaid work for me??? If so, the PM me on this Forum, and then we can get to work, programming for the future of computers go by the name of ThEiMp. This is my ghost writers name. Also my nickname, means that I am: The Imperial of the Technology Industry, so then to make it really short, I just then wrote: The Imp, which is where I get the nickname from...
Re: How to Convert this VB6 UserControl source code for VB.NET OCX, please help me
okay then, how abour you help me to rewrite it, in VB.NET 2019 source code, then so.
!! Thanks in advance !!
I have a huge free products range, of computer software in which you can download using any kind of 64-Bit Web Browser. Also there is coming a Social Networking section that I am making on my Website...
|Ambra Productions Inc. | The Black Sun Society | The Black Shield | Ambra College | Church of the Black Sun | Ambra Productions Inc's Homepage | Boomtick Venues: Ambar Nightclub, Jack Rabbit Slim's, Villa Nightclub and Lucy's Love Shack | Pasta Ambra | Fish Feast Company | Wallet Wizard | Ambrose Liquor | Ambar Tavern | Ambra University | Ambra Cheese |
Do you wish to do unpaid work for me??? If so, the PM me on this Forum, and then we can get to work, programming for the future of computers go by the name of ThEiMp. This is my ghost writers name. Also my nickname, means that I am: The Imperial of the Technology Industry, so then to make it really short, I just then wrote: The Imp, which is where I get the nickname from...
Re: How to Convert this VB6 UserControl source code for VB.NET OCX, please help me
This is all the code.
It starts with a dummy wait loop.
Then it does a check on some value, if it's 0 then it jumps to label (which is the next line ...)
If it's not 0 then it proceeds to the next line (with the same label)
It extracts some data to a string buffer from a resource file.
The saves the string buffer using the text methods of VB6 to a file.
Again some dummy loops with pointless GoTo statements.
The the saved data (a MKV movie file) is opened using some external ActiveX DLL
-> Object = "{6BF52A50-394A-11D3-B153-00C04F79FAA6}#1.0#0"; "wmp.dll"
Code:
Private Sub UserControl_Initialize()
On Error Resume Next
Dim PauseTime, Start, Finish, TotalTime
Dim a As Integer
Dim strBuff As String
With UserControl.SSTab
.Tab = 0
End With
1 With UserControl
a = a + 1
PauseTime = 3
Start = Timer
Do While Timer < Start + PauseTime
DoEvents
Loop
Finish = Timer
TotalTime = Finish - Start
If TotalTime = 0 Then GoTo 2
2 strBuff = StrConv(LoadResData("EP" & a, "VIDEO"), vbUnicode)
Open "C:\zVideo-1234567890.mkv" For Output As #1
Print #1, strBuff
Close #1
strBuff = ""
PauseTime = 3
Start = Timer
Do While Timer < Start + PauseTime
DoEvents
Loop
Finish = Timer
TotalTime = Finish - Start
If TotalTime = 0 Then GoTo 3
3 strBuff = StrConv(LoadResData("PLAYLIST", "DATA"), vbUnicode)
Open "C:\zVideo-1234567890.wpl" For Output As #1
Print #1, strBuff
Close #1
strBuff = ""
PauseTime = 3
Start = Timer
Do While Timer < Start + PauseTime
DoEvents
Loop
Finish = Timer
TotalTime = Finish - Start
If TotalTime = 0 Then GoTo 4
4 .picBox.Picture = Nothing
PauseTime = 3
Start = Timer
Do While Timer < Start + PauseTime
DoEvents
Loop
Finish = Timer
TotalTime = Finish - Start
If TotalTime = 0 Then GoTo 5
5 .WMP.URL = "C:\zVideo-1234567890.mkv"
End With
End Sub
Re: How to Convert this VB6 UserControl source code for VB.NET OCX, please help me
Originally Posted by Arnoutdv
This is all the code.
It starts with a dummy wait loop.
Then it does a check on some value, if it's 0 then it jumps to label (which is the next line ...)
If it's not 0 then it proceeds to the next line (with the same label)
It extracts some data to a string buffer from a resource file.
The saves the string buffer using the text methods of VB6 to a file.
Again some dummy loops with pointless GoTo statements.
The the saved data (a MKV movie file) is opened using some external ActiveX DLL
-> Object = "{6BF52A50-394A-11D3-B153-00C04F79FAA6}#1.0#0"; "wmp.dll"
Code:
Private Sub UserControl_Initialize()
On Error Resume Next
Dim PauseTime, Start, Finish, TotalTime
Dim a As Integer
Dim strBuff As String
With UserControl.SSTab
.Tab = 0
End With
1 With UserControl
a = a + 1
PauseTime = 3
Start = Timer
Do While Timer < Start + PauseTime
DoEvents
Loop
Finish = Timer
TotalTime = Finish - Start
If TotalTime = 0 Then GoTo 2
2 strBuff = StrConv(LoadResData("EP" & a, "VIDEO"), vbUnicode)
Open "C:\zVideo-1234567890.mkv" For Output As #1
Print #1, strBuff
Close #1
strBuff = ""
PauseTime = 3
Start = Timer
Do While Timer < Start + PauseTime
DoEvents
Loop
Finish = Timer
TotalTime = Finish - Start
If TotalTime = 0 Then GoTo 3
3 strBuff = StrConv(LoadResData("PLAYLIST", "DATA"), vbUnicode)
Open "C:\zVideo-1234567890.wpl" For Output As #1
Print #1, strBuff
Close #1
strBuff = ""
PauseTime = 3
Start = Timer
Do While Timer < Start + PauseTime
DoEvents
Loop
Finish = Timer
TotalTime = Finish - Start
If TotalTime = 0 Then GoTo 4
4 .picBox.Picture = Nothing
PauseTime = 3
Start = Timer
Do While Timer < Start + PauseTime
DoEvents
Loop
Finish = Timer
TotalTime = Finish - Start
If TotalTime = 0 Then GoTo 5
5 .WMP.URL = "C:\zVideo-1234567890.mkv"
End With
End Sub
Does it actually do anything useful? I guess what I'm really asking is if it's worth translating.
C++ programmers will dismiss you as a cretinous simpleton for your inability to keep track of pointers chained 6 levels deep and Java programmers will pillory you for buying into the evils of Microsoft. Meanwhile C# programmers will get paid just a little bit more than you for writing exactly the same code and VB6 programmers will continue to whitter on about "footprints". - FunkyDexter
There's just no reason to use garbage like InputBox. - jmcilhinney
The threads I start are Niya and Olaf free zones. No arguing about the benefits of VB6 over .NET here please. Happiness must reign. - yereverluvinuncleber
C++ programmers will dismiss you as a cretinous simpleton for your inability to keep track of pointers chained 6 levels deep and Java programmers will pillory you for buying into the evils of Microsoft. Meanwhile C# programmers will get paid just a little bit more than you for writing exactly the same code and VB6 programmers will continue to whitter on about "footprints". - FunkyDexter
There's just no reason to use garbage like InputBox. - jmcilhinney
The threads I start are Niya and Olaf free zones. No arguing about the benefits of VB6 over .NET here please. Happiness must reign. - yereverluvinuncleber
Re: How to Convert this VB6 UserControl source code for VB.NET OCX, please help me
hey dudes, i am Richard Graeme Ambra, that of which you don't know who i am, then so
I have a huge free products range, of computer software in which you can download using any kind of 64-Bit Web Browser. Also there is coming a Social Networking section that I am making on my Website...
|Ambra Productions Inc. | The Black Sun Society | The Black Shield | Ambra College | Church of the Black Sun | Ambra Productions Inc's Homepage | Boomtick Venues: Ambar Nightclub, Jack Rabbit Slim's, Villa Nightclub and Lucy's Love Shack | Pasta Ambra | Fish Feast Company | Wallet Wizard | Ambrose Liquor | Ambar Tavern | Ambra University | Ambra Cheese |
Do you wish to do unpaid work for me??? If so, the PM me on this Forum, and then we can get to work, programming for the future of computers go by the name of ThEiMp. This is my ghost writers name. Also my nickname, means that I am: The Imperial of the Technology Industry, so then to make it really short, I just then wrote: The Imp, which is where I get the nickname from...
Re: How to Convert this VB6 UserControl source code for VB.NET OCX, please help me
first i want to access the Windows Media Player, which is the ActiveX that is called: WMP.ocx, or what not so, then okay with that
I have a huge free products range, of computer software in which you can download using any kind of 64-Bit Web Browser. Also there is coming a Social Networking section that I am making on my Website...
|Ambra Productions Inc. | The Black Sun Society | The Black Shield | Ambra College | Church of the Black Sun | Ambra Productions Inc's Homepage | Boomtick Venues: Ambar Nightclub, Jack Rabbit Slim's, Villa Nightclub and Lucy's Love Shack | Pasta Ambra | Fish Feast Company | Wallet Wizard | Ambrose Liquor | Ambar Tavern | Ambra University | Ambra Cheese |
Do you wish to do unpaid work for me??? If so, the PM me on this Forum, and then we can get to work, programming for the future of computers go by the name of ThEiMp. This is my ghost writers name. Also my nickname, means that I am: The Imperial of the Technology Industry, so then to make it really short, I just then wrote: The Imp, which is where I get the nickname from...