|
I needed something like that time ago, so I looked over the internet and found the UserPort driver - it allows to use the in and out asm instructions when is installed & initialized.
For documentation how it works look @:
UserPort doc.[^]
If this is what you want, the google should help you with your next steps
|
|
|
|
|
Thank you very much.
Trust in the code Luke. Yea right!
|
|
|
|
|
hi guys
could some one tell me please how can i create database ".mdb" without using
Access? i've XP installed with office XP when i try to use table made in
Access i get error "Unrecognized file format"
please help
|
|
|
|
|
The issue is that Office is creating a mdb using a newer version of DAO/Jet (the database engine behind Access) and that MFC is using an older version of DAO (because MFC was created when DAO. In order to use the newer version DAO, you need to set an internal variable to tell DAO to use the newer version. Do this before calling ANY DAO routines.
AfxGetModuleState()->m_dwVersion = 0x0601;
Joel Lucsy
|
|
|
|
|
When reading information from the disk drive it's read wrong. Let's say this is the contents of the disk:
B3 2D 02 40 (hexadecimal)
when i read that information into a DWORD it becomes 0x40022db3. Is it possible to read the data so it becomes 0xb32d0240 in my buffer? OK. Let's say i convert this to binary:
10110011001011010000001001000000
Is it then possible to load the data into a struct from right to left instead of left to right?
so if i have this struct and the above data is on the disk, that it would put it in from right to left:
typedef struct {
unsigned int horizontal_size_value:12;
unsigned int vertical_size_value:12;
unsigned int aspect_ratio_information:4;
unsigned int frame_rate_code:4;
} info;
Thanks all!
|
|
|
|
|
I don't know how you're reading your data but I remember that in intel processors data is stored backwards from what you see, which is what is happening in your case. This leads me to believe that you are using assembly (correct me if I am wrong). On the other hand if you want to read data from the right to the left you could do the following (by the way there could be better ways but this is the first solution that popped into my head).
For example:
long lResult;
long lNum = 0xb32d0240;
int iRMBit; // The right most bit
// There are 8 numbers of 4 bits each, a total of 32 bits
for( i = 0; i < 32; i++ )
{
lResult = lNum & pow(2, i);
if( lResult == 0 )
iRMBit = 0;
else
iRMBit = 1;
} // end for
However, I don't see why do you have to go through so much trouble when you can get this data while you are converting the hex number into a binary number. Technically, the above loop is reading the number bit by bit.
none
|
|
|
|
|
Hi,
If I have a App that launch a dialog. After the dialog is launched, I can set the focus into an edit control contained by the dialog. By adding
m_wndMyEdit.SetFocus() into OnInitDialog() and returning false.
How can I do it for a CDialogBar? CDialogBar dont have any OnInitDialog() method?
thanks;)
Everything's beautiful if you look at it long enough...
|
|
|
|
|
Make sure you return FALSE from your OnInitDialog() . Alternatively, you could use GotoDlgCtrl() . Finally, you could set the tab order of your controls so that the edit control is the first one.
/ravi
Let's put "civil" back in "civilization"
http://www.ravib.com
ravib@ravib.com
|
|
|
|
|
k thanks, But how can I do it for a CDialogBar?
Everything's beautiful if you look at it long enough...
|
|
|
|
|
Hye,
I have create my own control which derived from CWnd. In this control their are ScrollBar what I manage in code. I work perfectly except for the mouse Wheel ! I never receive the message WM_MOUSEWHEEL. I also check with spy++ and I didn't receive to.
Who can't I manage the mousewheel for my custom control (MFC) like other windows control. I must had a style to the windows ?
François.
|
|
|
|
|
Nobody made control with scrollbar ?
|
|
|
|
|
I use VC7, non-MFC
with ANSI string, it's easy to use.....but with UNICODE string ...
I have only a way to declare a string:
WCHAR szEnglish[]={'h','e','l','l','o',0x0};
WCHAR szVietNamese[]={0x1ED6,0x1ED7,0x1ED8,0x1ED9,0x0};
When I write
WCHAR wbuffer[100];
lstrcpyW(wbuffer,"\x1ED6\x1ED7\x1ED8\x1ED9");
so a error messagebox occurs: "...too big for character..."
but if I write
WCHAR wbuffer[100];
wbuffer[0]=0x1ED6;
wbuffer[1]=0x1ED7;
wbuffer[2]=0x1ED8;
wbuffer[3]=0x1ED9;
wbuffer[4]=0x0;
it's okay. why so
Can I store UNICODE string in resource?
Can you show me a another way to declare a UNICODE string?
thanks!
|
|
|
|
|
Try L"\x1ed6"
The L prefix notifies the compiler it is a wide character string.
Tim Smith
I'm going to patent thought. I have yet to see any prior art.
|
|
|
|
|
Excellent result
thank you so much
|
|
|
|
|
If you precede a string literal with L, it becomes a wide character string.
E.g.
const char* pszAnsiString = "blah";
const wchar_t* pszWideString = L"blah";
Dave
http://www.cloudsofheaven.org
|
|
|
|
|
Dave Bryant wrote:
const char* pszAnsiString = "blah";
const wchar_t* pszWideString = L"blah";
or use the _T("xxx") format and the TCHAR type if you need to also build in non-unicode.
Max.
Maximilien Lincourt
For success one must aquire one's self
|
|
|
|
|
Hi,
i'am currently working on a DSL Traffic-monitor but faceing the problem that i
can't differentiate networktraffic from internettraffic, has anyone a clue
how to do that without using a packet driver ?
Currently i get the troughput from the various sources windows supplies for
there different windows versions, but its always the total traffic for a
specific adapter, and i can't relate them to network-or internettraffic
Thank you
Mario
|
|
|
|
|
How do I show changes in the image contrast ?
|
|
|
|
|
Is there some code or component to burn a CD programatically?
I have some data and have to save a CD from my system? Is there a way for doing this?
Thanks,
Mariano
Paranoico? yo???
|
|
|
|
|
Yes, in Windows XP you can use the IMAPI API, which is in fact an easy to use set of COM components.
If you need a generic solution, you can use Nero's APIs.
It's not the fall that kills you: it's the sudden stop - Down by Law, Jim Jamursch (1986)
|
|
|
|
|
Hi
i am trying to hide a group of radio buttons, and then display
them again, once a certain action has been performed
im trying to use a control variable assigned to the first radio button
in the group and then display it with ShowWindow(SW_SHOW), but this will only
work for the first radio button in the group, and the rest
stay hidden
i cant add control varibles to the rest of the radio buttons
and i dont know how to activate them,
Please Help
Simon
Simon
|
|
|
|
|
You need to handle them individually to show and hide them.
and add a variable for each control ( and the associated DDX_Control ).
Another way would be to put the radio buttons in a CWnd parent, and show/hide the parent CWnd.
Max.
Maximilien Lincourt
For success one must aquire one's self
|
|
|
|
|
If you have them in a dialog then you can use GetDlgItem(IDC_RADIOBUTTON)->ShowWindow(SW_SHOW/SW_HIDE) rather than having a control variable attached to them. Works for me!
My world tour
What I do now..
"I spent a lot of my money on booze, birds and fast cars. The rest I just squandered"
George Best.
|
|
|
|
|
Help! I'm having real problems getting this to work. I've tried the customdial sample which somebody kindly found for me yesterday, but it doesn't seem to work right. Has anyone got a Custom Dialler working properly who could spend a few minutes with me helping me iron out the problems? (mark@otway.com).
________________________
http://www.webreaper.net
|
|
|
|
|
Hello,
INTRODUCTION:
I've installed the SAPI SDK 5.1 and even the .msm file that comes with it in order to make the programmer able to use the international phonemes. (SpPhones.msm in http://www.microsoft.com/downloads/details.aspx?FamilyId=EFE95801-96DB-4B29-A3F4-E902BC1D4999&displaylang=en[^]).
What I would like to be able to do is to use the international phonemes and not the english ones...
QUESTION:
How do I choose them in order to be able to speak them?
NOTE:
I use the phonemes by using the code below:
<code>hr = cpVoice->Speak(L"<pron sym=\"h eh 1 l ow & w er 1 l d\"/>",0,NULL);</code>
This works great, but only in english (of course because the phonemes used are the
english ones and are not enough to pronounce all the sounds of my language...)
(you can find the complete list of phonemes in the same Microsoft article that is
linked at the top of the question). Thank you in advance.
|
|
|
|