Normal Topic @SelectTreeItem and Reports (Read 759 times)
proudpoppy
Full Member
Members
***
Offline


Do What ??

Posts: 420
Location: South Carolina
Joined: Apr 7th, 2004
@SelectTreeItem and Reports
Jul 6th, 2006 at 1:07pm
Print Post Print Post  
Var vsuccess as Int
 
vSuccess = @SelectTreeItem("Search Update Menu!Results Commands!Printing Commands!Reports!Tentreg!Tenant_Listing(Preview)")
If vSuccess = 0
{
  Writeln("The Print Command Failed")
}  

The above code keeps failing, tried it several ways no luck??  Help   Sad
  
Back to top
 
IP Logged
 
Hammer
YaBB Administrator
Lanticans
*****
Offline


Fire bad. Tree pretty.

Posts: 3436
Location: Ohio
Joined: Nov 22nd, 2002
Re: @SelectTreeItem and Reports
Reply #1 - Jul 6th, 2006 at 1:25pm
Print Post Print Post  
The path must be exact. Try a space between _Listing and (Preview.

Code
Select All
vSuccess = @SelectTreeItem("Search Update Menu!Results Commands!Printing Commands!Reports!Tentreg!Tenant_Listing (Preview)")   



EDIT: Ray says there is some other stuff too. He'll be posting in a moment. Smiley
  

- Hammer
The plural of anecdote is not data.
Back to top
IP Logged
 
Ray the Reaper
Global Moderator
Members
Lantica Support
*****
Offline


The One & The Only

Posts: 2482
Joined: Aug 20th, 2003
Re: @SelectTreeItem and Reports
Reply #2 - Jul 6th, 2006 at 1:29pm
Print Post Print Post  
Also Printing Commands should not be in the statement. Printing commands is on the same level as reports and is under Results commands

Code
Select All
vSuccess = @SelectTreeItem("Search Update Menu!Results Commands!Reports!Tentreg!Tenant_Listing (Preview)")   



Then as long as the database is named "Tentreg" and the report is named "Tenant_Listing" then the code will work.

-Ray

  

Raymond Yoxall Consulting
ray.yoxall@gmail.com
ryoxall@lantica.com
Sesame Applications, Design and Support
Back to top
IP Logged
 
proudpoppy
Full Member
Members
***
Offline


Do What ??

Posts: 420
Location: South Carolina
Joined: Apr 7th, 2004
Re: @SelectTreeItem and Reports
Reply #3 - Jul 6th, 2006 at 2:01pm
Print Post Print Post  
Angry

Vsuccess is returning a 0 I doubled checked the names of the database and the report they are right.
I'm calling this from a command button on a custom menu.
  
Back to top
 
IP Logged
 
Ray the Reaper
Global Moderator
Members
Lantica Support
*****
Offline


The One & The Only

Posts: 2482
Joined: Aug 20th, 2003
Re: @SelectTreeItem and Reports
Reply #4 - Jul 6th, 2006 at 2:16pm
Print Post Print Post  
Hold on a second. That code will only work if the form that is open is in the Tentreg database and the Tenant_Listing is listed as a report in it's menu tree. So if your custom menu is in another database then that code will not work. You will have to program the button to open the correct form, retrieve the correct records, and then run the report.

-Ray
  

Raymond Yoxall Consulting
ray.yoxall@gmail.com
ryoxall@lantica.com
Sesame Applications, Design and Support
Back to top
IP Logged
 
proudpoppy
Full Member
Members
***
Offline


Do What ??

Posts: 420
Location: South Carolina
Joined: Apr 7th, 2004
Re: @SelectTreeItem and Reports
Reply #5 - Jul 6th, 2006 at 2:40pm
Print Post Print Post  
Got it !!  Wink

Thanks Ray & Hammer
  
Back to top
 
IP Logged