Since the Text attribute does not accept properties I was hoping to use a
Custom Action to adjust the text based on the value of a bunch of public
properties. I was looking through the Wix
Tutorial(http://www.tramontana.co.hu) and found a Custom Action that was
changing some Text of a
ListBox(http://www.tramontana.co.hu/wix/lesson10.php).
Right now I'm starting simple. I was just trying to figure out how to set
the Text attribute of the ScrollableText Control with WcaAddTempRecord()
instead of a ListBox like in lesson 10. Is it possible to use
WcaAddTempRecord() to change the Text attribute? If so, then how? If not,
then are there any alternatives?
I am using Wix 2.0 and I linked the DLL I made with the WiX *.lib files and
the msi.lib file
Here is my broken code:
extern "C" UINT __stdcall FillListbox (MSIHANDLE hInstall) {
HRESULT hResult = WcaInitialize (hInstall, "testText");
if (FAILED (hResult)) return ERROR_INSTALL_FAILURE;
MSIHANDLE hTable = NULL;
MSIHANDLE hColumns = NULL;
hResult = WcaAddTempRecord (&hTable, &hColumns, L"ScrollableText", 0, 2,
L"{\rtf1\ansi\ansicpg1252\deff0\deflang1033{\fonttbl{\f0\fswiss\fcharset0
Arial;}}
\viewkind4\uc1\pard\f0\fs20 My Text\par}");
if (hTable)
MsiCloseHandle (hTable);
if (hColumns)
MsiCloseHandle (hColumns);
return WcaFinalize (hResult);
}
and here is my Dialog from my .wxs file:
...
<UI>
<Dialog Id="WelcomeDialog" Width="370" Height="270"
Title="[ProductName]
[Setup]" NoMinimize="yes">
<Control Id="Exit" Type="PushButton"
X="236" Y="243" Width="56" Height="17"
Disabled="no"
Default="yes" Text="Exit">
<Publish Event="EndDialog" Value="Exit" >1</Publish>
</Control>
<Control Id="FilledListbox" Type="ListBox"
Sorted="yes" Property="LISTBOXVALUES"
X="10" Y="50"
Width="200" Height="130" />
<Control Id="testText" Type="ScrollableText" Text="1"
X="10" Y="10"
Sunken ="yes" Disabled="no"
Width="300" Height="200">
</Control>
</Dialog>
</UI>
...
and here is the error i recieved in the log file:
testText: Error 0x8007064f: failed to open view on database
testText: Error 0x8007064f: failed to openexecute temp view with query
SELECT * FROM `ScrollableText`
I appreciate any information you can give me on how to use the
WcaAddTempRecord. Thank you!
--
View this message in context:
http://www.nabble.com/WcaAddTempRecord-with-ScrollableText-tf2142018.html#a5912684
Sent from the wix-users forum at Nabble.com.
-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
WiX-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/wix-users