Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 838
  • Last Modified:

Remove unused VBA Window in Dynamics

I downloaded a package for dynamics GP to a test server. the packaged had some modified forms and vba I removed most of them , but few vba code are still in my visual basic , how can I remove those form from VBA , I know that usually you go into the form click in the toolbar and remove the form from Visual basic , but I can't find the actual window listed in my VBA
here are the windows that I would like to remove, how can I find them in dynamics:
Toolbar(Window)
SalesAnalysisReportOptions (window)

thanks
David
0
taverny
Asked:
taverny
  • 11
  • 10
2 Solutions
 
Abdulmalek_HamshoCommented:
Well, I'm gonna give you the cleanup solution. In order to clean all of your VBA code for one dictionary, do the following:

1- Go the GP folder.
2- Delete the respective .vba file; means if your VBA code belong to Dynamics dictionary, then you need to delete Dynamics.vba. If your VBA code belong to Field Service dictionary, you need to delete SrvcAdv.vba file.

FYI, the Toolbar window is the main GP window, while SalesAnalysisReportOptions is in: Reports -> Sales -> Analysis.
0
 
tavernyAuthor Commented:
Thanks but if I have other VBA code in my dynamics.vba that I don't want to delete only want to delete the one for the toolbar. how do I do that , can I go into the dynamics.vba and delete from there, if so how or is there another approach?
0
 
tavernyAuthor Commented:
and I did try to remove the salesAnalysisReportOptions, from the one you told me , but it's still not removing . just to make sure when I go to Reports -> Sales -> Analysis. the one display is the Sales Analysis Reports not the option one.
0
Visualize your virtual and backup environments

Create well-organized and polished visualizations of your virtual and backup environments when planning VMware vSphere, Microsoft Hyper-V or Veeam deployments. It helps you to gain better visibility and valuable business insights.

 
Abdulmalek_HamshoCommented:
No, go the window and Rmove It from VBA. I've told in my previous post where are the remaining windows (Toolbar and SalesAnalysis...).
0
 
Abdulmalek_HamshoCommented:
You're right, I was mistaken. After opening the Sales Analysis Report window, click New button and remove this window from VBA.
0
 
tavernyAuthor Commented:
This one works thanks. what about the toolbar?
0
 
Abdulmalek_HamshoCommented:
It's the main GP window, close all of the opened GP windows and remove the main one from VBA (Same one contains the Home Page).
0
 
tavernyAuthor Commented:
hmm, I can't figure this one out , I click on both place noted red and It doesn't seem to show me the customize >remove vba. Am I clicking in the wrong place?
Capture.JPG
0
 
Abdulmalek_HamshoCommented:
Have you imported a modifications package from GP 8.0 or earlier version?
0
 
Abdulmalek_HamshoCommented:
It's a bit difficult to remove the Toolbar from VBA, and I suggest you to leave it.

To remove it do the followings:
 
1- Export all of your VBA modifications to a package.

2- Edit the export file in Notepad.

3- Remove all of the lines starting from:
<Component Name="Toolbar" ProductId="0" Object="VBAForm" >
Ending and including this line:
</Component>
The you may find many lines like this "</Component>", but you need to remove the code to the first occurance after the first line as following:

<Component Name="Toolbar" ProductId="0" Object="VBAForm" >
VBAForm "Toolbar"
{
 Windows
 {
  Window "Main_Menu_1"  
  {
   EventMode "0"
   Fields
   {
    WindowField "(L) eEnterpriseUser ID"    
    {
     ArrayIndex "0"
     DisplayName "eEnterpriseUserID"
     Local "true"
     ProgrammerName "eEnterpriseUser ID"
    }
    WindowField "Company Name"    
    {
     ArrayIndex "0"
     DisplayName "CompanyName"
     Local "false"
     ProgrammerName "Company Name"
    }
    WindowField "Date"    
    {
     ArrayIndex "0"
     DisplayName "UserDate"
     Local "false"
     ProgrammerName "Date"
    }
   }
   Title "Toolbar"
  }
 }
}
</Component>

0
 
tavernyAuthor Commented:
ok so I exported all the packages and modified like you said and removed only the code for the toolbar.
now what should I do ? since if I reimport it it will only overwrite what I currently have in the package so the toolbar will still be in my system .
0
 
Abdulmalek_HamshoCommented:
I'm sorry, my comments above needs to be continued:

4- Delete the dynamics.vba file from GP folder.

5- Import the package you've altered in Notepad.
0
 
tavernyAuthor Commented:
when I delete the dynamics.vba then I close dynamics and reopen it. it tells me that I need dynamics.vba for the Srvcadv.vba and ask me to point to it. so I put it back.
Do you think I should delete both VBA and reimport everything?
0
 
Abdulmalek_HamshoCommented:
Yes, no problem delete both. But you'll be able to delete them after closing GP only.
0
 
tavernyAuthor Commented:
ok I will try that right now.
0
 
tavernyAuthor Commented:
ok  I think it worked , I just have to test everyform to make sure that all of my code got imported correctly.

But here is something weird that happened. All my forms were into a folder called "Microsoft Dynamics GP Object"
now the folder is called "Interfund Management Objects"
do you think it's correct?
0
 
tavernyAuthor Commented:
Never mind. I closed dynamics and reopen it and now the name of the folder is back to normal . that was weird.
0
 
tavernyAuthor Commented:
Well thank you for this one, one more step done.
thank you so much.
0
 
Abdulmalek_HamshoCommented:
Any time.
0
 
tavernyAuthor Commented:
well, I have alot more to do. and I would like you to be able to help me more since you did help me the most in this project.
Just to give you the heads up on what else needs to be accomplish , and of course I will open a question for each part along this project.
-I need to create a new form that will pull the price list of an item on a separate window from the RMA
( I will elaborate more on that on the question)
- I also need to modify or create a new window for the creation of an item from an RMA that will have a bunch of rules and drop down list with the manufacturer in it
- create a new VBA software outside of dynamics to enable my users to post time into a WO Job without logging into Dynamics. I have about 30 Tech and I don't see 30 computers sitting around just for them to post time to the job. and at the same time it would take too long for one take to log in dynamics post time and log out for another user to post his time.
-and some other little modification to make dynamics more friendly

so hoppefully you will be along for this project since I really like your way of thinking throught the programming .
thank you so much again for all your help on all my questions.
David
0
 
Abdulmalek_HamshoCommented:
I with other EE experts will do our best.
0

Featured Post

Restore individual SQL databases with ease

Veeam Explorer for Microsoft SQL Server delivers an easy-to-use, wizard-driven interface for restoring your databases from a backup. No expert SQL background required. Web interface provides a complete view of all available SQL databases to simplify the recovery of lost database

  • 11
  • 10
Tackle projects and never again get stuck behind a technical roadblock.
Join Now