|
Does anyone know how to register an ActiveX Control on another pc automatically without requesting the user to do it by him/herself?
is InstallShield capable of registering an ActiveX Control in setup.exe? but how? What should i do? do i need to write script for it?
When i send release of my app to my friend which includes an .ocx file they are compelled to register (many of them don't know how to do it as well by using Regsvr32.exe) it before starting the app.
Thanks for ur help..
Atilla Selem
just listening to you...
|
|
|
|
|
Yes you need to execute the DLLRegisterServer function
#include <stdole.h>
typedef HRESULT (STDAPICALLTYPE *CTLREGPROC)() ;
HMODULE hModule = ::LoadLibrary(m_strPathName) ;
CTLREGPROC DLLRegisterServer =
(CTLREGPROC)::GetProcAddress(hModule,"DllRegisterServer" ) ;
DLLRegisterServer() ;
::FreeLibrary(hModule) ;
Best Regards
Carlos Antollini.
Sonork ID 100.10529 cantollini
|
|
|
|
|
that's great...it has worked!,
thanks for ur help Mr.Antollini...
Best Regards,
Atilla Selem
just listening to you...
|
|
|
|
|
Another problem with distrubuting my application is that Mr.Antollini.
i tried to use MFC ODBC classes to keep some user information. And whenever they need to search someone they would have easily connected a DSN and got the info. But i realized that that would need them to create an ODBC connection in their local but again it needs help (as in ActiveX..)
is there a way for making a ODBC Data Source connection by coding inside the app?
That would really solve one of my distrubuting problem Mr.Antollini
Thanks for ur help,
Yours respectfully...
Atilla Selem
just listening to you...
|
|
|
|
|
Yes, No problem with that...
You need to use the function SQLConfigDataSource
SQLConfigDataSource(NULL,ODBC_ADD_DSN,
(LPSTR) "Excel Files (*.xls)",
(LPSTR) "DSN=New Excel Data Source\0"
"Description=New Excel Data Source\0"
"FileType=Excel\0"
"DataDirectory=C:\\EXCELDIR\0"
"MaxScanRows=20\0");
Carlos Antollini.
www.wanakostudios.com
Sonork ID 100.10529 cantollini
Best Regards....
|
|
|
|
|
My problem is the following. I've based myself on a document writen by Microsoft on how to print with the webBrowser Control. So I've been able to specify my desire settings like paper size and paper orientation. But my ultimate goal is to restore the original settings once I am finished. I've created a function that backups the settings and work fine and a restore function that restore my settings that works fine too. But the problem is that when it is executed the print dialog is still open and thus the restore function wont work. So far my only way arround it is to have a button call this function, but I don't want that, I want it to do that automatically.
The article I used is called Printing with the Internet Explorer WebBrowser Control written by Dave Templin. I am using the wp_print03 example.
Thank you
|
|
|
|
|
i have painted a big image on a smaller in size windowless control, how do i make the user scroll the image in the control
|
|
|
|
|
Hi,
I just want to know that if I could get a view's DC from the Doc class?
how to do it?
anyone konws?
thank you.
YES, I am here.
|
|
|
|
|
I assume that you must have access to the views from the document. If so, simply instantiate a CClientDC passing it the desired view pointer.
Cheers,
Tom Archer
Author - Inside C#, Visual C++.NET Bible
A total abstainer is one who abstains from everything but abstention, and especially from inactivity in the af
|
|
|
|
|
Look the article Q108587 - "HOWTO: Get Current CDocument or CView from Anywhere" in MSDN
Best regards,
Eugene Pustovoyt
|
|
|
|
|
Can anyone recommend a good CDatabase/CRecordset clone which doesn't use MFC?
Alternatively, can you recommend a different technology (ADO or something) which is independant of MFC?
Cheers
James Spibey
I love the word naked, it's brilliant isn't it, 'naked'. When I was a kid I used to write the word naked on a bit of paper hundreds of times and rub my face in it - Jeff, Coupling, BBC2
|
|
|
|
|
James Spibey wrote:
Can anyone recommend a good CDatabase/CRecordset clone which doesn't use MFC?
You can using COM. There are some articles in CP.
http://www.codeproject.com/database/#COM
Mazy
"The path you tread is narrow and the drop is shear and very high,
The ravens all are watching from a vantage point near by,
Apprehension creeping like a choo-train uo your spine,
Will the tightrope reach the end;will the final cuplet rhyme?"Cymbaline-Pink Floyd
|
|
|
|
|
James Spibey wrote:
Alternatively, can you recommend a different technology (ADO or something) which is independant of MFC?
SQLite at http://www.hwaci.com/sw/sqlite/
Joel Lucsy (jjlucsy@ameritech.net)
|
|
|
|
|
Libodbc++ is good, but it's not a clone of CDatabase/CRecordset. It's based on the JDBC API instead.
|
|
|
|
|
I used CSizingTabCtrlBar and created it in my CMainFrame ,but a problem followed sequently.My listviewfunctions will not work except it was called inside my listview class.For example,when i call InsertItem(...)inside my listview ,it is normal.but if i use GetActiveView()->m_pListCtrl->InsertItem(...),it doesn't work.
if i don't created this control ,then everything was ok!a strange problem ,who can help me?
i am coming quietly just as i am leaving quietly.
|
|
|
|
|
How can I get current system cpu load? Is there some
function or?
|
|
|
|
|
Kristian33 wrote:
How can I get current system cpu load?
When you say "load", do you mean a value like the one shown on unix boxes when you type "uptime", or do you just need to know the percentage of CPU (time) being used by the "System Idle Process"?
Peace!
-=- James.
(Try Check Favorites Sometime!)
|
|
|
|
|
I mean by system load like task manager style
in windows 2000/XP.
|
|
|
|
|
What do you need to Know, The speed of CPU or what kind of CPU do you have....
For those questions I have the Answers...
Regards..
Carlos Antollini.
www.wanakostudios.com
Sonork ID 100.10529 cantollini
|
|
|
|
|
pOld=GlobalAllocPtr(GMEM_MOVABLE,bi.biSizeImage)
This method for memory allocation is unknown for me.
Does anyone known the library it's in, header-file to use? Or is this a vc7.0 function? I'm using 6.0
GMEM_MOVABLE is also unknown...
[VISUAL STUDIO 6.0] [MFC] [WIN98/2]
Bluute tette!
|
|
|
|
|
Found it myself
GlobalAllocPtr is in windowsx.h.
btw. it's GMEM_MOVEABLE
[VISUAL STUDIO 6.0] [MFC] [WIN98/2]
Bluute tette!
|
|
|
|
|
GlobalAlloc and friends are all Windows API functions,. you can use them from any language you want (C/C++/VB/etc)
-c
I don't care, and you can't make me.
|
|
|
|
|
Hi, with GetTopIndex() I get the first visible index of my listbox. Is there a way to get also the current bottom index (or largest visible)?
Hmm... it seems not. I might need a workaround, e.g.:
<br />
int nTop = GetTopIndex();<br />
CRect rect;<br />
GetClientRect(&rect);<br />
int nBottom = nTop + int((rect.bottom / GetItemHeight(0))+GetItemHeight(0)-1);<br />
if(nBottom >= GetCount()) nBottom = GetCount()-1;<br />
Assuming all my items have same height (which is like that).
Thx for help/ideas.
|
|
|
|
|
Apply CListCtrl::GetTopIndex() , CListCtrl::GetCountPerPage() and some math.
|
|
|
|
|
ClistBox not CListCtrl, thx.
|
|
|
|