this is code http://yanhui8001.googlepages.com/test_draw.rar[^] this is error video. http://yanhui8001.googlepages.com/question.rar[^] this code is gdi+ draw program. need set #include and lib.
alantop
this is code http://yanhui8001.googlepages.com/test_draw.rar[^] this is error video. http://yanhui8001.googlepages.com/question.rar[^] this code is gdi+ draw program. need set #include and lib.
alantop
this is idl declaration: STDMETHOD(ExecVerifygps)(/*[in]*/ BSTR gpsContent, /*[in]*/ short length, /*[out, retval]*/ boolean* flag); this build tli file. inline char IVgps::ExecVerifygps ( _bstr_t gpsContent, short length ) { char _result; HRESULT _hr = raw_ExecVerifygps(gpsContent, length, &_result); if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this)); return _result; } why 3rd parameter change to char?
alantop
How to CComBSTR convert to char *?
alantop
How to send and receive data use the same port? alantop
Thanks two.I want the curve is free, no rule, casually for two, may draw passes through these two curves. alantop
I need a plot curve the example? Who may provide? Extremely thank! alantop
VARIANT varBuffer; ------------------ if(varBuffer.vt==(VT_ARRAY|VT_UI1)) { DWORD dwSize=varBuffer.parray->rgsabound[0].cElements; BYTE lpBuffer=new BYTE[dwSize]; memcpy( lpBuffer , varBuffer.parray->pvData,dwSize); delete []lpBuffer; } alantop
vc provides one method. build new project, select "Custom AppWizard",input new project name.ok show "Custom AppWizard - Step 1 of 2", select "an existing Project", next, show "Custom AppWizard - Step 2 of 2", now notice select yourself project (*.dsp),finish. build... now it will bring "*.awx" and "*.pdb". then copy they to vc install directory common\msdev98\template. now you build new project, use "AppWizard", you find new item. alantop
I code this, but no use? why? How to add Timer in activex ? BEGIN_MSG_MAP(ClistSample) MESSAGE_HANDLER(WM_TIMER, OnTimer) END_MSG_MAP() LRESULT OnTimer(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled) { return 0; } alantop
if not, how to use thread in the activex ? alantop
How uses ATL to establish to have the doc/view style ActiveX control. Best, may provide an example. I want to establish treectl in the left side, right side establishes listctl. A little likes the windows explorer. alantop
But, I didn't find a quicker accees the method. alantop
How access Safearray to be quicker in ATL? alantop
I use m_ListBox.ModifyStyle(0, LBS_MULTIPLESEL), but don't modify its style to "multiple". why? thanks! alantop
How to modify CListBox's style? alantop
{ ShowBanner(); if (!AfxWinInit(::GetModuleHandle(NULL), NULL, ::GetCommandLine(), 0)) { cerr << _T("MFC Failed to initialize.\n"); return 1; } if (argc < 2 || !ParseOptions(argc, argv) || pszURL == NULL) ShowUsage(); int nRetCode = 0; CTearSession session(_T("TEAR - MFC Sample App"), dwAccessType); CHttpConnection* pServer = NULL; CHttpFile* pFile = NULL; try { // check to see if this is a reasonable URL CString strServerName; CString strObject; INTERNET_PORT nPort; DWORD dwServiceType; if (!AfxParseURL(pszURL, dwServiceType, strServerName, strObject, nPort) || dwServiceType != INTERNET_SERVICE_HTTP) { cerr << _T("Error: can only use URLs beginning with http://") << endl; ThrowTearException(1); } if (bProgressMode) { cerr << _T("Opening Internet..."); VERIFY(session.EnableStatusCallback(TRUE)); } pServer = session.GetHttpConnection(strServerName, nPort); pFile = pServer->OpenRequest(CHttpConnection::HTTP_VERB_GET, strObject, NULL, 1, NULL, NULL, dwHttpRequestFlags); pFile->AddRequestHeaders(szHeaders); pFile->SendRequest(); DWORD dwRet; pFile->QueryInfoStatusCode(dwRet); // if access was denied, prompt the user for the password if (dwRet == HTTP_STATUS_DENIED) { DWORD dwPrompt; dwPrompt = pFile->ErrorDlg(NULL, ERROR_INTERNET_INCORRECT_PASSWORD, FLAGS_ERROR_UI_FLAGS_GENERATE_DATA | FLAGS_ERROR_UI_FLAGS_CHANGE_OPTIONS, NULL); // if the user cancelled the dialog, bail out if (dwPrompt != ERROR_INTERNET_FORCE_RETRY) { cerr << _T("Access denied: Invalid password\n"); ThrowTearException(1); } pFile->SendRequest(); pFile->QueryInfoStatusCode(dwRet); } CString strNewLocation; pFile->QueryInfo(HTTP_QUERY_RAW_HEADERS_CRLF, strNewLocation); // were we redirected? // these response status codes come from WININET.H if (dwRet == HTTP_STATUS_MOVED || dwRet == HTTP_STATUS_REDIRECT || dwRet == HTTP_STATUS_REDIRECT_METHOD) { CString strNewLocation; pFile->QueryInfo(HTTP_QUERY_RAW_HEADERS_CRLF, strNewLocation); int nPlace = strNewLocation.Find(_T("Location: ")); if (nPlace == -1) { cerr << _T("Error: Site redirects with no new location") << endl; ThrowTearException(2); } strNewLocation = strNewLocation.Mid(nPlace + 10); nPlace = strNewLocation.Find('\n'); if (nPlace > 0) strNewLocation = strNewLocation.Left(nPlace); // close up the redirected site
Does this, certainly cannot examine a webpage whether exists? Only analyzes a URL. alantop
How to check if a url is valid at internet? alantop
please send to me : e-mail: zhmster@gmail.com alantop
I'm sorry I meant to say if there is a method that test if a File exist or not? thanks! alantop