KiXforms Forum Index KiXforms
The Forum for the KiXforms Community
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
 Quick Links 
Site News
Downloads
Documentation
Donations
Script Archive
Tracking Systems

Kixform.NET installation question !

 
Post new topic   Reply to topic    KiXforms Forum Index -> KiXforms.NET Discussion
View previous topic :: View next topic  
Author Message
MACE1
KiXforms Enthusiast
KiXforms Enthusiast


Joined: 12 Oct 2004
Posts: 130
Location: Manchester UK

PostPosted: Tue Jul 24, 2007 8:10 am    Post subject: Kixform.NET installation question ! Reply with quote

Question Does .NET replace the kixforms.dll or add to it ?
The MSI can be installed using /quiet /norestart which is fine, but how do we test for version to keep it up to date etc. Don't actually know what is installed from the msi.
I currently use in the login script... and want to do similar with .net
Code:

;-------------------------------------------------------------------------------
;               Update and Registration of kixforms.dll & WKix32
;-------------------------------------------------------------------------------
$bin=READPROFILESTRING("%SCRIPTS%\logon.ini","TSKSTANDARD","bin")
if not exist("%SystemRoot%\system32\kixforms.dll")
    copy $bin + 'kixforms.dll' '%SystemRoot%\system32\'
else
    if getfileversion($bin + 'kixforms.dll') <> getfileversion('%SystemRoot%\system32\kixforms.dll') or
       (getfileversion($bin + 'kixforms.dll') = getfileversion('%SystemRoot%\system32\kixforms.dll') and
       val(getfileversion($bin + 'kixforms.dll', "SpecialBuild")) >       val(getfileversion('%SystemRoot%\system32\kixforms.dll', "SpecialBuild")) )
        copy $bin + 'kixforms.dll' '%SystemRoot%\system32\'
    endif
endif

if not exist("%SystemRoot%\system32\wkix32.exe")
    copy $bin + 'wkix32.exe' '%SystemRoot%\system32\'
else
    if getfileversion($bin + 'wkix32.exe') <> getfileversion('%SystemRoot%\system32\wkix32.exe')
        copy $bin + 'wkix32.exe' '%SystemRoot%\system32\'
    endif
endif

if exist("%SystemRoot%\system32\wkix32.exe")
 $ = WRITEVALUE ("HKEY_CLASSES_ROOT\.KX", "", "KX_auto_file", "REG_SZ")
 $ = WRITEVALUE ("HKEY_CLASSES_ROOT\.KIX", "", "KIX_auto_file", "REG_SZ")
 If KeyExist("HKEY_CLASSES_ROOT\Applications\ConTEXT.exe\shell\edit\command") = 1
  $EDITOR=READVALUE("HKEY_CLASSES_ROOT\Applications\ConTEXT.exe\shell\edit\command","")
 Else
  $EDITOR='%SystemRoot%\system32\notepad.exe "%1"'
 Endif
 If INGROUP("administrators")=1
   $ = WRITEVALUE ("HKEY_CLASSES_ROOT\KIX_auto_file\shell\edit\command", "", $EDITOR, "REG_SZ")
   $ = WRITEVALUE ("HKEY_CLASSES_ROOT\KIX_auto_file\shell\open\command", "", $EDITOR, "REG_SZ")
 ELSE
   $ = WRITEVALUE ("HKEY_CLASSES_ROOT\KIX_auto_file\shell\open\command", "", '%SystemRoot%\system32\wkix32.exe "%1" '+"%*", "REG_SZ")
   $ = WRITEVALUE ("HKEY_CLASSES_ROOT\KIX_auto_file\shell\edit\command", "", $EDITOR, "REG_SZ")
 ENDIF
Endif

$system = createobject("KiXtart.System")
if @error
    shell 'regsvr32 /s kixforms.dll'
    $system = createobject("KiXtart.System")
    if @error
        $_ = messagebox('You may not be a local administrator, make sure that you have appropriate rights on your system',
                        'Registration of Kixforms.dll failed - CONTACT AN ADMINISTRATOR IMMEDIATELY !',4112)
        quit 1
    endif
endif


________
Glass Weed Pipe


Last edited by MACE1 on Fri Feb 18, 2011 5:12 pm; edited 1 time in total
Back to top
View user's profile Send private message
Shawn
KiXforms Developer
KiXforms Developer


Joined: 22 Feb 2003
Posts: 1983
Location: Canada

PostPosted: Thu Jul 26, 2007 12:01 pm    Post subject: Reply with quote

The installer first un-installs any old version, than installs the new one. If the versions are the same - it will display the modify/remove instead. I just made some big changes to the installer - in the development build - will be posted shortly.

1) The installer defaults to ALLUSERS.

2) I stripped-down the user-interface (only one screen now)

3) The version is displayed in the "title" ie - it shows as Kixforms.Net xxx in Add/Removes.

In script, you can use the System.ProductVersion method to return the current Kixforms version number, etc:


?"Version=" + $System.ProductVersion
?"Major=" + $System.ProductVersion.Major
?"Minor=" + $System.ProductVersion.Minor
?"Build=" + $System.ProductVersion.Build
?"Revision=" + $System.ProductVersion.Revision

-Shawn
Back to top
View user's profile Send private message
MACE1
KiXforms Enthusiast
KiXforms Enthusiast


Joined: 12 Oct 2004
Posts: 130
Location: Manchester UK

PostPosted: Thu Jul 26, 2007 3:54 pm    Post subject: Reply with quote

Very Happy
Will look forward to it.
Will you have time to update the help files to match...?
________
MEDICAL MARIJUANA CARD


Last edited by MACE1 on Fri Feb 18, 2011 5:13 pm; edited 1 time in total
Back to top
View user's profile Send private message
Shawn
KiXforms Developer
KiXforms Developer


Joined: 22 Feb 2003
Posts: 1983
Location: Canada

PostPosted: Thu Jul 26, 2007 4:00 pm    Post subject: Reply with quote

I have been updating the help files as much as possible. Will be posting the new build within the hour ...
Back to top
View user's profile Send private message
MACE1
KiXforms Enthusiast
KiXforms Enthusiast


Joined: 12 Oct 2004
Posts: 130
Location: Manchester UK

PostPosted: Fri Jul 27, 2007 12:02 pm    Post subject: Reply with quote

The level of information I need is simply the version number of the DLL.
I have found the following to be the most practical for the time being...
Code:

$bin=READPROFILESTRING("%SCRIPTS%\logon.ini","STANDARD","bin")
$NET=READPROFILESTRING("%SCRIPTS%\logon.ini","STANDARD","net")

;----------------------Ensure Kixforms.Net installed on local machine --------------------
if not exist("%SystemRoot%\system32\kixforms.system.dll")
 If Exist ($bin + 'KiXforms_net.msi')
  shell "%systemroot%\system32\msiexec /i "+ $bin + 'KiXforms_net.msi /norestart /quiet'
  if not exist("%SystemRoot%\system32\kixforms.system.dll")
   Messagebox("KIXFORMS.NET could not install/update."+chr(10)+"Please Contact the ADMINISTRATOR","SEVERE ERROR",4112)
   Quit 1
  EndIf
 EndIf
else
 $DLL=getfileversion("%SystemRoot%\system32\kixforms.system.dll")
 If ($DLL <> $NET) and Exist($bin + 'KiXforms_net.msi'); Compare Version to logon.ini
  shell "%systemroot%\system32\msiexec /i "+ $bin + 'KiXforms_net.msi /norestart /quiet'
  if not exist("%SystemRoot%\system32\kixforms.system.dll")
   Messagebox("KIXFORMS.NET could not install/update."+chr(10)+"Please Contact the ADMINISTRATOR","SEVERE ERROR",4112)
   Quit 1
  EndIf
 Endif
Endif


It would really help if the MSI had the same queriable version as the DLL so I could omit the reading of the INI.
________
GIFT CARDS
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    KiXforms Forum Index -> KiXforms.NET Discussion All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group