cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Dmitry_Bond
Level 2

DLL functions not working properly in IS 2012!

Hi.

We are investigating question if we could migrate to new InstallShield version from the very old one (v.11).
But I have faced very strange problem - the DLL function call which was working fine in the InstallShield 11 is working in a wrong way in InstallShield 2012 Professional!

In particular here is function header from IS script:

prototype string InstUtil.GetPropertyValue(byval string, byval string, byval number);

Here is a piece of code of IS script:

sz = GetPropertyValue("DiskSize,mb", svResult, -1);
diskCapacity = StrToNumDef(sz, -1);


In the log file generated by DLL I can see:

[FONT="Courier New"]174037.024 [P3344|INFO] GetPropertyValue("DiskSize,mb", "C:", -1)
174037.024 [P3344|INFO] GetPropertyValue: Result="42939"
[/FONT]

But the debug message from InstallShield 2012 script is showing this:

---------------------------
SW Server 2010.2 - InstallShield Wizard
DEBUG: DiskSize,Mb = ㈴㌹9嵽2, capacity=-1
---------------------------

As you can see - the "42939" string was screwed up to the "㈴㌹9嵽2".

So, for sure function was called and it was returned correct result value.
But the InstallShield 2012 was screwed up value somewhere inside. 😞

Can you see any reasons - WHY?!

Regards,
Dmitry.
Labels (1)
0 Kudos
(4) Replies
MichaelU
Level 12 Flexeran
Level 12 Flexeran

It sounds like you might need to look at the migration articles. I'd focus in particular at the IS2011 one, where we improved InstallScript's support and use of Unicode strings and APIs. (This symptom looks a lot like an ANSI string being interpreted as a Unicode one.)
0 Kudos
Dmitry_Bond
Level 2

MichaelU wrote:
It sounds like you might need to look at the migration articles. I'd focus in particular at the IS2011 one, where we improved InstallScript's support and use of Unicode strings and APIs. (This symptom looks a lot like an ANSI string being interpreted as a Unicode one.)


Could you please post links to articles you mentioned?

Or at least - what is option name to change to make it use ANSI encoding instead of unicode?
0 Kudos
DebbieL
Level 17

The Read Me First sticky (http://community.flexerasoftware.com/showthread.php?t=201579) in the forum has links.

Note that InstallShield 2012 and InstallShield 2012 Spring are two different versions. This thread is in the InstallShield 2012 Spring forum. If you are using InstallShield 2012, you'll probably want to look at the sticky in the InstallShield 2012 forum:
http://community.flexerasoftware.com/showthread.php?t=198772

I hope that helps.
0 Kudos
mallikarjuna_y
Level 2

Hi All,

I am also facing same issue with IS2012.

How can we get host name in IS2012, is there any IS variable/function to get this.

Also, how to convert UNICODE to ASCII...

Thanks in advance....
Mallikarjuna
0 Kudos