QtUrl problem with Windows 7 - 64 bit



  • Our application is a 32 bit application . When it is installed in windows 7 64bit, typically it install at "C:\Program Files (x86)" location, instead of ""C:\Program Files". We are constructing a Url based on the install location and and pass it around as a part of web service.The way , we are constructing the Url is like this -
    ppmPath = "http://" + ipAddress + ":13007/" + folder + ".ppm" + "?filePath=" + applicationDirPath + "/" + FIRMWARE;
    QUrl ppmURL( ppmPath, QUrl::TolerantMode );
    ppmPath = QString( ppmURL.toEncoded() );

    The variable types and meaning are usual.
    Since "applicationDirPath" for Windows 7 64 bit contains one closing bracket ")" -for "(x86) substring - apparently the URL is broken. If we install it to any other location, it works perfectly, even though the location has any other special character.
    How to deal with ")" character in the URL , so that is is not broken ?



  • [quote author="vsthakur1" date="1352770236"]
    How to deal with ")" character in the URL , so that is is not broken ?
    [/quote]

    Have you tried adding backslash ("") before it? e.g. ")".
    There are instances that we need to add "" when dealing with special characters.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.