|
Nevermind - found it out myself:
<br />
IHTMLDocument2Ptr piDoc = ...;<br />
IPersistStreamInitPtr piPersistStreamInit;<br />
IStreamPtr piStream;<br />
HGLOBAL hGlobal = NULL;<br />
<br />
::CreateStreamOnHGlobal( NULL, TRUE, &piStream );<br />
piDoc->QueryInterface( IID_IPersistStreamInit, (void**)&piPersistStream );<br />
piPersistStream->Save( piStream, FALSE );<br />
<br />
::GetHGlobalOnStream( &hGlobal, piStream );<br />
<br />
size_t nNumBytes = ::GlobalSize( hGlobal );<br />
if ( nNumBytes > 0 )<br />
{<br />
BYTE* pBytes = reinterpret_cast< BYTE* >( ::GlobalLock( hGlobal ) );<br />
if ( pBytes[0] == 0xFF && pBytes[1] == 0xFE )<br />
{<br />
LPCWSTR pszwHTML = reinterpret_cast< LPCWSTR >( pBytes + 2 );<br />
}<br />
else<br />
{<br />
LPCSTR pszHTML = reinterpret_cast< LPCSTR >( pBytes );<br />
}<br />
::GlobalUnlock( hGlobal );<br />
}<br />
<br />
Wenn ist das Nunstück git und Slotermeyer? Ja! Beierhund das oder die Flipperwaldt gersput!
|
|
|
|
|
I am writing an application right now in VB 6.0. I was just wondering if someone could help with this. Upon the FormLoad() function, I need the program to call a notepad file (main.ini) and read the third line and replace a variable inside of my program. Can somebody please please help me????
Thanks again,
Bob
|
|
|
|
|
Bad forum . Warning: VBers hated here .
Pavel
Sonork 100.15206
|
|
|
|
|
BHBAD2002 wrote:
Can somebody please please help me????
Yeah! I can tell ya to not cross-post and ask in the appropriate forum. Like say, it's a VB question, so maybe your luck will change in the, gee I don't know, the Visual Basic / VB.NET forum maybe.
Jeremy Falcon
Imputek
<nobr>"In fact it is quite simple, men and women both only want one thing - what they can't have!" - phykell
|
|
|
|
|
I think it will need ADOX, but are there any links/samples that show how to merge database1 and database2 to create a final database. The number of fields in each db is different, and some of them are distinct, though some overlap.
Thanks,
ns
|
|
|
|
|
Do you mean merging seperate databases or seperate tables? Can you provide more information about your database format etc.
Michael
Programming is great. First they pay you to introduce bugs into software. Then they pay you to remove them again.
|
|
|
|
|
EAch access database has one table. SOme of the fields overlap. I need to merge these two different databases, so that the new one has all the fields (union of), and whatever field was not present in database 1, should have entries "abc", likewise if the field wasnt present in database2, those records should have entries "abc" too. I suppose one could at first check and see which fields are different, then use ADOX for each database to add the new fields and populate them. So now we have two dbs with identical fields (different number of records of course). Now how to merge these two databases so the final one has one table in it which is the sum of the tables from db1 and db2.
Hope this is clearer...
Thanks,
ns
|
|
|
|
|
Do you just need the result or do you actually need a program that does this.
If itst the result you're looking for. Do it in Access by importing data from one DB into the other ( or import both into a new DB). Create a table with all the fields you want. Use Insert queries to move the data from the old tables to the new one.
Even if you need to be able to repeat the process. I'd recommend doing this in Access. Just write a VBA script to do the job.
|
|
|
|
|
Unfortunately I have to do this with code as a feature of another program. I'm using MFC...
|
|
|
|
|
Its too bad you have to do this in VC++. That will be the most ineffective language to use.
Your original post posed this question:
are there any links/samples that show how to merge database1 and database2 to create a final database
I can't imagine that there are. That's a pretty odd thing to do to databases. Using MFC or anything else, the process will be as I described earlier. I have seen code samples of creating a new database and tables from VC, but I can't remember exactly where. With a little effort you should be able to find examples of each of the steps.
Good luck,
Bill
|
|
|
|
|
I have a list control object and I add a notification handler for double-clicks (VC.NET). The problem is that I never receive the notification.
Michel
It is a lovely language, but it takes a very long time to say anything in it, because we do not say anything in it, unless it is worth taking a very long time to say, and to listen to.
- TreeBeard
|
|
|
|
|
AFAIK, WM_LBUTTONDBLCLK won't work for list box'es!
Use the following:
ON_LBN_DBLCLK(IDC_MYLISTBOX, OnDblclkMyListBox)
If you are using Wizards, it generates this code. There shouldn't be any problems.
Mustafa Demirhan
http://www.macroangel.com
Sonork ID 100.9935:zoltrix
<nobr>They say I'm lazy but it takes all my time
|
|
|
|
|
Is there a possibility to create a MetafileDC without clip region ? All metafiles derived from ClientDC or ScreenDC have an implicit "desktop-size" clip region.
My problem:
Metafiles, created from our graphic displays, do not include all graphical objects, if the graphic display has dimensions larger desktop size. Missing are WMF-based objects, which are drawn by PlayEnhMetafile(). Debugging shows, that these objects are processed and that PlayEnhMetafile() does not return an error.
I assume, that the WMF data is clipped, if these objects' origin are outside the device dependent clip region.
The problem would be solved, if I could define a MetafileDC with a clip region equal to the dimensions of the graphic display.
|
|
|
|
|
You create an enhanced metafile by CreateEnhMetaFile (CreateMetaFile is only leftovers for Win16 compatibility)?
This call creates one HDC.
I see no mention in the documentation that it should in any way or form clip to the desktop size. But if it does, you might try a call to SelectClipRgn with a NULL region.
|
|
|
|
|
Using ATL Server for Web Service may be a choice for speed when comparing with other Web Service methods, but when I
using it to make a test, I met a strange problem, My idea is put the image processing methods on the Server, the client can load image data, and then access the server for processing. since only for testing, I define only one method:
HRESULT SobelProcessH([in]LPSTR lpImage,[out,retval]lpImageOut)
I also presented the realization for this SobleProcessH function on the server, then I add a project for WebSetup, build them, so the service is done, when I begin to create a client project to access the service, the problem came out:
first I added a client project, then I added Web Reference for the Web Service, after that the proxy builded and output a .h file for me, but in that .h file, I found the SobelProcessH function having three parameter other than two,another parameter
int lpImage_size
was found in the function.
you know I define the function with two parameter in the server side, why did this happen? what kind of type should I use for transfer image in the functions based on SOAP and XML?
victorswan
|
|
|
|
|
Hi:
we can use winpopup.exe to send net message to other peer in win9x,while in winNT/2000,we use "net send ...".
Winpopup.exe use windows mailslot to read/write message,the question is how winNT/2000 read/write message from network? does it use namedpipe?
I am seeking...
For what?
Why did you ask me for what? I don't know!
|
|
|
|
|
I'm pretty sure "net send" uses SMB (the horror).
A starting point might be Q168893.
For more info I'd point you to the samba project (no url, but googling should get you there).
|
|
|
|
|
No, it also uses NetBios(), which actually means it uses mailslots.
The "net send" thing is there since the very first days of Windows for Workgroups and interoperable between all OS that support SMB (they all use the same mailslot for it).
--
Daniel Lohmann
http://www.losoft.de
(Hey, this page is worth looking! You can find some free and handy NT tools there )
|
|
|
|
|
I read long ago, and forgot... one way to integrate the platform SDK help into VS help, thus one can access it directly pressing F1. Does anybody know how to or whether is it still possible with the latest SDKs?
Thanks,
Javier
|
|
|
|
|
The last PSDK I downloaded (July) included a menu item under Start/Programs/Microsoft Platform SDK called Visual Studio Registration. The function Register PSDK... worked well in VS6. I don't know if it works with VS.NET, but it's worth a try.
|
|
|
|
|
Yes, I know that option, but it is only meant to include for you the source, headers and lib paths into VS options.
I believe what I want is way more tricky to do something with registry keys.
Thank You anyway!
|
|
|
|
|
Check this out:
http://www.codejock.com/developer/article01.htm
I am seeking...
For what?
Why did you ask me for what? I don't know!
|
|
|
|
|
Yesss
That's what I was looking for!
Thank You!
|
|
|
|
|
I don't know if this would work the same way it worked for me.
I alaredy had MSDN library, so after instalig PSDK Ive changed the folowing keys in registry (WinXP):
HKEY_LOCAL_MACHINE\SOFTVARE\Microsoft\HTML Help Collections\Developer Collections\0x0409\0x035eef540
Default: Name
Filename: path to the sdk .col file
|
|
|
|
|
Please send me one.
Thank you very much!
Best regards!
msn: nevergrief@hotmail.com
C++ lover ,haha
|
|
|
|