|
I created two projects, whose names are same
How to know their pathes respectively
(VC6)
|
|
|
|
|
U can use GetModuleFileName
Arjan.
|
|
|
|
|
Hi,
use GetModuleFileName(NULL, Buffer, BufferLength);
Regards
Frank
|
|
|
|
|
Yeah,
sorry
but you have mistaken my meaning
I want to know the path through Microvisual Studio 6.0 window not by programming
that is,look at Microvisual Studio 6.0 interface on computer screen and then know the path of my project
Have I expressed my meaning clear?
|
|
|
|
|
Go into the fileview (the third tab, near ressource), right-click the workspace name and choose properties.
~RaGE();
|
|
|
|
|
Thank you!
Now I know the way
I think that
it is not very easy
and the microsoft corps should show the path at a more outstanding position
thank you again!
|
|
|
|
|
You can also just right click any editor window and select "Properties" from the popup menu.
/ravi
Let's put "civil" back in "civilization"
Home | Articles | Freeware | Music
ravib@ravib.com
|
|
|
|
|
Hi to everybody!
Is somebody knows, how can i listen to specific pin notification of a Serial Port or a Parallel Port ?
|
|
|
|
|
I have written an MDI application.
I wolud like to create on the desktop of my application
an hyperlink to my web page
How can I do this?
I'm able to create an hyperlink in the dialog box but I'm
not able to create it on the desktop of my application
|
|
|
|
|
What do you mean with the desktop of your application ? If it is in the toolbar, then you would consider using a rebar, with Chris' CHyperLink control.
~RaGE();
|
|
|
|
|
|
I want to start DirectX programming. I get the SDK and samples with it, but I want some tutorial about how to begin. The document with the SDK is not good for beginnig.
Mazy
No sig. available now.
|
|
|
|
|
IMHO, compared with what is available on the net, the SDK samples are not bad for getting started. There is a DirectX forum at <www.gamedev.net> You'll probably get more leads to tutorials from the posters there.
Good Luck with DirectX!
-Roger
|
|
|
|
|
Thanks Roger. I find GameDev.net forum.
Mazy
No sig. available now.
|
|
|
|
|
Here are some code about DeviceIoControl:
BTemp=DeviceIoControl
(
hDrive, // handle to device
IOCTL_STORAGE_CHECK_VERIFY, // dwIoControlCode operation
NULL, // lpInBuffer; must be NULL
0, // nInBufferSize; must be zero
NULL, // lpOutBuffer; must be NULL
0, // nOutBufferSize; must be zero
&BytesReturned, // number of bytes returned
NULL // OVERLAPPED structure
);
this function "DeviceIoControl" is to check whether the floppy disk has been changed(If the function succeeds, the return value is nonzero.If the function fails, the return value is zero.)
Something wrong happens here:
BTemp is a minus when I test on a wrong floppy device which does not work well while it is plus when on a work-well floppy device
does this mean that a returned minus value says the floppy device is error?
|
|
|
|
|
Hi All,
I have a webbrowser object and I want to open the new window link in same parent window and not let the child window to open. I searched for new window method and found it as..OnNewWindow2(LPDISPATCH FAR* ppDisp, BOOL* Cancel)..where assigning cancel to to non zero value does the job of letting open the IE in new window..but I dont know how to get it to navigate to the link user has clicked on...I found an example in VB but that takes in the parameter as URL and in VC..i wasnt able to find any such method..I need it to be done..can anyone out there help me out..any help or pointers are highly appreciated..Thanks a lot in advance..
Himanshu
|
|
|
|
|
When I add information to access table ,I use this code !
set.m_access_attribute = GetDlgItemInt (IDC_EDIT1);
How can I warn to fill edit box if it is forgotten ?
emroz
|
|
|
|
|
GetDlgItemInt has two more parameters. The actual syntax is: UINT GetDlgItemInt( int nID, BOOL* lpTrans = NULL, BOOL bSigned = TRUE ) const;
If the edit box doesn't contain a valid numeric value then pTrans would become 0.
BOOL pTrans;
int iValue = GetDlgItemInt( IDC_EDIT1, &pTrans );
if( pTrans == 0 )
AfxMessageBox( "Please enter a numerical value!");
else
set.m_access_attribute = iValue;
I haven't tried to compile the code so it might contain errors.
Another way is to force the edit box accept only integers and that can be done in the resource editor. Right-click on the edit box, select properties, and then in the styles tab select Number.
// Afterall, I realized that even my comment lines have bugs
When one cannot invent, one must at least improve (in bed).-My latest fortune cookie
|
|
|
|
|
how is it done when using a dialog with a toolbar?
thanks
|
|
|
|
|
If your program is dialog based, then how did you attach a toolbar to it?
Anyways, since you didn't accept the answer from Eugene (sorry if I misspelled the name), then you can try something like this (only if the toolbar is dialog based):
GetDlgItem( IDC_TOOLBAR_ITEM )->EnableWindow( TRUE );
// Afterall, I realized that even my comment lines have bugs
When one cannot invent, one must at least improve (in bed).-My latest fortune cookie
|
|
|
|
|
i didnt accept Eugenes answer becuase i couldnt figure out how to get the commandui function
|
|
|
|
|
also your answer doesnt work
|
|
|
|
|
In Visual C++ 6.0, when I set Directory list in menu "Tools->Options...->Directories", the Directory list is used for every project. If I open new project, I must enter new Directory list. How can I set the Directory list for each project? I'm boring to set new Directory list every time I open new project.
|
|
|
|
|
Hi,
use your project-settings.
For include files: project-settings -> C/C++ -> Preprocessor : "Additional include directories"
For Lib files: project-settings -> Link -> Input : "Additional library path"
HTH
Regards
Frank
|
|
|
|
|
I want to control 'richedit sting color'.
Fisrt step,,,,
I used CRicheditCtrl member,,,,
I accessed directly RTF-formated string.
and,select string,and set RTF-formated string.
because of selecting string,the program affect scroll bar and cursor.
ofcourse,I can used CRichEditCtrl::SetSel.But For a moment, the selection range flickers.
Second Step,,,
I used ITextRange member,,,,
But A program needs to convert "CString(char*)-index" to "CRichEditCtrl(GetSel)-index", in order to use a member.
How do I convert "CRichEditCtrl::GetSel index" to "CString(char*) index"?
or
How do I convert "CString(char*) index" to "CRichEditCtrl::GetSel index"?
Please help me.
|
|
|
|