|
|
I want to enumerate the User Account Names for people that actually can log on (i.e. everybody who is listed on the XP logon screen).
Using NetQueryDisplayInformation I also get IIS accounts etc, and with the NetUserEnum's filter parameter, I'm confused
Pandoras Gift #44: Hope. The one that keeps you on suffering. aber.. "Wie gesagt, der Scheiss is' Therapie" boost your code || Fold With Us! || sighist | doxygen
|
|
|
|
|
Hello friends;
I am writting a printer driver for customizing the Document & printer property sheet. I am using Win2K ddk & doing work in the unidrv. I am adding my specification in the sampe code of oemui given in the \ntddk\src\oemdll\ .
It Build successfully but when i click on the "print preferences..." button it shoud shows my "Customize MessageBox" & then it show the Default Document Property sheet (i.e. LayOut , paper Quality).
I want to show only the customize message box not anything default.
Can u please tell me the appropriate answer asap.
Regards
Asim
|
|
|
|
|
I'm trying to select a line of a multiline edit box. I've been using the LineLength function but it doesn't give me the correct number of characters of a line and i wonder why?. This is my code:
void CSubtitlesDlg::SelectLine(int Line)
{
int nLineIndex;
int nLength;
nLineIndex = m_ctrlSubtitlesList.LineIndex(Line-1);
nLength = m_ctrlSubtitlesList.LineLength();
m_ctrlSubtitlesList.SetSel(nLineIndex, nLineIndex + nLength, FALSE);
m_ctrlSubtitlesList.SetFocus();
}
|
|
|
|
|
Hi,
what about
nLength = m_ctrlSubtitlesList.LineLength( nLineIndex ); ?
int LineLength( int nLine = -1 ) const;
nLine
Specifies the character index of a character in the line whose length is to be retrieved. If this parameter is –1, the length of the current line (the line that contains the caret) is returned.
|
|
|
|
|
I am using VC++ 6.0. I want to create an application with one of the functionality of Device Manager. When we connect a usb cam or a scanner its friendly name gets added to Imaging Devices in Device Manager. I would appreciate help in creating an application similar to this but the appplication should make out the difference between the camera abd the scanner.
This is what i have done..
<br />
CString name_class="image";
GUID class_GuidList;<br />
SetupDiClassGuidsFromName(name_class,&class_GuidList,1,&required_size);<br />
dev_info=SetupDiGetClassDevs(&class_GuidList,NULL,handle_win,DIGCF_PRESENT);<br />
ret=SetupDiEnumDeviceInfo(dev_info,(DWORD)i,&DeviceInfoData);<br />
SetupDiGetDeviceRegistryProperty(dev_info,&DeviceInfoData,SPDRP_DEVICEDESC,<br />
&prop_datatype,prop_buffer,100,&req_bufsize);<br />
But the above code lists the scanner also.
Is there any way to make out the differnce between the scanner and the camera?
Regards,
Nripun
|
|
|
|
|
There is an article about doing that on CodeProject.
Don't try it, just do it!
|
|
|
|
|
Alexander M. wrote:
There is an article about doing that on CodeProject
Thanks,
I checked the following article.
http://www.codeproject.com/treectrl/DeviceTree.asp[^]
But i couldnt find any property tat is common to all usbcams and not present/different from scanner.
Regards,
Nripun
|
|
|
|
|
How to highlight multiple chars in different edit control~
What i want to do is to highlight two corresponding characters in two different edit controls?
What i know is before setsel(), i have to set focus to the edit control. So if i do the same thing to highlight the second, the highlighted edit control will definitely lose the focus, and the highlight will disappear~
How to resolve this problem!
|
|
|
|
|
Set the ES_NOHIDESEL property for both the edit controls.
The opinions expressed in this communication do not necessarily represent those of the author (especially if you find them impolite, discourteous or inflammatory).
|
|
|
|
|
|
|
i want to do my Socket Programming using CSocket Class.i m not understanding how to start with.Thanx for any help or article regarding mentioned problem
.
|
|
|
|
|
There are many way's in VC++ to deal with communication with socket
1.Try the ActiveX WinSock { if u have demo project , i did not get one}
2.Use the CSocket Class {easy to use }
3.Use CAsyncSocket which is the base class for CSocket
4.Driectly use the " SOCKET " provided in windows.
Sockets are very difficult to handle in Multiple Client and Server System
try to use WinSock
I have pasted a small raw code so dont copy past it use the funda from
this code .Actually we create two socket we Bind the first on and set it
on listining mode .When a client arrives we use another socket to communicte
through that client .Remember first one is yet in listening mode. Use the
Multithreading concept if u are using MFC .
//->--------------
#define SERVER_SOCKET_ERROR 1
#define SOCKET_OK 0
{
CSocket s,a;
s.Create();
SOCKADDR_IN sin;
sin.sin_family = PF_INET;
sin.sin_port = htons(6000);
sin.sin_addr.s_addr = INADDR_ANY;
//bind the socket
s.Bind ( (LPSOCKADDR)&sin, sizeof(sin));
if(rVal == SOCKET_ERROR)
{
socketError("Failed bind()");
WSACleanup();
return SERVER_SOCKET_ERROR;
}
//get socket to listen
s.Listen (1);
if(rVal == SOCKET_ERROR)
{
socketError("Failed listen()");
WSACleanup();
return SERVER_SOCKET_ERROR;
}
s.Listen (1);
s.Accept (a,NULL,NULL);
s.Send ("hi",3);
if(s.Connect("10.0.0.17",6123))
{
int i=0;
while(i++<10)
{s.Send(m_text,m_text.GetLength());
m_text = "";
char buff[17];
int i;
while(m_text.Find('\n') == -1)
{
i=s.Receive(buff,16);
buff[i]=0;
m_text += buff;
}
AfxMessageBox(buff);
}
// m_text.Trim();
//UpdateData(false);
}
s.Close();
}
//->----------------------------
Hope this solve your need
Vikas Amin
Embin Technology
Bombay
vikas.amin@embin.com
|
|
|
|
|
why do u not download the sample code from MSDN : ms-help://MS.VSCC.2003/MS.MSDNQTR.2003FEB.2052/vcsample/html/_sample_mfc_CHATSRVR.htm
give a hand,have a heart
|
|
|
|
|
|
|
sunit5 wrote:
Thanx a lot to everyone
Why Do u need to use CSocket in your Project! any particular reason. from you previous post here, you are using raw socket api in your project/software!
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
|
|
|
|
|
1- Suppose we have installed hebrow and arabic languages on an english version of windows. I have written a windows API program that has some text in arabic, some in hebrow and some in english to be shown on client area of my window. WITHOUT DEFINING UNICODE how can I notify Windows that This text should be shown in Arabic and that text should be shown in hebrow? perhaps by notifying Windows the code page of the text to be shown.
2- How can I change font and language of a Dialog Box with runtime functions?
3- How can I trap WM_INPUTLANGCHANGE in the dialog box procedure? this message is not sent to the procedure.
Thanks a lot
|
|
|
|
|
Hello. I was wondering what is the algorithm used by outlook express to encrypt the password for the stored accounts. (I lost the password for a very important account of mine ;-( ) Please help.
|
|
|
|
|
If I were you, I'd just request a new password from the mail provider.
There's little chance that the password is encrypted in a way that you can easily revert it to the original from what is stored, even if you knew the algorithm they use.
--
jlr
http://jlamas.blogspot.com/[^]
|
|
|
|
|
gecool wrote:
I was wondering what is the algorithm used by outlook express to encrypt the password for the stored accounts.
Outlook express doesn't encrypt the password when it store it, i myself retrieve it some time before but I forget how to do that!, I believe the Search should start from registry!
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
|
|
|
|
|
thankz, first... i figured out the key where the password is stored, but since i don't know the algorithm used i don't know how to decript it. It possible to do it since out there on www are available a bunch of appz destined to recover the outlook password. I just want to find out the encryption algorithm used to store
the password in the registry
|
|
|
|
|
gecool wrote:
I just want to find out the encryption algorithm used to store
the password in the registry
This Link Will Help
Accounts Password[^]
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
|
|
|
|
|
Did not ... but they (Micro$oft) weren't suppose to reveal their own secret, were they ?
|
|
|
|