|
I HAVE DOWNLOADED AN EXE FILE USING URLOPEN().NOW I WANT TO SET-UP THAT EXE FILE WITHOUT SHOWING ME THE SET UP WINDOW,ASKING FOR PARAMETRS TO SET-UP.THE INSTALLATION SHOULDNOT ASK PARAMETERS FOR INSTALLATION FOR ANY EXE FILE I DOWNLOAD.
IS THERE ANYWAY IT AUTOMATICALLY ACCEPT DEFAULT PARMETERS.
|
|
|
|
|
sunit5 wrote:
NOW I WANT TO SET-UP THAT EXE FILE WITHOUT SHOWING ME THE SET UP WINDOW
Please clarify. Are you wanting to run the .exe file using something like CreateProcess() or ShellExecute() ? Unless the .exe file that you are wanting to run accepts command-line parameters, there is nothing you can do.
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
|
|
|
|
|
thanks for ur suggestion it helped me.if the exe file accepts command-line parameters then only i can do silient installation.otherwise in windows i have to know what parameters does that .exe will accept.pls pour in ur suggestions if i m wrong.
|
|
|
|
|
you can make your exe file to go for silent install , it depend how you make your exe file.
and also pls dont use caps for messages.
Regards
Tarundeep Singh Kalra
************************
www.tarunsadhana.com
************************
All men die. Not all men really live”. - “Braveheart”, 1995
|
|
|
|
|
Hi, I'm developing on WinCE, ppc2003
these are dialog's datas from .rc file:
IDD_LAMINERKIA_DIALOG DIALOGEX 12, 11, 200, 300
STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION
EXSTYLE WS_EX_CLIENTEDGE | WS_EX_STATICEDGE
FONT 8, "MS Sans Serif"
BEGIN
DEFPUSHBUTTON "OK",IDOK,0,23,240,30
LTEXT "Stat",
IDC_STATIC,0,70,233,100,0,WS_EX_CLIENTEDGE
END
well.. how do I retrieve Dialog's information regarding its size and position.. I mean: how do I get the values underlined 12, 11, 200, 300?
[Note: GetWindowRect() or GetLocalRect() both give me values regarding the screen position.. and I need the exact values of the .rc file!]
Any help is welcome.
|
|
|
|
|
Dialog dmensions in an .rc file are in dialog base units[^], not pixels. To obtain the dialog's dimension in client coordinates, convert the size obtained using GetWindowRect() , like so:
CRect rect;
GetWindowRect (&rect);
ScreenToClient (&rect);
/ravi
My new year's resolution: 2048 x 1536
Home | Articles | Freeware | Music
ravib@ravib.com
|
|
|
|
|
Hi, Ravi,
thank u, but.. a couple of things:
1) ScreenToClient() lets unchanged the values of rect .. and even ClientToScreen() seems totally worthless. What reason for this?
2) The values I get in rect with GetWindowRect() and with GetClientrect() are those of the screen.. I mean.. exactly the coordinates where the device places the dialog automatically.. they're different from the values on my .rc file... and they're not even these I'd expect with the conversion..
Any idea on how to retrieve the values from the .rc file directly ...not having to convert anything?
|
|
|
|
|
As I mentioned, the width and height dimensions in your .rc file are in dialog base units, not pixels (i.e. screen coordinates). You can use GetDialogBaseUnits() to help convert screen coords to dialog base units, and MapDialogRect() to go in the other dirextion.
Hope this helps.
/ravi
My new year's resolution: 2048 x 1536
Home | Articles | Freeware | Music
ravib@ravib.com
|
|
|
|
|
This is exactly what I did, but the strange event is this:
neither GetWindowRect() nor GetClientRect() retrieves me values looking like my dialog's values
This is the example:
this is the sample dialog
IDD_LAMA_DIALOG DIALOG DISCARDABLE 50, 50, 200, 200
STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION
FONT 8, "MS Sans Serif"
BEGIN
DEFPUSHBUTTON "OK",IDOK,58,23,100,30
LTEXT "S",
IDC_STATIC,7,70,200,100,0,WS_EX_CLIENTEDGE
END
and this is the rect I get calling GetWindowRect()
[ I call this function inside the Onpaint() event ] :
top=26 (just under the menu bar)
bottom=294
left=0
right=240
(the screen resolution of my device is 240X320)
These values seems to have nothing to do with my .rc values.. and they represent size and dimension of the Dialog after it's been diplayed automatically and has filled the screen place.
So the question is the same.. I have to find the correct way to get the original size and position of mydialog ... after I will convert.
|
|
|
|
|
It seems that Windows is maximizing your dialog to fill the screen. You should try to disable this behavior - I suspect that will cause Windows to position the dialog at the screen coords corresponding to (50, 50, 200, 200).
Once again, note that the (50, 50, 200, 200) dimensions in your .rc file are in dialog base units, and NOT pixels!
/ravi
My new year's resolution: 2048 x 1536
Home | Articles | Freeware | Music
ravib@ravib.com
|
|
|
|
|
Lvca wrote:
exactly the coordinates where the device places the dialog automatically.. they're different from the values on my .rc file...
As has already been mentioned, the values in the .rc file are in dialog base units (DBUs), which are device-independent. These are different than pixels. The reason, and benefit, for this is so that an application can use a single template to create the same dialog box for all types of display devices. This ensures that a dialog box will have the same proportions and appearance on all screens despite differing resolutions and aspect ratios between screens.
Last time I bothered messing with them, one DBU was equal to about 1/4 the size of a system-font character. Using a different font changes this ratio. To get the number of pixels per DBU for the current display, use the GetDialogBaseUnits() function
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
|
|
|
|
|
You can process the resource data directly out of the binary resource data of your DLL, OCX, EXE, etc. using the EnumResourceNames, EnumResourceTypes, EnumResourceLanguages, etc. family of functions.
From your statement it is unclear exactly when you want to get these values. You should be able to read the resources from within the dialog, or you can do it from elsewhere in your program, or from another program entirely.
|
|
|
|
|
Hello,
How do I temporary disable the WM_PAINT operation during the time I am the scrolling CView? The reason is that I have a list of heavy drawing operations in my OnDraw. I would like it to draw only after I stop the scrolling of my CView.
thank you
|
|
|
|
|
I think the SetRedraw(TRUE|FALSE) function disables/enables calls to the drawing mechanism. I use it to disable drawing while populating large entries in my tree and list controls. I think this is a function of the CWnd class, so should also work in your CView derived class.
I Dream of Absolute Zero
|
|
|
|
|
Thanks, I will try that.
Yang
|
|
|
|
|
Try with CWnd::SetRedraw(FALSE);
Have a nice day
|
|
|
|
|
i'm using VS.Net 2003, compiling a DLL with /MDd (it links to external libs
compiled with the same flags)
the following is in the main header
#if _MSC_VER < 1300
#include <iostream.h>
#else
#include <iostream>
using namespace std;
#endif
the project compiles without error or warning, but while linking i get ...
C:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\include\ostream(955):
error C2491: 'std::flush' : definition of dllimport function not allowed
C:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\include\ostream(947):
error C2491: 'std::ends' : definition of dllimport function not allowed
C:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\include\ostream(930):
error C2491: 'std::endl' : definition of dllimport function not allowed
these are repeated once per include of the header...
these methods are prefixed with the _CRTIMP2 macro, which with /MDd set, is
expanded to __declspec(import).
This in turn which chokes the linker..
note that i'm not even (explicitly) using any STL classes/templates/operators, etc
any clues on how to solve this ?
"Fried ice-cream is a reality !" - George Clinton
|
|
|
|
|
My VC6 IDE New/Projects listing contains items for which the target was already deleted. The IDE is in:
"C:\Program Files\Microsoft Visual Studio\Common\MSDev98\Bin\MSDEV.EXE"
Specifically e.g. it refers to a "VCFLibraryAppWizard" (note, the VCF target was already deleted; maybe a mistake?)
How can I remove/delete this item from the IDE? Which file contains the reference to it?
|
|
|
|
|
Hi,
I know a bit of C++ programming. I need to improvre my knowledge about it. In particular I'd like to learn how to:
1) Realize a GUI;
2) Implement SQL instructions;
3) implement a dll already built;
4) If it possible I would also like to begin to learn something about multithreading programming.
I'd like make all these things by Visual Studio
So, I'm serching for a book to help me. Can someone advise me some title?
Thanks!!!
Fracco.
|
|
|
|
|
hi
i would suggest
Begining Visual C++ 6.0 by Ivor Horton. by WroX
( the big book )
Jetli
Constant Thing In World Is Change.
|
|
|
|
|
Well there are loads of books on the net if u look for them. Lookng into your requirements, I would suggets Sams Teach Yourself VC++ in 21 days. Pretty good book with all you need, one thing at a time, covers all you are lookng for and more. You can either opt to buy a hard copy or download the pdf, chm or htm whatever you find convineant from the net. This book will give you a hands on experience in all aspects, but if you are keen on intricate details, go for MS Press books like MFC Programming, Programming Win98, etc, again, all available on the net as well as hard copies!
long live the dEvIL
|
|
|
|
|
Stduy any simple vc++ book first.
Then you turn to MSDN.
Microsoft press - Robert Petsold for Win32
Microsoft press- Jeprey pross for MFC
|
|
|
|
|
Hi All,
I want to send a digitally signed email that should contain the digital certificate that could be shown by the email client.
I have the S/MIME compatible message but i am unable to send that message as a digitally signed message through MAPI. If any one knows about the libraries, APIs which i can use to send a digitally signed email through MAPI, then please share ur knowledge with me.
Regards,
Common Man
|
|
|
|
|
hi everyone. i'm hoping there's a genius out there who can help me with this
bit of a beginner here with C++. I'm using .net 2.0 / VS 2005 Beta (for my sins!)
i have a rather basic problem, which i cannot seem to resolve.
i have a managed class "city" (definitions below)
i have a function to load an external XML file (selected by the user), which creates a managed array City, as follows (the int "numberofcities" is also read from the file)
array<city^>^City = gcnew array<city^>(numberofcities);
each object City[0], City[1], City[2] etc is then created as I loop through the XML city file, using
City[rowcount] = gcnew city(...,...,.... )
obviously, i don't know the size of the array or the contents until the file is selected by the user and the XML is processed.
All well and good so far. I can play with the array within the file loading function and I'm happy. But then the City array of objects is of local scope to the function loading the XML, and I want to be able to access this array elsewhere in the program
for example, i have a function where i draw the cities on a map, and want to use something like:
double longitude = City[1]->lng;
double latitude = City[2]->lat;
and so on.
so after the long winded introduction: my question is -- how can i make City available to other functions outside of the scope where it was loaded?
i have had a few people make suggestions, but no-one has come up with something workable so far.
i heard about:
1. using native arrays rather than .net arrays -- but then i can't include system::strings in the class
2. defining a "wrapper class" - have only found references to this regarding .COM objects ? i confess, i don't know where to start.
3. using a singleton object and instances (?) : again, no clue
4. using a pin pointer; (but the pin pointer is only a local scope variable also?) and anyway i don't know if it works
5. passes the array from function to function. i'm not sure i can make that work either. also, there is more than one array loaded alongside City.
6. don't use arrays of objects, use XML connection directly in each function. could work, but i would lose all the benefits of being able to manipulate objects (for example, i will have a method for city to allocate all the demand from city 1 to city 2)
i would really appreciate someone giving either a detailed idea of how to address this... or at the least maybe giving some sort of indication of which if any of the above suggestions is worth me looking in to in more depth
thanks everyone!
//////////////////
public ref class city
{
public: int cityID;
String ^cityName;
String ^ countryID;
String ^ countryName;
double lng, lat;
double dailydemand;
double annualdemand;
//constructor
public: city() {
dailydemand = 0;
annualdemand = 0;
}
public: city(int cID,String ^ cName,String ^ coID,String ^ coName,double ln,double la)
{
cityID=cID;
cityName=cName;
countryID=coID;
countryName=coName;
lng=ln;
lat=la;
}
};
|
|
|
|
|
I'd go for possiblity no 3 by making City a global variable. I have never used VC7.0 or managed code/arrays, but in my VC6.0 I would put the declaration in a common header:
<br />
extern array^ City;<br />
and in one (and only one) cpp put
<br />
array^ City = NULL<br />
and in your XML read function:
<br />
City = gcnew array(numberofcities)<br />
In this way City is visible all over your program
Cheers
Steen.
"To claim that computer games influence children is ridiculous. If Pacman had influenced children born in the 80'ies we would see a lot of youngsters running around in dark rooms eating pills while listening to monotonous music"
|
|
|
|
|