|
Ok.. thanks.. to bad I can't just up the limit... Oh well..
I think I'll just go through all my static text objects and code them in.. That should free up bunches...
Thanks for the info...
|
|
|
|
|
Can you explain why you use of 400 objects,please?
|
|
|
|
|
IIRC a dialog resource has a limit of 255 controls. If you need more, you can create them in your WM_INITDIALOG handler.
|
|
|
|
|
I'am trying to use VC to operate Ms Excel, but I can't set the back color of cells, what can I do for it?
freeman
|
|
|
|
|
Here's a code segment written in VB
With Selection.Interior
.ColorIndex = 3 ' this is red ...
.Pattern = xlSolid
End With
I think it it easy to know how to do it in VC from that.
By the way, there is a way to know how to get some work accomplished in your codes: just open Excel, and record a macro doing just the same thing, then you can check the code in Excel's Macro editor. I got that piece of code in this way.
|
|
|
|
|
Good idear! I have solved my problem! Thank u!
And do it in VC just need to add some codes follow:
Interior bkColor;
bkColor.AttachDispatch(range.GetInterior().pdispVal)
bkColor.SetColor(COleVariant((long)0x000000)); //black
Also Give Thank to a friend named ◎Alpha◎ who helped me, God will bless him and his family!
freeman
|
|
|
|
|
Im using the SetTimer() function to try and achieve a 100Hz query via RS-232... My problem that I have run into, is that we i check the time that the timer is occuring at, using std::GetLocalTime(), and comparing it to the last time it was called, it appears that it running at 20Hz, or every 50 milliseconds as oppose to 10 ms. Any ideas on why this is happening, and how to fix it?
"There are 10 types of people, those who understand binary, and those who don't."
- Somebody, not me.
|
|
|
|
|
For that kind of resolution you'll probably want to use a multimedia timer.
Timer events coming through windows messages are pretty innacurate and resolution is not so good
(as you've seen).
Check out timeGetDevCaps(), timeBeginPeriod(), timeSetEvent(), etc.
Mark
|
|
|
|
|
Hello
I am trying to use wide character constants in my program in a switch statement basically as follows:
TCHAR chChar = L'ä';
switch( chChar )
{
case L'ä': break;
case L'ö': break;
}
UNICODE and _UNICODE are both defined.
The compiler gives me warning C4066: "characters beyond first in wide-character constant ignored". This leads to error C2196: "case value '195' already used".
Is there any way around this?
Thanks.
|
|
|
|
|
If you cast L'ä' and L'ö' to short , what do you get? If the values are different, then use casting for the workaround. If not, it would seem that there's an issue with the compiler.
--
Presented in doublevision (where drunk)
|
|
|
|
|
I can't reproduce that (warning level 3).
Are you sure _UNICODE is defined before #include <tchar.h> ??
Mark
-- modified at 18:41 Tuesday 24th October, 2006
|
|
|
|
|
Don't use any characters outside of the ASCII range in your source code. Use the \x escape with the Unicode code points for the characters - L'\xe4' for ä, L'\xf6' for ö, and so on.
|
|
|
|
|
Well, in the software i'm developing, we need to display images on a folder. I'm using the FindFirstFile function and specifying a directory. This is working fine.
The problem arises when there's a filename that contains extended characters, such as "U+FB98: Arabic Letter Gueh Initial Form", which is this one: ﮘ. Now, the FindFirstFile function returns it, but the FindFileData.cFileName returns a filename with some question marks(I suppose these are wildcards) instead of the symbols.
This would not be a problem if the loading CBitmap would work... but it doesnt. I suppose it's in fact because of these symbols being replaced with question marks.
Is there any way around this? How can I effectively get the filename I need? Is this a problem with gdiplus CBitmap loading operation or with the filename being given with question marks?
Thanks in advance!
Andrés Cartín
|
|
|
|
|
Are you using the Unicode version of FindFirstFile..?
--
If not entertaining, write your congressman
|
|
|
|
|
Well, I tried to. I have to prefix this "\\?\" to the path right? In C the prefix would be written as "\\\\?\\". This produces the exact same results.
<br />
strPattern = "\\\\?\\" + m_folder;<br />
<br />
if (strPattern.Right(1) != TEXT("\\") )<br />
strPattern += "\\";<br />
strPattern += "*.*";<br />
hFind = ::FindFirstFile(strPattern, &FindFileData);
Any ideas?
|
|
|
|
|
skullfire wrote: Any ideas?
No, sorry.
--
Simulcast on Crazy People's Fillings
|
|
|
|
|
skullfire wrote: I have to prefix this "\\?\" to the path right?
No. You do not have to add the prefix. Just go to your project settings and change your project to using UNICODE.
And you have to change all string constants in your program to wide char strings, i.e., "*.*" should be replaced with L"*.*" , unless you are using the TEXT macro like:
skullfire wrote: if (strPattern.Right(1) != TEXT("\\") )
|
|
|
|
|
Currently I have a working example code (VC++ 8) for Win32 platform which uses WinPcap libraries. Does anybody know how to change the platform to Pocket PC 2003? Do I have to have WinPcap libraries for Pocket PC?
Yinyan Wang
|
|
|
|
|
Hi,
How do I send message to the parent window to move a cursor from one point to another
Any ideas please
Prithaa
|
|
|
|
|
Move the mouse cursor? SetCursorPos()
Move the "text cursor" (caret)? SetCaretPos()
Does the parent need to do this?
Mark
|
|
|
|
|
Hello,
Yes ,I need to send a message to the parent to move the keyboard cursor
Thanks
Prithaa
|
|
|
|
|
Hi
I am using _popen to execute an exe file and read back the result in to a text file and analyze it. but from the time that user clicks the button the console window appears on the screen and goes away when the process is finished. how can i hide the console window from the user and show something like work in progress instead.
is there a way to hide _popen ?
char Buffer[9];<br />
string commandline="address";<br />
<br />
FILE *fp;<br />
<br />
if ( (fp= _popen(commandline.c_str(),"r"))==NULL)<br />
exit(1);<br />
<br />
fgets( Buffer, 9, fp );
|
|
|
|
|
mitil20390482304 wrote: I am using _popen to execute an exe file...
To create a Windows application that redirects input and output, read the section "Creating a Child Process with Redirected Input and Output" in the Win32 SDK. See here and here.
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
thanks man..i have already read those,,,and I have a really hard time undrestanding how i can use it in my case...can you help me some more...how can i run my _popen inside a process that has a hiden window?
|
|
|
|
|