|
Is the dll a resource only dll.
You may have to use FindResource or LoadResource.
« Superman »
|
|
|
|
|
Hi,
How can I write a multilanguage application in VB 6, VC6 ?
Thank !
To love in vain more than love no one.
|
|
|
|
|
hi friend,
maybe you should split your programs into DLLs, since they are language independent.
Write a DLL in VB , VC++, Delphi, or anything else and use them from your main program.
this would be a good method
Regards,
Mohammad
|
|
|
|
|
Put your code in one place and your resources in a separate DLL.
Load the appropriate language DLL at runtime.
All functions loading resources accept a 'handle' of the module where the resource to be loaded must come from.
|
|
|
|
|
I want to send a bmp from one client to another client using the Sockets.
How can i do it. Because i tried to read *.bmp file and send it to remote client. But unfortunately it didnt receive what i intended to send. Do i need to study BMP File Format. If yes from where coz i cudnt find any by searching. Please give me a good ref to it
Thankx
|
|
|
|
|
Hi friend,
I really didn't try to send large amounts of data over a network, so what i write here is just a try to help:
lets assume that both client and server know how much data is to be sent.
Then:
on the sending terminal:
1. Load the Bitmap using LoadImage.
2. Attach it to a CBitmap Object.
3. Allocate memory using GlobalAlloc function, equal to the size of bmp
4. Get Bitmap Data using GetBitmapBits()
5. send these data using send(), with each send() sends about 1KB of data.
On the receiving terminal:
1. Create a compatible CBitmap Object.
2. use recv() to receive the whole image data. (multiple recv() calls may be needed)
3. use setbitmapbits() to set image data, to what was received.
4. now use this object as a CBitmap.
Remember that on the receiving terminal you must first set bitmap info (i.e. bitsperpixel, width ,...) to the same values as the bitmap on the source
And Good Luck
Regards,
Mohammad Gdeisat
now you have
|
|
|
|
|
Thank You so much Friend ... I will try and hope it works :P
|
|
|
|
|
one thing more since GetBitmapBits() and SetBitmapBits() are now obselete in Win32 programming, I will have to use GetDIBits() and SetDIBits() instead. Thankx alor for the help and guidance
|
|
|
|
|
I am giving you only logic, you have to implement the rest.
#1 Read whole Bmp File in Char array(character by character, open that in text mode), don't forget to add NULL character to complete the char array.
#2 Send that through socket and after receving it another end copy all the data in to empty file.
#3 the file now contain required data
or you can go for this example,if you facing difficult implemeting above logic
http://www.codeproject.com/internet/SocketFileTransfer.asp[^]
"I Think this Will Help"
[Vote One Here,.....]
<h5
alok gupta="" <br=""> visit me at http://www.thisisalok.tk
|
|
|
|
|
yah i try it many days ago but i failed then ... i dont exactly rem the problem...i was sending the file size correctly...did broke the file into pieces and send it but failed somehow...well i liked the other method mentioned in this thread so might give a try to it now....anyways thanx for the help
|
|
|
|
|
Now trying to hook joystick.but it's not easy to me.
below is my source.
//------------------------------------------------------------------
// Set Hook
//------------------------------------------------------------------
BOOL SetHook( HWND hWnd )
{
g_HwndServer = hWnd ; // Set Hook Server
if(joySetCapture( g_HwndServer , JOYSTICKID1, 0, FALSE))
{
MessageBox(g_HwndServer, "Unable to capture the joystick",
NULL, MB_OK);
}
// set movement threshold
//.......................
{
UINT nThreshold;
joyGetThreshold(JOYSTICKID1, &nThreshold);
if (nThreshold < 100)
{
nThreshold = 100;
joySetThreshold(JOYSTICKID1, nThreshold);
}
}
g_Hook = SetWindowsHookEx( WH_GETMESSAGE , GetMessageProc, (HINSTANCE)g_Module , 0 ) ;
return false ;
}
//------------------------------------------------------------------
// Remove Hook
//------------------------------------------------------------------
BOOL RemoveHook()
{
joyReleaseCapture(JOYSTICKID1);
UnhookWindowsHookEx( g_Hook ) ;
return true ;
}
//--------------------------------------------------------------
// Hook Procedure - Keyboard
//--------------------------------------------------------------
LRESULT CALLBACK GetMessageProc(int nCode, WPARAM wParam, LPARAM lParam)
{
LPMSG msg=(LPMSG)lParam;
if ((nCode >= 0) && PM_REMOVE == wParam &&
(msg->message == MM_JOY1MOVE
{
MessageBox( g_HwndServer, "Joistick",
NULL, MB_OK);
}
// We must pass the all messages on to CallNextHookEx.
return ::CallNextHookEx( g_Hook , nCode , wParam , lParam );
}
the problem is that though i don't move joystick this above code is
executed.
i hope you help me to solve this problem.
God bless you!
nice to meet u
|
|
|
|
|
Why aren't you using DirectInput?
Don't try it, just do it!
|
|
|
|
|
your advice is correct.
DirectInput is very good. i don't need to hook joystick
it is enough to use directInput.
Thank you.
God bless you.
nice to meet u
|
|
|
|
|
i am using cdoex.dll in my application by #import statement.It gives compile errors in cdoex.tlh file.Please any one give the solution to get rid of these errors.Here is the code.
#import "F:\\Program Files\\Common Files\\System\\ado\\msado15.dll" rename("EOF","EndOfFile")
#import "F:\\Program Files\\Common Files\\Microsoft Shared\\CDO\\cdoex.dll"
CoInitialize(NULL);
{
IMessagePtr iMsg(__uuidof(Message));
IConfigurationPtr iConf(__uuidof(Configuration));
iConf = iMsg->Configuration;
FieldsPtr Flds = iConf->GetFields();
Flds->Item[cdoSendUsingMethod]->Value = _variant_t(cdoSendUsingPort);
Flds->Item[cdoSMTPServer]->Value = _variant_t("lavanm2k3.csavl2k3.com");
Flds->Item[cdoSMTPConnectionTimeout]->Value = _variant_t((long)10);
Flds->Item[cdoSMTPAuthenticate]->Value = _variant_t(cdoBasic);
/*FieldPtr Fld = Flds->GetItem("http://schemas.microsoft.com/cdo/configuration/sendusing");
// Set the sendusing field to cdoSendUsingExchange.
Fld->Value = "2";
Flds->Item[cdoSendUserName]->Value = _variant_t("xshield");
Flds->Item[cdoSendPassword]->Value = _variant_t("titan%10");
Flds->Item[cdoURLProxyServer]->Value = _variant_t("server:80");
Flds->Item[cdoURLProxyBypass]->Value = _variant_t("<local>");
Flds->Item[cdoURLGetLatestVersion]->Value = _variant_t(VARIANT_TRUE);*/
Flds->Update();
iMsg->From = "\""+fromvar+"\"";
int n= listvar2.GetCount();
for(int j=0;j<n;j++)
{
="" cstring="" str;
="" listvar2.gettext(j,str);
=""
="" imsg-="">To = "\""+str+"\"";
iMsg->Subject = "\""+subvar+"\"";
iMsg->TextBody = "\""+textvar+"\"";
try
{
iMsg->AddAttachment("\""+attachvar+"\"","","");
}
catch(_com_error err)
{
// handle exception
}
for(int i=0;i<m_nmsg;i++)
{
="" imsg-="">Send();
}
}
}
CoUninitialize();
Errors:
g:\MFCtest\mailsend1\Debug\cdoex.tlh(915): error C2501: 'CDO::IDataSource::_ConnectionPtr' : missing storage-class or type specifiers
g:\MFCtest\mailsend1\Debug\cdoex.tlh(915): error C2501: 'CDO::IDataSource::ActiveConnection' : missing storage-class or type specifiers
g:\MFCtest\mailsend1\Debug\cdoex.tlh(927): error C2146: syntax error : missing ';' before identifier 'GetActiveConnection'
g:\MFCtest\mailsend1\Debug\cdoex.tlh(927): error C2501: 'CDO::IDataSource::_ConnectionPtr' : missing storage-class or type specifiers
g:\MFCtest\mailsend1\Debug\cdoex.tlh(915): error C2146: syntax error : missing ';' before identifier 'ActiveConnection'
|
|
|
|
|
Can anyone help me with this problem??
|
|
|
|
|
hiho@ll
i try to auto login a website using the postdata i got from a form
my code:
CString url("http://www.mytestlogin.de/public/login.php");
CString post("user=testuser&pwd=testpass&log=&login=Login");
CString header("Content-Type application/x-www-form-urlencoded");
COleVariant vPostData(post);
COleVariant vHeader(header);
BSTR str=::SysAllocString(T2OLE(url.GetBuffer()));
m_pWebBrowser->Navigate(str,COleVariant((long)0,VT_I4),
COleVariant("_SELF", VT_BSTR),vPostData,vHeader);
does anybody know why it doesn't work?
all i get is the login page, where i have to put username and pass and click the login button
but with the code above i should be in the member area!?
i traced the http connection with a http proxy and the browser doesn't send the post data and my header!?
Is there a failure in variable declaration?
whats wrong?
thx@ll
|
|
|
|
|
yeah
my problem was the following:
replace
CString header("Content-Type application/x-www-form-urlencoded");
with
CString header("Content-Type: application/x-www-form-urlencoded\n");
|
|
|
|
|
other application pass the hInstance or hWnd as an int , my program should change it into HINSTANCE or HWND.
How to do this?
|
|
|
|
|
you have to cast int to HINSTANCE or HWND, like this way
<code>int</code> i=...;
<code> HINSTANCE </code>hInst=(<code>HINSTANCE</code>)i;
or
<code>HWND</code> hWnd=(<code>HWND</code>)i;
"I Think this Will Help"
[Vote One Here,.....]
<h5
alok gupta="" <br=""> visit me at http://www.thisisalok.tk
|
|
|
|
|
I need to make my application run within MS Word. Any ideas or suggestions??
Basically what i need to do is write a software and have it run with another existing software.
|
|
|
|
|
http://support.microsoft.com/?kbid=278260
|
|
|
|
|
|
Hello.
I've been searching the internet for hours now and I am looking for an OpenSource C++ library that does POP3 mail retrieval with SSL support for Windows. Basically, i only need sample code with SSL. Using the RFC, I can do mail retrieval and listing. I just need to get sample code for SSL with POP3. The idea is that I'm trying to make a POP3 notifier with SSL support as a plugin for another application.
Thanks a lot.
|
|
|
|
|
Trivex wrote:
SSL support for Windows
Would this[^] article help?
/ravi
My new year's resolution: 2048 x 1536
Home | Articles | Freeware | Music
ravib@ravib.com
|
|
|
|
|
Here is the errors when building:
SkinMagicLib.lib(coolsblib.obj) : error LNK2001: unresolved external symbol __imp__InitCommonControlsEx@4
SkinMagicLib.lib(SkinToolBar.obj) : error LNK2001: unresolved external symbol __imp__ImageList_GetIcon@12
SkinMagicLib.lib(SkinToolBar.obj) : error LNK2001: unresolved external symbol __imp__ImageList_Draw@24
SkinMagicLib.lib(SkinToolBar.obj) : error LNK2001: unresolved external symbol __imp__ImageList_GetIconSize@12
SkinMagicLib.lib(SkinControl.obj) : error LNK2001: unresolved external symbol __imp___TrackMouseEvent@4
Debug/SkinMagicSDK.dll : fatal error LNK1120: 5 unresolved externals
How to resolve it?
Thanks!
|
|
|
|