Announcement

Collapse
No announcement yet.

Help with Saving Input Txt in Folder

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Help with Saving Input Txt in Folder

    Hello.

    Really just want to have a "SAVE YOUR WORK" button that allows the user to browse folders on their hard drive and save the text they typed in the "edit text field property" box.

    Once things are typed in, what actions should happen next? I've got the browse folders part, but stuck with how to get a "save as" going.
    Any help would be greatly appreciated.
    Thanks,
    M.[img]/ubbthreads/images/icons/cool.gif[/img]

  • #2
    Re: Help with Saving Input Txt in Folder

    Hi Michael, nice to see you back. TEXT FILE > WRITE to write your variable to a text file. (using an EDIT FIELD > GET TEXT to get the edit field contents into variable first)

    Corey Milner
    Creative Director, Indigo Rose Software

    Comment


    • #3
      Re: Help with Saving Input Txt in Folder

      Thanks, Corey. Been in DVD land for a while....

      What I would like to do is to save (write) the file to a folder and have the user, on coming back to the CD for further study, be able to pull up the file for appending, etc. while in AMS. One other thought is to have the corresponding question included "with" the text as well.

      I'll get to work on using your suggestions.

      Thanks,
      M.

      Hey, what is the word on the powertips CD you were working on?

      Comment


      • #4
        Re: Help with Saving Input Txt in Folder

        Powertips hit the dust chin first but we have a better, more improved series of training CDs due out in the next month or so...

        As for the text file thing, yep that's easily do-able. Check out the other text file actions and let us know if you need any help.

        Corey Milner
        Creative Director, Indigo Rose Software

        Comment


        • #5
          Re: Help with Saving Input Txt in Folder

          He had to drop it for now...I wish he would pick it back up! How about it Corey?

          Comment


          • #6
            Re: Help with Saving Input Txt in Folder

            You mean about the CD or the text file jazz?

            Corey Milner
            Creative Director, Indigo Rose Software

            Comment


            • #7
              Re: Help with Saving Input Txt in Folder

              Thanks.

              What I have now:
              button opens dialogue box and saves a ".txt" file, but the text itself is the address to the AMS file, not the typed text in the edit field. Strange. Appended action list:

              <IR_ACTIONS_LIST>
              <Action name="Get Text">
              <Variable>%Text1%</Variable>
              <ObjectName>Question1</ObjectName>
              </Action>

              <Action name="Write">
              <FileName>%SrcDir%\Question1</FileName>
              <DataToWrite>%SrcDir%\Question1</DataToWrite>
              <IfFileExists>2</IfFileExists>
              </Action>

              <Action name="Copy">
              <Source>%SrcDir%\Question1</Source>
              <Destination>%Desktop%</Destination>
              <DialogTitle>Copying Files</DialogTitle>
              </Action>

              <Action name="File Browse">
              <DefaultDirectory>%DeskTop%</DefaultDirectory>
              <DefaultFileName>Question1</DefaultFileName>
              <DefaultFileExtenstion>txt</DefaultFileExtenstion>
              <FileFilter>Text (*.txt)</FileFilter>
              <FileMustExist>1</FileMustExist>
              <Variable>%FullPath%</Variable>
              <DialogTitle>File Save</DialogTitle>
              </Action>
              </IR_ACTIONS_LIST>


              So, it's working except the typed text is not getting saved.

              Thanks for any help.
              M.[img]/ubbthreads/images/icons/cool.gif[/img]

              Comment


              • #8
                Re: Help with Saving Input Txt in Folder

                OK here's a sample file which has a text button and an edit field. Whenever you click the text button it appends a text file with whatever is in the edit field. (even if it's blank, which adds a blank line) The text file it writes to can be found at %TempDir%\MyText.txt (persistent after a restart) but you can change that easily, all the actions are on the "Add to file" button. http://www.indigorose.com/temp_web/appender.zip let me know if that helps or if the issue needs more clarification.

                Corey Milner
                Creative Director, Indigo Rose Software

                Comment


                • #9
                  Re: Help with Saving Input Txt in Folder

                  Excellent. Nicely done. and Thanks.

                  The last piece is to add the "save as" or open the save dialogue box instead of going to a temp dir. I changed the file now so that it's saving on the desktop, but I'm thinking that end users will need the opportunity to file away the text. (it works so efficiently, that the user won't know what happened.... [img]/ubbthreads/images/icons/smile.gif[/img] )

                  Can't seem to rework the actions to allow this. Where can I put this action in?

                  Thanks again.
                  M. [img]/ubbthreads/images/icons/cool.gif[/img]

                  Comment


                  • #10
                    Re: Help with Saving Input Txt in Folder

                    Instead of using %Temp% or %Desktop% just use a DIALOG > FOLDER BROWSE action on your apps first page to get the users choice of folder into a variable, i.e. %myFolder% and then just use that location in the TEXT FILE actions instead...

                    Corey Milner
                    Creative Director, Indigo Rose Software

                    Comment


                    • #11
                      Re: Help with Saving Input Txt in Folder

                      The CD

                      Comment


                      • #12
                        Re: Help with Saving Input Txt in Folder

                        close.....but still fumbling.

                        ".... to get the users choice of folder into a variable".

                        Can't seem to get the folder created as a variable. Is it possible to "create" a folder?

                        ....no cigar.

                        M.
                        Bruce?

                        Comment


                        • #13
                          Re: Help with Saving Input Txt in Folder

                          Forgive me if I'm missing something here but, "Folder/create" Save it some where unique and tell your end user where the folder now resides, or do as Corey suggested %MyFolder%

                          Comment


                          • #14
                            Re: Help with Saving Input Txt in Folder

                            New CDs are even better Bruce and they're on the way for sure.

                            As to the file thingy download it again from the above link, I have changed it to meet your needs, it now has a Folder Browse Dialog added to the page's OnShow event which customizes the folder destination.

                            Corey Milner
                            Creative Director, Indigo Rose Software

                            Comment


                            • #15
                              Re: Help with Saving Input Txt in Folder

                              Thanks, Corey.

                              That ought to wrap it up. The new version has the user selecting a folder first and really adds a nice touch. Your update was so simple, it was hard for me to see the solution as I got closer to the end of this project. You know, it's amazing that there are so many features to this software, that as soon as you get one aspect down (i.e., video playback on CD), there's always more that you can use to expand your project.

                              Not to mention your finding the interactivity between Flash, .exe's, and AMS, while you helped with my problem.

                              Cooler than a dancing banana.

                              Thanks!

                              M.[img]/ubbthreads/images/icons/cool.gif[/img]

                              Comment

                              Working...
                              X