Change \ with / - Advanced Installer Community

We’re moving our forums to a new platform.

You can still browse and search existing topics, but you can no longer create new topics or post replies.

For questions, technical issues, or feature requests, please don’t hesitate to contact our support team at support@advancedinstaller.com.

Thank you for your understanding!

cagura
Posts: 10
Joined: Thu Feb 08, 2007 3:44 pm

Change \ with /

I am wanting to change the \ in the APPDIR to be / instead. Having the \ messes up the Java Application when I am inserting into a ini file.

I need to know how to do this exactly. I think I need to do a custom action and also set a Registry thing or something. Could someone help please?

Charles Gura
cagura
Posts: 10
Joined: Thu Feb 08, 2007 3:44 pm

I found the solution, here is what I ended up doing. I created a Custom Action and put it Before Finalize and before the ini file is created.

Code: Select all

Function Main 
   Dim appDir
   appDir = Session.Property("APPDIR") 
   appDir = Replace(appDir, "\", "/", 1, -1, 1) 
   Session.Property("INSTPATH") = appDir 

End Function 
Hope this helps others.

Return to “Common Problems”