|
Does it make real windows programs?.
I wrote a one click app in vb, and it's a pain in the a** to maintain and deploy. The program I'm writing now is to replace the vb program I wrote. The program below. It's so hard to package and deploy that program, that it's not worth the effort.
http://www.ice5commerce.com/Applications/suWizard_2012/SetupWizard.html[^]
I made a huge mistake in the program, in which I tried to make it support XP and Vista, and it bombs on XP because I could not deploy the Microsoft.Web.admin.dll to XP. I had to rely on the web server dll to get the path to the website, so I can find the AppData Folder.
|
|
|
|
|
jkirkerx wrote: Does it make real windows programs?.
Of course.
I would suggest using MFC, but, you need to go through one of the MSDN tutorials first, it can be a little complex at first to get to know the tools.
==============================
Nothing to say.
|
|
|
|
|
I just don't want to load that c++ redistribute program
|
|
|
|
|
Yeah, OK. Since you are learning then stick with the win32 api and c++, it wil give you a great foundation to make MFC code rerally fly later on.
==============================
Nothing to say.
|
|
|
|
|
I'm working on Win7 and VC++2010. I've built MFC application with Web Browser Control I added registry entry to enable the "Open in new Tab" but I need to disable/invisible the "Open in new Window".
Anyone knows how to do this?
10x
Dan
Dan B.
|
|
|
|
|
Hi,
I'm trying to create a Windows application that needs to do the following:
-The application is comprised of only one dialog window that will render a bitmap.
-I would like this bitmap to be a screen capture of exactly what lies behind my window. If I were to move the app window, the bitmap content would update according to what new content is behind it. In some sense the window would look like a hollow frame, although the content inside it would be altered somewhat.
I know that there are transparent window API's, and while that would let me "see" what lies behind, it wouldn't actually provide the copy of the pixels that I need to manipulate.
I'm pretty sure have that Windows keeps track of the non-active desktop space, including what lies behind the active window. Does anyone know of an API call or a method that would allow me to get at this?
Anyone's help is appreciated. Thanks!
|
|
|
|
|
Quite a few articles here[^] on CodeProject.
Unrequited desire is character building. OriginalGriff
I'm sitting here giving you a standing ovation - Len Goodman
|
|
|
|
|
When you want to do the screen shot, do the following steps:
- minimize your window
- wait shortly (other windows will now be re-painted)
- do the screen shot of the whole screen
- restore your window
- get the (screen) position and size of your window and cut the corresponding region from your screen shot. That's now the region of interest.
|
|
|
|
|
All you need is the handle of the window and PrintWindow .
void CScreenShotDlg::OnPaint()
{
CPaintDC dc(this);
HWND hWnd = ::FindWindow( 0, _T( "myWindow" ));
PrintWindow( hWnd,
dc.GetSafeHdc(),
0 );
}
This [ article ] shows how to capture a window even if it is minimized or fully hidden by other windows
The [ PrintWindow ] function (MSDN).
|
|
|
|
|
That's great! Thanks a lot for your help, and I'll let you know how things go.
|
|
|
|
|
This is my first post so please be kind.
I have a project that requires the locale for the current session to be set to something different than the system setting, e.g. system is American English but the session needs to be German. The program uses setlocal.c aand related routines installed with VS2005.
This works well for most languages. The problem is that some locales/languages cannot be set with this method per MS (
|
|
|
|
|
CliffRat wrote: The problem is that some locales/languages cannot be set with this method per MS
If this is a published restriction I am not sure what you expect from this site.
Unrequited desire is character building. OriginalGriff
I'm sitting here giving you a standing ovation - Len Goodman
|
|
|
|
|
Silly me...
Iguess I thought someone might know of another method or possibly a workaround to this one.
|
|
|
|
|
The [setlocale] function.
The code below sets the current locale to "Germany".
#include <stdio.h>
#include <locale.h>
#include <time.h>
int main(void)
{
time_t ltime;
struct tm *thetime;
unsigned char str[100];
setlocale(LC_ALL, "German");
time (<ime);
thetime = gmtime(<ime);
if (!strftime((char *)str, 100, "%#x",
(const struct tm *)thetime))
printf("strftime failed!\n");
else
printf("In German locale, strftime returns '%s'\n",
str);
setlocale(LC_ALL, "C");
time (<ime);
thetime = gmtime(<ime);
if (!strftime((char *)str, 100, "%#x",
(const struct tm *)thetime))
printf("strftime failed!\n");
else
printf("In 'C' locale, strftime returns '%s'\n",
str);
}
|
|
|
|
|
Thanks for the suggestion but that is what is currently being used.
The problem is that some languages, and the codes are clearly documented, have a codepage value of 0 (zero). Some of these languages need to be set for the session but are rejected because a zero codepage is not handled in the code.
I need a workaround to programmatically change to these 0 (zero) codepage languages.
HELP!
|
|
|
|
|
CliffRat wrote: The problem is that some locales/languages cannot be set with this method per MS (
You could implement your own solution of course.
Or just refuse to support those, perhaps by examining the requirement that stated they were needed in the first place. Specifically what is the realistic, not imagined, market share possible from those locations in the next year? Or the next five?
|
|
|
|
|
Just to let everyone know...
I posted this also to MSDN forums and they were able to duplicate the problem as it exists in VC++ 2005. They also pointed out that this issue had been corrected in VC++ 2010.
Of course, my problem is I need to keep working in 2005 for now...
C'est la vie!
|
|
|
|
|
I've written a C++ FTP Client to fetch files of a certain name pattern. I use FtpFindFirstFile which iteratively returns file data into the WIN32_FIND_DATA structure and it works great from dos (far end) to dos (near end).
However, when the far end is Unix, the string returned in the cFileName member of the WIN32_FIND_DATA struct also contains all the file attributes (file size, access rights etc.).
I'm sure it must be something simple, but how can I get it to work so I just get the actual filename returned ? It's a real pain as I need to use wildcards in my pattern match.
|
|
|
|
|
As far as i know there is no standard to what form the FTP protocol gives you a directory listing, it's basicly meant for a human to read, so different implementations might return the information differently making it hard if not impossible to make a universal parser. I guess Microsoft uses its own way to do it which can be parsed by the WinInet methods but unix goes its own ways. It might as well just be a simple line termination difference, e.g. windows expects a new-line at the end of lines while unix works with carriage-returns, or something like that. Don't know how to get around that.
> The problem with computers is that they do what you tell them to do and not what you want them to do. <
> If it doesn't matter, it's antimatter.<
|
|
|
|
|
I've managed to configure my FTP client with the far end OS and parsed the results accordingly. Seems like a bit of a hack, but works.
|
|
|
|
|
Hi,
As code-o-mat stated, the old ftp protocol RFC describing the LIST/NLST commands neglected to standardize the output. However it might save you some time if you have a look at ftpparse[^] written by Dr. Bernstein[^]. It doesn't look very pretty but millions of servers across the world are using his internet software.
Best Wishes,
-David Delaune
|
|
|
|
|
Default message map is getting overloaded and application is getting freeze. I want to solve it by providing multiple message maps. Is that possible? If yes any example?
|
|
|
|
|
What do you mean by overloaded? There isn't a restriction in size that I'm aware of.
Chris Meech
I am Canadian. [heard in a local bar]
In theory there is no difference between theory and practice. In practice there is. [Yogi Berra]
posting about Crystal Reports here is like discussing gay marriage on a catholic church’s website.[Nishant Sivakumar]
|
|
|
|
|
Well, each "derived class" of a CDialog has its own Message Map. That map is first in a "daisy chain" back through the base class (for as deep as the derivation chain goes). So, technically, you can have multiple maps.
I too am curious on how yours got "overloaded". Sounds like the daisy chaining is not set up correctly.
|
|
|
|
|
rahul.kulshreshtha wrote: Default message map is getting overloaded and application is getting freeze
You dont need a nother message map, you need to structure your code correctly: Dont wait in the message handling code, or do heavy work. Think of the message handler as a dispatcher.
Have it fire off threads to do the work, or to wait for events, ie, do the usefull stuff.
Then your app will stop freezing.
==============================
Nothing to say.
|
|
|
|