Search:
Type: Posts; User: AngelV
Search:
Search took 0.05 seconds.
-
WOW Brilliant!! That solved the problem :)
To be honest, It would have never occurred to me to declare the MEMBERID_NIL const as long !!!
I already knew that DispCallFunc is very unforgiving...
-
Indeed fafalone. I use x64 but I also use x32.
BTW, the GetDocumentation vtable call fails with the same -2147319765 error in both x64 and x32 so I suspect the error is not related to the calling...
-
I had seen that post but I can't use oleexp .
Thanks.
-
I dopn't think so. VTable_Ordinal is 12
PTR_LEN = 4&
*QueryInterface Offset = 0 * PTR_lEN = 0
*AddRef Offset = 1 * PTR_lEN = 4
*Release ...
-
I am trying to extract all classes CLSID and corresponding interface names given a COM DLL.
I found this C++ code snippet which I am trying to translate into vb6/vba but the code erors out when I...
-
Thanks. I will do that. If I have any difficulties, I will ask in the forum.
Thanks for your help.
-
@fafalone
After some further testing, Ii seems that the reason for your code crashing in vbax64 is because I have two versions of excel installed in my computer (both x32 and x64)
I don't know...
-
Yes, MessageBoxTimeout works and MessageBoxEx works too. However, MessageBoxIndirect doesn't work and ignores the dwLanguageId
-
I just downloaded and installed rohitab apimonitor but I don't know how I would use it to monitor what happens in the background and watch all the calls made when let's say I call a simple MsgBox....
-
Dim lRet As Long
lRet = SoftModalMessageBox(md)
Debug.Print lRet '<<=== output works fine
MsgBox lRet '<<== Error 5 invalid procedure call or argument
After making the change you suggested,...
-
Just to confirm the issue. I just copied and pasted your full module code (from post#29) in my vba project. I changed nothing. the code compiles well. and then when ran, it displays the...
-
Well. it could be because I am using an older version (xl 2016 x64). Who knows.
It may well be, but dwLanguageId is completely ignored in MessageBoxIndirect ! I am yet to see a working example.
-
Although your code uses PtrSafe and LongPtr, it may still be running x32bit. Are you sure your vba host is not a x32bit application ?
PS: Please, try replacing LongPtr with LongLong to confirm.
-
@fafalone,
Your last code displays the messagebox but you can't show the result in a msgbox . In fact, you can't display any other msgbox after the function returning.
It doesn't crash if...
-
Franky, I can't believe it !! I didn't know that the MessageBoxEx(A/W) API worked for showing multilingual button captions! for some reason, I was under the impression that it didn't work just like...
-
@fafalone
I seem to have managed to make the undocumented SoftModalMessageBox api look and behave just like standard vb/vba msgbox but with the added bonus of being able to choose the language...
-
I have managed to make this undocumented SoftModalMessageBox func work but it is useless for what I am after here because the vbMsgBoxStyles have no effect except for icons.
This undocumented...
-
@fafalone
Have you made any progress with this? Thanks.
-
This is what I am using:
Private Declare PtrSafe Function MessageBoxIndirect Lib "user32" Alias "MessageBoxIndirectW" (lpMsgBoxParams As MSGBOXPARAMSW) As Long
Private Type MSGBOXPARAMSW
...
-
No. I didn't compile or tested the C code in the article. All I see is that it is wrapper for the user32 MessageBoxIndirect and the article explains how to set the dwLanguageId which implies (at...
-
I have 4 languages installed. English being the current default system language.
When I change the default language (say from English to Spanish) via Control Panel, the MessageboxIndirect func...
-
Agree. It is just that such an important step (otherwise the icons won't show up) is not documented anywhere ! I find this weird.
Had I not seen a MessegaBoxIndirect example posted in this forum...
-
UP
As I mentioned in post#5, I am Still trying to understand why I need to AND the dwStyle with (Not (&H70&)).
What's all about this misterious flag? I can't find it anywhere in the...
-
Online and via code :
EnumSystemLocales(AddressOf EnumSystemLocalesProc, LCID_INSTALLED)
-
One more question:
MB.dwStyle = (Buttons + MB_USERICON) And Not (&H70&)
If we omit the And Not (&H70&), the messagebox icons don't show up.
Where does that magic flag come from? I couldn't...
-
Shame. I saw this C# project in the codeproject website and the developper sounds confident the language ID can be set.
-
I want to set the language of the messagebox buttons via the dwLanguageId member of the MSGBOXPARAMS but it is not working.
I have tested with Spanish, Arabic and French which are all installed in...
-
Thanks fafalone for the explanation.
-
Hi all,
Function SomeFunc(x As Long) As Long
SomeFunc = x
End Function
Sub Caller()
MsgBox SomeFunc(2&) '<== Works ok
End Sub
-
@Dry Bone
BTW,
If (typ And &H4000) = 0 Then ArrayPtr = VarPtr(arr): Exit Function
The ArrayPtr function won't work if the array is passed ByVal
-
Sorry for the confusion. I used ArrPtr from msvbvm60.dll just because I am posting the question in the vb6 forum and to make it easy for you guys to test the code snippet. In reality, I use the...
-
Thank you guys for your help.
@Dry Bone
I tweaked your alternative ArrayPtr custom function using CopyMemory as I am applying this to vba where there is no msvbvm60. Your solution worked.
...
-
Yes, I know I could do that but, I am exploring SafeArrays and related ole functions. I am trying to learn how arrays work at lower level.
Thanks.
-
Declare Function ArrPtr Lib "msvbvm60.dll" Alias "VarPtr" (var () As Any) As Long
Declare Function SafeArrayCopy Lib "oleaut32" (ByVal psa As Long, ByVal ppsaOut As Any) As Long
Declare Sub...
-
As we can see from the above MSForms library docs, the UserForm CoClass implements two interfaces: The _UserForm (default interface) and the FormEvents (default events interface)
Below, I am...
-
Thanks fafalone. I have learnt so much from your work on interfaces.
-
@fafalone
Thanks.
I was actually displaying the text in the debug window and on a standard MsgBox which are ansi.
Why would PSFormatPropertyValue return a string with such invisible...
-
Hi fafalone,
Been using this but i get extra 0x3f character (? question mark character) when passing System.DateCreated as mPKEY
?20/?02/?2024 ??10:45
BTW, the vbforums site is very slow today...
-
-
Duplicate - forum site slow
|
Click Here to Expand Forum to Full Width
|