Did you saw the missing T in the word Session.Proper_y(... ?

Best regards,
Sebastian Brand
sebast...@instyler.com

Geisenfelder Str. 53a
85053 Ingolstadt, Germany
EU VAT ID: DE219712370
Phone: +49 841 4544567

www.instyler.com - Instyler Setup: Create WiX-based MSI installations,
elegantly.
www.traveladdin.com - Travel Add-in for Outlook: Add travel and return times
to your calendar.
www.sebastianbrand.com - blogging about software development, deployment and
productivity.




> -----Original Message-----
> From: Rich Daniel [mailto:rdan...@microsoft.com]
> Sent: Friday, January 15, 2010 02:41
> To: General discussion for Windows Installer XML toolset.
> Subject: [WiX-users] Help with setting properties from a JScript CA.
> 
> So, I've got this code that lets me know if certain databases are
installed or
> not:
> 
> function CheckDatabase(serverProperty, databaseProperty, checkProperty)
> {
>     var serverName = Session.Property(serverProperty);
>     var connectionString = "Provider=SQLOLEDB;Data Source=" + serverName
> + ";Integrated Security=SSPI";
>     var connection = new ActiveXObject("ADODB.Connection");
>     connection.Open(connectionString);
>     var databaseName = Session.Property(databaseProperty);
>     var command = "SELECT CASE WHEN DB_ID('" + databaseName + "') IS
> NULL THEN 0 ELSE 1 END";
>     var records = connection.Execute(command);
>     var exists = Number(records(0));
>     Session.Propery(checkProperty) = exists;
>     connection.Close();
> }
> 
> And it seems to work like a charm right up to the point I try to execute
> "Session.Propery(checkProperty) = exists;"
> At that point it hits me with a "script error -2146827850, Microsoft
JScript
> runtime error: Object doesn't support this property or method"
> 
> Is there something I'm missing or should I be taking a different approach
> entirely?
> 
> Thanks
> - Rich
> 
>
----------------------------------------------------------------------------
--
> Throughout its 18-year history, RSA Conference consistently attracts the
> world's best and brightest in the field, creating opportunities for
Conference
> attendees to learn about information security's most important issues
> through interactions with peers, luminaries and emerging and established
> companies.
> http://p.sf.net/sfu/rsaconf-dev2dev
> _______________________________________________
> WiX-users mailing list
> WiX-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wix-users


------------------------------------------------------------------------------
Throughout its 18-year history, RSA Conference consistently attracts the
world's best and brightest in the field, creating opportunities for Conference
attendees to learn about information security's most important issues through
interactions with peers, luminaries and emerging and established companies.
http://p.sf.net/sfu/rsaconf-dev2dev
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to