Jump to content


This is a ready-only archive of the InstallSite Forum. You cannot post any new content here. / Dies ist ein Archiv des InstallSite Forums. Hier können keine neuen Beiträge veröffentlicht werden.
Photo

Loosing focus


3 replies to this topic

Submit

Submit
  • Members
  • 6 posts

Posted 13 February 2004 - 20:21

Hello

I had a serious problem:

I tried to install my application on a Win XP, and each time I tried to choose or write the Path I loose the focus.

This is my code, can you help please:

function DialogShowSdAskDestPath()
NUMBER nValidDir, nValid;
NUMBER nResult, nCount;
STRING szTitle, szMsg, szField1, svResult, svCutDir;
begin

StrSub( svCutDir, svDir, 1, 2 );
if( svCutDir == ":\\" ) then
svDir = "\\\\Server" ^ @PRODUCT_NAME;
endif;
nResult = SdAskDestPath( szTitle, szMsg, svDir, 0 );
// autres
else
StrSub( svCutDir, svDir, 0, 2 );
if( svCutDir == "\\\\" ) then
svDir = "C:\\" ^ @PRODUCT_NAME;
endif;
szTitle = "";
szMsg = "";
nResult = SdAskDestPath( szTitle, szMsg, svDir, 0 );
endif;

// Remove trailing backslashes if any
StrSub( svCutDir, svDir, StrLength(svDir)-1, 1 );
nCount = 0;
while( StrCompare( svCutDir, "\\" ) == 0 && nCount < 20 )
nCount = nCount + 1;
StrRemoveLastSlash( svDir );
StrSub( svCutDir, svDir, StrLength(svDir)-1, 1 );
endwhile;

//if( ExistsDir( svDir ) != 0 || svDir == "\\" ) then
if( svDir == "\\" ) then
// Display message
MessageBox( svDir + @ERROR_PATH, WARNING );
return AGAIN;
endif;

TARGETDIR = svDir;
return nResult;
end;


Help please

Taco Bell

Taco Bell

    IS6 Expert

  • Moderators
  • 1,281 posts

Posted 14 February 2004 - 03:52

First, the usual questions, are you using IS Pro 6.31 and have Windows XP selected in your project properties in order to properly support XP?
user posted image

Submit

Submit
  • Members
  • 6 posts

Posted 16 February 2004 - 14:51

Hi

No I have installshield 6.10


Thanks

Xitch13

Xitch13
  • Members
  • 134 posts

Posted 17 February 2004 - 16:20

Some caveats before I go into what might be wrong.
a. I've never programmed in 6.1, just 6.31 and later
b. I've haven't tried this change to see if it will work, just assuming it might help


OK, now on to the fix. I looked over the code several times before it hit me. You're using 'C' like conditional statements---- if (x ==y) then.

In IS you only need the one = sign. It both assigns variables and checks condition in statements.


Also, I'm not sure what you're AGAIN statement will do. I'm not familar with it, and didn't see anything on it in the HELP section.


Good luck
There is great chaos under heaven, and the situation is excellent. (Mao Tse Tung)