VB6 and wine_get_unix_file_name
VB6 and wine_get_unix_file_name
Hello,
I'm trying to make a function for using wine_get_unix_file_name in VB6
programs.
Private Declare Function lstrcpyA Lib "kernel32.dll" (ByVal lpString1 As
String, ByVal lpString2 As Long) As Long
Public Declare Function GetProcessHeap Lib "kernel32" () As Long
Public Declare Function HeapFree Lib "kernel32" (ByVal hHeap As Long, ByVal
dwFlags As Long, IpMem As Any) As Long
Public Declare Function wine_get_unix_file_name Lib "kernel32" (ByVal
lpszSrc As String) As Long
Public Function GetUnixPath(ByVal sPath As String) As String
Dim ptr As Long
Dim sBuffer As String * 255
ptr = wine_get_unix_file_name(StrConv(sPath, vbUnicode))
lstrcpyA sBuffer, ptr
HeapFree GetProcessHeap(), 0, ByVal ptr
GetUnixPath = sBuffer
End Function
Sub Main()
UnixPath = GetUnixPath()
MsgBox UnixPath
End usb
When running this code I got a blank msgbox can anyone help me please.
See you.
Escuder Nicolas
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.winehq.org/pipermail/wine-us ... chment.htm
I'm trying to make a function for using wine_get_unix_file_name in VB6
programs.
Private Declare Function lstrcpyA Lib "kernel32.dll" (ByVal lpString1 As
String, ByVal lpString2 As Long) As Long
Public Declare Function GetProcessHeap Lib "kernel32" () As Long
Public Declare Function HeapFree Lib "kernel32" (ByVal hHeap As Long, ByVal
dwFlags As Long, IpMem As Any) As Long
Public Declare Function wine_get_unix_file_name Lib "kernel32" (ByVal
lpszSrc As String) As Long
Public Function GetUnixPath(ByVal sPath As String) As String
Dim ptr As Long
Dim sBuffer As String * 255
ptr = wine_get_unix_file_name(StrConv(sPath, vbUnicode))
lstrcpyA sBuffer, ptr
HeapFree GetProcessHeap(), 0, ByVal ptr
GetUnixPath = sBuffer
End Function
Sub Main()
UnixPath = GetUnixPath()
MsgBox UnixPath
End usb
When running this code I got a blank msgbox can anyone help me please.
See you.
Escuder Nicolas
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.winehq.org/pipermail/wine-us ... chment.htm
Re: VB6 and wine_get_unix_file_name
That is Wine internal function - don't use it.Escuder Nicolas wrote:I'm trying to make a function for using wine_get_unix_file_name in VB6 programs.
VB6 and wine_get_unix_file_name
On Sat, May 10, 2008 at 9:16 AM, vitamin <[email protected]> wrote:
But we do export that function from kernel32, so it's not
*that* internal. And IIRC we use that function in Picasa
to hide the DOS drive letters. So I think I support Escuder's
idea.
- Dan
I suppose alternately one could run winepath.Escuder Nicolas wrote:That is Wine internal function - don't use it.I'm trying to make a function for using wine_get_unix_file_name in VB6 programs.
But we do export that function from kernel32, so it's not
*that* internal. And IIRC we use that function in Picasa
to hide the DOS drive letters. So I think I support Escuder's
idea.
- Dan
Re: VB6 and wine_get_unix_file_name
Then one can always use GetProcAddress().Dan Kegel wrote:On Sat, May 10, 2008 at 9:16 AM, vitamin <[email protected]> wrote:I suppose alternately one could run winepath.Escuder Nicolas wrote:That is Wine internal function - don't use it.I'm trying to make a function for using wine_get_unix_file_name in VB6 programs.
But we do export that function from kernel32, so it's not
*that* internal. And IIRC we use that function in Picasa
to hide the DOS drive letters. So I think I support Escuder's
idea.
- Dan
VB6 and wine_get_unix_file_name
On Sat, May 10, 2008 at 12:35 PM, vitamin <[email protected]> wrote:
And it's what Escuder is trying to do with VB. He's just
having a little trouble getting it working.
- Dan
Right, that's what Picasa does, I think.Then one can always use GetProcAddress().But we do export that function from kernel32, so it's not
*that* internal. And IIRC we use that function in Picasa
to hide the DOS drive letters.
And it's what Escuder is trying to do with VB. He's just
having a little trouble getting it working.
- Dan
Re: VB6 and wine_get_unix_file_name
Well this is Wine forum not VB forum. What I suggested works perfectly for me in C programs.Dan Kegel wrote:Right, that's what Picasa does, I think.
And it's what Escuder is trying to do with VB. He's just
having a little trouble getting it working.
VB6 and wine_get_unix_file_name
On Sat, May 10, 2008 at 2:48 PM, vitamin <[email protected]> wrote:
We shouldn't discriminate against people trying to
ask Wine-specific questions just because of the language they choose to use.
Vitamin, you have to cut the bad attitude.Well this is Wine forum not VB forum. What I suggested works perfectly for me in C programs.And it's what Escuder is trying to do with VB. He's just
having a little trouble getting it working.
We shouldn't discriminate against people trying to
ask Wine-specific questions just because of the language they choose to use.
VB6 and wine_get_unix_file_name
vitamin wrote:
to my logic, but you have to be willing to assist those who use a
language other than your favorite. BTW, VB is used in industry for some
heavy duty programs (of which I have signed NDAs for in order to get an
interview.) The question and problem are legit, so if you cannot help
someone with the problem then let others.
BTW, I would suggest to the OP of this problem to look in a good VB book
to see how to convert a c call into a VB call.
James McKenzie
Acutally, this belongs in a developer forum, not a Users forum accordingDan Kegel wrote:
Well this is Wine forum not VB forum. What I suggested works perfectly for me in C programs.Right, that's what Picasa does, I think.
And it's what Escuder is trying to do with VB. He's just
having a little trouble getting it working.
to my logic, but you have to be willing to assist those who use a
language other than your favorite. BTW, VB is used in industry for some
heavy duty programs (of which I have signed NDAs for in order to get an
interview.) The question and problem are legit, so if you cannot help
someone with the problem then let others.
BTW, I would suggest to the OP of this problem to look in a good VB book
to see how to convert a c call into a VB call.
James McKenzie
VB6 and wine_get_unix_file_name
UnixPath = GetUnixPath() needs a parameter...
Escuder Nicolas escreveu:
Escuder Nicolas escreveu:
Hello,
I’m trying to make a function for using wine_get_unix_file_name in VB6
programs.
Private Declare Function lstrcpyA Lib "kernel32.dll" (ByVal lpString1
As String, ByVal lpString2 As Long) As Long
Public Declare Function GetProcessHeap Lib "kernel32" () As Long
Public Declare Function HeapFree Lib "kernel32" (ByVal hHeap As Long,
ByVal dwFlags As Long, IpMem As Any) As Long
Public Declare Function wine_get_unix_file_name Lib "kernel32" (ByVal
lpszSrc As String) As Long
Public Function GetUnixPath(ByVal sPath As String) As String
Dim ptr As Long
Dim sBuffer As String * 255
ptr = wine_get_unix_file_name(StrConv(sPath, vbUnicode))
lstrcpyA sBuffer, ptr
HeapFree GetProcessHeap(), 0, ByVal ptr
GetUnixPath = sBuffer
End Function
Sub Main()
UnixPath = GetUnixPath()
MsgBox UnixPath
End usb
When running this code I got a blank msgbox can anyone help me please.
See you.
*Escuder Nicolas*
------------------------------------------------------------------------