|
Hi ,
I want to read microsoft Performance counter objects details for the SQL server using C# .
I found the .dll ('sqlctr80.dll') for the same under the path:
%Programefiles%/Microsoft SQL Server\MSSQL\Binn
Now,I want to read this .dll for getting SQL server performance objects and relevant counters and instances for the particular objects.
any more assistance will be appreciated.
Thanks
pbrathod
Thanks in Advance,
pbrathod
|
|
|
|
|
Hi !!!
First of all i am sorry for deleting my question..Here still i have problem..look
In my Application,I created one dialog box..In this dialog box,I cretaed small 2 boxes.One is for list of Symbol ( text ) and second box is for preview of the drawing.
For exam:-
Box1: Box 2 ( preview )
Exchanger-Double end
Exchanger-Single end
Exchanger-Double end kettle
My requirement is,
If I will click on Exchanger-Double end ( box1) from dialog box then it will show me drawing of Exchanger-Double end ..If I will click on Exchanger-Single end
then it will show me preview of Drawing Exchanger-Single end.
My code is:-
BOOL CDwgPvDLG::OnInitDialog()
{
CDialog::OnInitDialog();
m_mytext.AddString(_T("Exchanger-Double end"));
m_mytext.AddString(_T("Exchanger-Single end"));
m_mytext.AddString(_T("Exchanger-Double end kettle"));
m_mytext.SetCurSel(0);
mydwg = _T("C:\\Symbol\\Exchangers\\Exchanger_1_i.dwg");
return TRUE;
}
void CDwgPvDLG::OnPaint()
{
CDwgPreview ::ShowInDialog (mydwg,this,IDC_PVTYP);
CPaintDC dc(this);
}
void CDwgPvDLG::OnselectionchangeList()
{
int nEntry = m_mytext.GetCurSel();
switch (nEntry)
{
case 0:
mydwg = _T("C:\\Symbol\\Exchangers\\Exchanger_1_i.dwg");
break ;
case 1:
mydwg = _T("C:\\Symbol\\Exchangers\\Exchanger_2_i.dwg");
break ;
case 2:
mydwg = _T("C:\\Symbol\\Exchangers\\Exchanger_3_i.dwg");
break;
}
}
Anybody know How can I do it ??
Thanking you..
Shah
|
|
|
|
|
See, u handle the selection event of the list, and upon notifying, draw the things in the other box.
Where the problem is?
Come online at:-
jubinc@skype
|
|
|
|
|
Shah Satish wrote: // this is class for Preview of the drawing. CDwgPreview ::ShowInDialog (mydwg,this,IDC_PVTYP);
What does this function do ?
Have considered the fact that, you need to invalidate the rectangle , before drawing to it ?
Can you be clear about your problem ?
|
|
|
|
|
Hi,
i use the BitmapPicture from Chris Maunder.
I like to add a click possibility.
A ON_WM_LBUTTONDOWN() Handler does not work.
BitmapPicture is a CStatic derived control.
How can i send a Message to the Parent, where can i catch the click?
Thanks
|
|
|
|
|
I show u the steps involved in Static control notification:-
In the dialog resource, add a Static Control. Go to the property of Static control and select Styles tab. There, Notify check box is there, check it. Then to to its events and select, BN_CLICKED.
This way, u will receive the notification from the Static Control. By default, Static Control does not send any notification to Parent.
Note:- If u want only WM_LBUTTONDOWN, then deriving a class from CStatic is not needed.
Come online at:-
jubinc@skype
|
|
|
|
|
You need to select Notify property for static control.
|
|
|
|
|
|
Did you set Notify for your control?
|
|
|
|
|
It was for a control, which is setted without the Ressource-Designer.
But i changed the Styles via programmation :
Slide = new CBitmapPicture();
Slide->Create("",WS_CHILD | WS_VISIBLE,rect,this,ID_SLIDE);
Slide->SetBitmap(IDB_SLIDEBAR);
Slide->ModifyStyle(0,SS_NOTIFY);
|
|
|
|
|
I think your problem must solved,right;)
|
|
|
|
|
I need to be able to find the special folders (e.g. My Documents) for a user other than the one currently logged on.
The best I've been able to come up with so far is to use NetUserEnum() to get a list of all the users on the machine and check the HKEY_USERS\***\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders registry key (where *** is the user's SID).
Peeking into the registry like this is a bit kludgy so is there a better way?
0 bottles of beer on the wall, 0 bottles of beer, you take 1 down, pass it around, 4294967295 bottles of beer on the wall.
Awasu 2.2.4 [^]: A free RSS/Atom feed reader with support for Code Project.
|
|
|
|
|
Other way is, get the folders present in "C:\Documents and Settings\". 'Cuz each and every user account on the system has folders (of username) in this path.
Come online at:-
jubinc@skype
|
|
|
|
|
Doesn't work on NT nor Vista.
Doesn't work on non-English versions of Windows since that directory will be named differently.
It also won't work if the special folders have been redirected to elsewhere.
0 bottles of beer on the wall, 0 bottles of beer, you take 1 down, pass it around, 4294967295 bottles of beer on the wall.
Awasu 2.2.4 [^]: A free RSS/Atom feed reader with support for Code Project.
|
|
|
|
|
Taka Muraoka wrote: I need to be able to find the special folders (e.g. My Documents) for a user other than the one currently logged on.
That's what the third argument to SHGetFolderPath() is for.
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
DavidCrow wrote: That's what the third argument to SHGetFolderPath() is for.
Doesn't work for me, unfortunately. You need the user's password to get a token.
0 bottles of beer on the wall, 0 bottles of beer, you take 1 down, pass it around, 4294967295 bottles of beer on the wall.
Awasu 2.2.4 [^]: A free RSS/Atom feed reader with support for Code Project.
|
|
|
|
|
Then just query the registry. For each user, query the following registry key:
HKEY_USERS\<SID of user>\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
Well, that's what I wrote in my original post but it seems a bit of a clunky way of getting the info I need so I was just asking if there was a better way.
Thanks anyway
0 bottles of beer on the wall, 0 bottles of beer, you take 1 down, pass it around, 4294967295 bottles of beer on the wall.
Awasu 2.2.4 [^]: A free RSS/Atom feed reader with support for Code Project.
|
|
|
|
|
[Message Deleted due to spam]
|
|
|
|
|
|
[Message Deleted due to spam]
|
|
|
|
|
The system wouldn't recognize your memory as a disk.
I don't know of any CRT library functions or OS APIs that will run a process froma memory
image.
Are you trying to speed up startup time of the other process?
|
|
|
|
|
[Message Deleted due to spam]
|
|
|
|
|
I don't know how it could be done. I would imagine the main reason there's no API to do it is
because it's a huge security risk. It's an easy way to run a virus.
|
|
|
|
|