Site Search:
Sign in | Join | Help

Dynamics GP

Notes, Tips and Tricks on Developing in Dynamics GP
  • Problems with Integration Manager reading XML document attributes

    A client recently called with an issue with importing an XML file using Integration Manager (IM). Apparently, IM can't read the attributes in an XML document. After trying for a while to get it to work, we decided to write a small application that would parse the XML file and move the attributes to nodes.

    That effort is documented in our VB.NET/XML blog, here:

    http://devshed.us/Blogs/tabid/227/EntryId/407/XmlDocument-Loop-through-a-document-and-move-an-attribute-to-a-node.aspx 

     

  • Code to display tax schedules

    I recently had to do some work against tax schedules at a client, I needed to quickly see the tax schedules. Here is code to display the tax rate for one tax schedule, and for all of them.

    The result will look something like this:

    To get one tax schedule, I wrote a function:

     -- =============================================
    -- Written by 4Penny.net
    -- 941-747-3669
    -- =============================================
    
    
    IF EXISTS (SELECT * 
        FROM   sysobjects 
        WHERE  name = N'f_4P_taxAmount')
     DROP FUNCTION f_4P_taxAmount
    GO
    
    
    CREATE FUNCTION f_4P_taxAmount ( @taxschid varchar(15))
    --  select ngb01.dbo.f_4P_taxAmount('dekalb')
    
    
    Returns money
    
    
    AS
    begin
     declare @out money
     set @out = 0
     
     select @out = sum(tx00201.txdtlpct)
      from tx00102 with (nolock)
       left join tx00201 with (nolock) on tx00201.taxdtlid = tx00102.taxdtlid 
      where taxschid = @taxschid
    
    
     return (@out)
    end
    go
    grant all on f_4P_taxAmount to public
    
    
    
     

    Then we can call the function from a query to get all the tax schedules: 

    select t.taxschid, t.txschdsc, dbo.f_4P_taxAmount(t.taxschid)
     from tx00101 t (nolock)
     order by t.taxschid

  • You do not have sufficient privileges on this system to modify the VBA project

    You do not have sufficient privileges on this system to modify the VBA project

    Wonderful.

    This is on my dev box, where I'm a Domain Admin. But I gave some thought to the wording of the error and opened up the security for the GP folder (In Windows Explorer navigate to the Program Files\Dynamics\GP 2010 folder and right click, Properties). I saw that the MACHINE administrator had full control, and the Users group didnt' have Modify rights. I gave the Users group full permissions and it started working.

     I wouldn't do this on a production client, though.

     

More Posts Next page »