cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
bowbow13
Level 3

problem for default printer and values returned

Hello,
I devellope install file with installShield 2008. I have a few small problems to execute actions which I desperately need help, and I have great difficulty with this software.
These actions are:
_ Recover from the default printer (if there is one declared in Windows)
_ Capture values returned by the user in dialog case in order to put into differents files.

Can does one me explain or even give me an example or something else?

Thanking you in advance

ps: sorry for my English, i'm student French and i need help
Labels (1)
0 Kudos
(14) Replies
ChristopheOce
Level 7

Hi bowbow13 the french man !

for your second question, if you try to catch the value enter by the user in a control as a textbox for example, you must to create a custom action with some installscript or vb. There are several informations, and sample on this site..

tell me if you arrive to do this

Have a nice day
Christophe
0 Kudos
bowbow13
Level 3

Ok thank you for your answer christophe

I thought that there was a function integrated with IS 2008 to solve my problem.
Unaware of the VB, I will try to do so in C + +

Have a nice day
0 Kudos
ChristopheOce
Level 7

hi,

i think it's more easy in installscript, installscript is the language of installshield !

A very little and fast sample 🙂 !

crate a basic msi project, go to installscript, click right file and select new script file and copy paste this :


export prototype Hello(HWND);

function Hello(hMSI)
STRING sString;

begin
sString = " french man";
MessageBox("Hello " + sString, INFORMATION);
end:



Now go to custom action and sequence, click right custom action and select new install script. You can rename your custom action if you want.
Click on your custom action that you has just added, and for the property function name, select the installscript language function => Hello

Now place you custom in a sequence, place you custom action for install exec sequence property => installInitialize and for install exec condition => Not Installed
Not Installed means that you action "hello" will be fire if the product is not installed !

Try this, it's a very simply sample, now if you can display for example the value of some controls (textbox, ..) you must to get the value of them with the function

MsiGetProperty();


see sample in the doc or in this site !

Have a nice day
Christophe
0 Kudos
bowbow13
Level 3

Oh thanks
Thank you so much for your explanations as clear.
I think what you try me say this afternoon or tomorrow, but it will save very useful.

I wish you aware, I have tested, and I tell you, if I succeeded;)

Christophe thanks again
0 Kudos
bowbow13
Level 3

I would like to know that she file type must be created: this is a cpp or dll?
0 Kudos
ChristopheOce
Level 7

Hi,

No no, no need to create a file cpp or a dll dotnet !!!
Of course if you want you can create a dll and execute it while you install your product !

but installshield has a language => installscript !
As i said in my previous post, create a project test
type project => basic msi project

on the left pane go to behavior and logic, clic installscript
on installscript click right file and select new script file a file will be add.

Now you can write your first custom action as i show you in my last post !

If you want, you can send me a private mail and talk in french because i speak french also, and i give you a sample in a zip file.

Try..
Christophe
0 Kudos
bowbow13
Level 3

Excuse me, I did not do gaffe ... I am very sick for a week.

I created the installScript and I was the custom action but a erruer dll I appeared:
An error occurred ISSetup.dll streaming media file c: \ ..... \ IS2008 \ Redist \ 0809 \ i386 \ _isres.dll

It might come from bad configuration of my action in Behavior and Logic \ Custom Actions and Sequences \ Customs Actions
0 Kudos
ChristopheOce
Level 7

hm !

perhpas place your custom action between installinitialize and installfiniliaze in custom action and sequence !

in custom action and sequence, you have added a installscript function and selected the correct function name !?

but you message you received comes from installshield perhapas reboot your computer ! i don't know this message and i haven't seen it !


Christophe
0 Kudos
bowbow13
Level 3

The following steps will be made in Customs Actions:
Click right \ New installScript
Click on the right and I selected newCustomsActions1 Wizard CustomAction

In Type Action, I left Run InstallScript Code

Shares in Parameters, Source, Hello (name of the function)

Return Processing: Synchronous (Check exit code)

In Exection script: Immediate execution and Execution Sheduling: Always Execute

In Insert into Sequence: Install IU Sequence, I selected After InstallWelcome

Here is my response to the various choices proposed by IS2008, is it an error in my answers?
0 Kudos
bowbow13
Level 3

Yes .. I found or comes from the error. This file contains data made on the language of dialog boxes. That language is missing on the PC, it was normal that he can not find it.
However, when j'execute after InstallWelcome the script, the script must m'afficher hello french man in a messageBOx after the dialog installWelcome?
Because nothing is displayed
0 Kudos
ChristopheOce
Level 7

Yes !

now you can search on the help on installshield for to try what you can do !
there are several method as dotnet copyfile, write file, launch another exe, execute function dotnet, and so on !

Many things are possible with installshield but sometimes it enough hard to know how i can do it 🙂

Bon week end
Christophe
0 Kudos
bowbow13
Level 3

Ok thank you very much for your help
I will already try to retrieve the values of my text fields and after I will try to mettres in the appropriate files.

Who knows if I get one recroiseras not sure about this forum;)

Thanks again for your valuable assistance;)
0 Kudos
ChristopheOce
Level 7

don't mention it guys !

if you want to retrieve information about controls as textbox or other and write in a xml file for sample there are two ways :

a )use xml change view in the installshield left pane
b) use installscript function for to have the value (MsiGetProperty) and for to write there are some function as getline or writeline !

A bientot
Christophe
0 Kudos
julianfarnandez
Level 2

I have a problem with my default Epson printer and values returned. And I don't understand how to Resolve Epson WF-3640 Blurry Printing machine immediately. If you know how to solve this problem, please let us know.

0 Kudos