title
Products            Buy            Support Forum            Professional            About            Codec Central
 

dbpoer amp and MS Access

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • christopherhall
    • Mar 2007
    • 8

    dbpoer amp and MS Access

    Hi I am trying to use dbpoweramp in connection with MS Access.

    I have a script which runs the following line of code only when it reaches this point I get the message:

    Object doesn't support this property or method

    Is there a reference in Access that I am missing?

    Here is the line of code:

    dMC = CreateObject("dMCScripting.Converter")


    Thanks

    Chris
  • Deano
    dBpoweramp Enthusiast
    • Jan 2006
    • 130

    #2
    Re: dbpoer amp and MS Access

    dMC is an object, thus you'll need to use the VBScript keyword "Set". So the line will need to be:

    Set dMC = CreateObject("dMCScripting.Converter")

    Comment

    • christopherhall
      • Mar 2007
      • 8

      #3
      Re: dbpoer amp and MS Access

      Thanks for that Deano,

      Now another, what I hope is an easy question.

      I am calling the following line of code:

      Call dMC.Convert(oFile, "Test_MP3_To_WMA_Result\" & Left(oFile.Name, Len(oFile.Name) - 3) & "wma", "mp3 (Lame)", "-b=128", "")

      The aim is to convert each mp3 file in a folder to wma.

      This runs without any errors although it does not create the wma file.


      Thanks

      Chris

      Comment

      • christopherhall
        • Mar 2007
        • 8

        #4
        Re: dbpoer amp and MS Access

        I have tried running this mannually using dbpowerAmp but am getting the following message:

        The CODEC required to compress 'D:\Test_MP3_To_WMA_Result\2474_1_3_clip.wma' could not be opened.

        Comment

        • LtData
          dBpoweramp Guru
          • May 2004
          • 8288

          #5
          Re: dbpoer amp and MS Access

          Did you install the WMA codec into dMC?

          Comment

          • christopherhall
            • Mar 2007
            • 8

            #6
            Re: dbpoer amp and MS Access

            Yes,

            I can run it through the dppowerAmp front End but when I try to run it using code it does not work?

            Chris

            Comment

            • christopherhall
              • Mar 2007
              • 8

              #7
              Re: dbpoer amp and MS Access

              OK,

              I have started again from scratch, with a simpler script.

              Here is what I have:

              Code:
              Function conMp3()
              
              Dim dMC
              
                          Set dMC = CreateObject("dMCScripting.Converter")
                          newFile = "D:\Test_MP3_To_WMA_Result\2474_1_0_clip.mp3"
                          Call dMC.Convert("D:\Test_MP3_To_WMA\2474_1_0_clip.mp3", newFile, "mp3 (Lame)", "-b=128", "")
              
              End Function
              When I run this it gets to the line:

              Code:
              Call dMC.Convert("D:\Test_MP3_To_WMA\2474_1_0_clip.mp3", newFile, "mp3 (Lame)", "-b=128", "")
              And gives the error message:

              Object doesn't support this property or method


              Any help would be great.


              Chris

              Comment

              • Spoon
                Administrator
                • Apr 2002
                • 43888

                #8
                Re: dbpoer amp and MS Access

                >Call dMC.Convert(oFile, "Test_MP3_To_WMA_Result\" & Left(oFile.Name, Len(oFile.Name) - 3) & "wma", "mp3 (Lame)", "-b=128", "")

                You are converting to mp3, but giving the file with a .wma extension...You need instead of "mp3 (Lame)", "Windows Media Audio v10" (you will have to look at the help file for wma how to extract the wma command line.
                Spoon
                www.dbpoweramp.com

                Comment

                • LtData
                  dBpoweramp Guru
                  • May 2004
                  • 8288

                  #9
                  Re: dbpoer amp and MS Access

                  Did you try looking at the examples here: http://www.dbpoweramp.com/developer-scripting-dmc.htm ?

                  Moved to the Developer section of this forum

                  Comment

                  • christopherhall
                    • Mar 2007
                    • 8

                    #10
                    Re: dbpoer amp and MS Access

                    Thanks for your replies.

                    I have changed the code so that it is trying to change an mp3 into an mp3.

                    Code:
                    Dim dMC
                    
                                Set dMC = CreateObject("dMCScripting.Converter")
                                newFile = "D:\Test_MP3_To_WMA_Result\2474_1_0_clip.mp3"
                                Call dMC.Convert("D:\Test_MP3_To_WMA\2474_1_0_clip.mp3", newFile, "mp3 (Lame)", "-b=128", "")
                    However when I try to run this script I am getting the message:

                    Object doesn't support this property or method.


                    Any ideas.

                    Chris

                    Comment

                    • christopherhall
                      • Mar 2007
                      • 8

                      #11
                      Re: dbpoer amp and MS Access

                      Hi,

                      Sorry about this but does anyone have any ideas?

                      It could be a show stopper and I will have to move away from dbpowerAmp


                      Chris

                      Comment

                      • Spoon
                        Administrator
                        • Apr 2002
                        • 43888

                        #12
                        Re: dbpoer amp and MS Access

                        Tried using the code here unchanged (except for filenames)?

                        Spoon
                        www.dbpoweramp.com

                        Comment

                        • christopherhall
                          • Mar 2007
                          • 8

                          #13
                          Re: dbpoer amp and MS Access

                          Hi,

                          Yes I have tried that. One of the first things that I had to do was to put SET infront of dMC = CreateObject("dMCScripting.Converter").

                          That now works but when I try to CALL dMC.Convert I am getting an error.


                          Chris

                          Comment

                          • bhoar
                            dBpoweramp Guru
                            • Sep 2006
                            • 1173

                            #14
                            Re: dbpoer amp and MS Access

                            EDIT:

                            0. Try it without the "Call " prefix and see if that makes a difference.

                            If not...

                            1. Does this file really exist at this filepath? "D:\Test_MP3_To_WMA\2474_1_0_clip.mp3"

                            2. Does this directory really exist at this path: "D:\Test_MP3_To_WMA_Result"

                            3. Does the current user have read privileges in the input directory?

                            4. Does the current user have write privileges in the output directory?

                            -brendan

                            Comment

                            Working...

                            ]]>