My bad, you're right. I was going through the source, and I didn't realize
they were all just overrides.
Please sir, forgive me. :-) It was a fit of pique, not a serious
complaint.
Chris
On Wed, May 21, 2008 at 3:19 PM, Jason Ginchereau <[EMAIL PROTECTED]>
wrote:
> If the RecordStream class was public, what could you do that you can't do
> now?
>
>
>
> Note that Record.GetStream() or Record.Item on a stream field actually does
> return a RecordStream instance, it just calls it a plain Stream because you
> shouldn't need to care what kind of Stream it is. Every single
> property/method in RecordStream is just overriding the Stream member, so
> there's nothing there that isn't callable.
>
>
>
> *From:* [EMAIL PROTECTED] [mailto:
> [EMAIL PROTECTED] *On Behalf Of *Christopher Karper
> *Sent:* Wednesday, May 21, 2008 12:13 PM
> *To:* Christopher Painter
> *Cc:* wix-users@lists.sourceforge.net
> *Subject:* Re: [WiX-users] DTF Stream Operations Issue
>
>
>
> Shouldn't matter. I can get the data to and from the file with no issue.
> It's just trying to get the data into the memorystream instead f the
> filestream is an issue.
>
> The RecordStream object in DTF looks like it might be useful, but in
> typical MS fashion, the useful foundation classes are internal instead of
> public, LOL.
>
> I appreciate your help. I'll just keep banging on it from here.
>
> Chris
>
> On Wed, May 21, 2008 at 3:01 PM, Christopher Painter <[EMAIL PROTECTED]>
> wrote:
>
> Ok, I was wondering how you were going to read binary data into a string.
> I'm not the best C# guy in the world but I'll see what I can learn here. I
> am wondering though, is your text unicode or ansi and would it even
> matter?
>
>
>
>
>
>
> *Christopher Karper <[EMAIL PROTECTED]>* wrote:
>
> It's text, and I'm running as a custom action, so my database should
> already be available.
>
> I'm opening the view with a joined query, but getting the same data. I can
> get the record fine, and I can get the stream fine, it's when I try to read
> from the StreamReader wrapper that I run into issues.
>
>
> I'm trying to read out the text data stored in the binaries table, then
> modify it. I'm trying to avoid using a temp file if I can, since I only
> need it in memory.
>
> Chris
>
> On Wed, May 21, 2008 at 2:41 PM, Christopher Painter <[EMAIL PROTECTED]>
> wrote:
>
> What is the type of script?
>
>
>
> Eitherway, would this work for you?
>
>
>
> Database db = new Database("C:\\TEST.MSI", DatabaseOpenMode.ReadOnly);
>
> View view = db.OpenView("SELECT `Name`, `Data` From `Binary` WHERE
> `Binary`.`Name` = 'ISXMLCFG.DLL'");
>
> view.Execute();
>
> foreach (Record rec in view) using (rec)
>
> {
>
> Stream stream = rec["Data"] as Stream;
>
> }
>
>
>
>
>
>
>
> *Christopher Karper <[EMAIL PROTECTED]>* wrote:
>
> I'm trying to read binary data into a memory stream, but
>
> Stream stream = binRec.GetStream("Data");
> using (StreamReader sr = new StreamReader(stream))
> {
> script += sr.ReadToEnd();
> }
>
>
>
> Gives me an ArgumentNullException when I try to read the stream. Am I
> missing a step?
>
>
> Is this stream not compatible with a streamreader?
>
> Chris
>
> -------------------------------------------------------------------------
> This SF.net email is sponsored by: Microsoft
> Defy all challenges. Microsoft(R) Visual Studio 2008.
>
> http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/_______________________________________________
> WiX-users mailing list
> WiX-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wix-users
>
>
>
>
>
>
>
>
>
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users