Click here to Skip to main content
15,900,378 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Beginner's Question Pin
UKM_Student11-Sep-09 3:31
UKM_Student11-Sep-09 3:31 
GeneralRe: Beginner's Question Pin
Richard MacCutchan11-Sep-09 3:25
mveRichard MacCutchan11-Sep-09 3:25 
GeneralRe: Beginner's Question Pin
CPallini11-Sep-09 3:14
mveCPallini11-Sep-09 3:14 
GeneralRe: Beginner's Question Pin
UKM_Student11-Sep-09 3:19
UKM_Student11-Sep-09 3:19 
GeneralRe: Beginner's Question Pin
UKM_Student11-Sep-09 3:32
UKM_Student11-Sep-09 3:32 
QuestionDetecting identical path names Pin
Mattias G11-Sep-09 1:08
Mattias G11-Sep-09 1:08 
AnswerRe: Detecting identical path names Pin
Randor 11-Sep-09 1:30
professional Randor 11-Sep-09 1:30 
GeneralRe: Detecting identical path names Pin
Mattias G11-Sep-09 1:36
Mattias G11-Sep-09 1:36 
GeneralRe: Detecting identical path names Pin
Randor 11-Sep-09 1:40
professional Randor 11-Sep-09 1:40 
GeneralRe: Detecting identical path names [modified] Pin
Mattias G11-Sep-09 2:07
Mattias G11-Sep-09 2:07 
GeneralRe: Detecting identical path names Pin
David Crow11-Sep-09 3:40
David Crow11-Sep-09 3:40 
GeneralRe: Detecting identical path names Pin
Randor 13-Sep-09 0:19
professional Randor 13-Sep-09 0:19 
GeneralRe: Detecting identical path names Pin
Member 419459314-Sep-09 9:21
Member 419459314-Sep-09 9:21 
GeneralRe: Detecting identical path names Pin
Mattias G14-Sep-09 22:53
Mattias G14-Sep-09 22:53 
Thanks for the input. Have been trying IShellItem::Compare, but can't get that to work unless files on the same share are specified the same way (\\share\path or X:\path). IShellItem::Compare can handle differences in case, however. I'm using SHCreateShellItem to create the objects, and that call fails if I'm using a relative path such as \\share\bohoo\tada\..\tada\file.txt. As always, this could be due to user incompetence on my side, so feel free to check this one for errors:

// ...
PIDLIST_ABSOLUTE pid1; 
PIDLIST_ABSOLUTE pid2; 
IShellItem* itm1;
IShellItem* itm2;

pid1 = ILCreateFromPath(szPath);
SHCreateShellItem(NULL, NULL, pid1, &itm1);
ILFree(pid1);

for(unsigned i = 0; i < m_rgGlossaries.size(); i++){
	BSTR strPath;
	// ...
	pid2 = ILCreateFromPath(strPath);
	SysFreeString(strPath);
	SHCreateShellItem(NULL, NULL, pid2, &itm2);
	ILFree(pid2);
	itm1->Compare(itm2, SICHINT_ALLFIELDS, &nCmpResult);
	itm2->Release();
	if(nCmpResult == 0){
		AfxMessageBox(_T("Hurrah"));
		// ...
	}
}

// ...


Eagerly awaiting suggestions. Would prefer not to do lots of conversions and resolving on my own.
GeneralRe: Detecting identical path names Pin
Member 419459315-Sep-09 9:31
Member 419459315-Sep-09 9:31 
GeneralRe: Detecting identical path names Pin
Randor 16-Sep-09 2:09
professional Randor 16-Sep-09 2:09 
GeneralRe: Detecting identical path names Pin
Member 419459316-Sep-09 5:48
Member 419459316-Sep-09 5:48 
QuestionIs There a way to set WS_EX_RTLREADING style only to some columns of ClistCtrl Pin
A&Ms11-Sep-09 0:34
A&Ms11-Sep-09 0:34 
Questionvisual studio WINAPI directive Pin
FotisSs11-Sep-09 0:15
FotisSs11-Sep-09 0:15 
AnswerRe: visual studio WINAPI directive Pin
CPallini11-Sep-09 0:51
mveCPallini11-Sep-09 0:51 
AnswerRe: visual studio WINAPI directive Pin
Stuart Dootson11-Sep-09 1:02
professionalStuart Dootson11-Sep-09 1:02 
QuestionHow to make image in a rich edit? Pin
mr bard210-Sep-09 23:42
mr bard210-Sep-09 23:42 
AnswerRe: How to make image in a rich edit? Pin
Mattias G11-Sep-09 1:01
Mattias G11-Sep-09 1:01 
GeneralRe: How to make image in a rich edit? Pin
mr bard211-Sep-09 23:39
mr bard211-Sep-09 23:39 
AnswerRe: How to make image in a rich edit? Pin
Nuri Ismail11-Sep-09 2:29
Nuri Ismail11-Sep-09 2:29 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.