Home | Forums | Contact | Search | Syndication  
 
 [login] [create account]   Friday, August 29, 2025 
 
slxdeveloper.com Community Forums  
   
The Forums on slxdeveloper.com are now retired. The forum archive will remain available for the time being. Thank you for your participation on slxdeveloper.com!
 Architect Forums - SalesLogix Scripting & Customization
Forum to discuss writing script in Architect plugins for SalesLogix & general SalesLogix customization topics (for Windows client only). View the code of conduct for posting guidelines.
Forums RSS Feed


 Back to Forum List | Back to SalesLogix Scripting & Customization | New ThreadView:  Search:  
 Author  Thread: Linking from a lookup edit to an Opportunity Record
Andrew Fink
Posts: 41
 
Linking from a lookup edit to an Opportunity RecordYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 18 Feb 08 12:38 PM
I am sure that this has been covered in a previous post. I have searched and couldn't find anything. I have made it so that Tickets can be bound to an Opportunity the same way that a Ticket is bound to an Account or a Contact. I am trying to make the Lookupedit link to the Opportunity that is shown in the Lookupedit. How can I go about this? I have tried the example in the Architect Help menu (below) but this only pulls up a lookup dialog box asking the user to input the Opportunity Name. Any help is greatly appreciated. Thanks.

Sub lkpOpportunityNameClick(Sender)
If Sender.LookupID <> "" Then
Application.BASICFunctions.SetCurrentOpportunityIDSender.LookupID
End If
End Sub



[Reply][Quote]
Andrew Fink
Posts: 41
 
Re: Linking from a lookup edit to an Opportunity RecordYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 18 Feb 08 2:07 PM
Looking at the SLX Developer's Reference guide, I think I need to use the Application.BasicFunctions.ShowViewForRecord function but I am still unable to get this to work. Why oh why doesn't the developer's reference have syntax examples? I'm sure if I could find a syntax example I could figure it out. Here is some of the syntax I have tried:

Application.BasicFunctions.ShowViewForRecord "SYSTEM","Opportunity Details", strOpportunityID ....Could not find view named "Opportunity Details"
Application.BasicFunctions.ShowViewForRecord "SYSTEM","System:Opportunity Details", strOpportunityID
....Could not find view named "System:Opportunity Details"

What is the correct syntax for this function?

..A call from our Sage partner has got me through this issue but I would still like to know the exact syntax of this function. Thanks.
[Reply][Quote]
Andrew Fink
Posts: 41
 
Re: Linking from a lookup edit to an Opportunity RecordYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 18 Feb 08 2:43 PM
Update: The route the Sage partner took worked for a little bit but now every single ticket in the system is an invalid record so I am going to continue with ShowViewForRecord. Anyone have any syntax examples or know where I could find one in the SLX code?
[Reply][Quote]
Phil Parkin
Posts: 819
Top 10 forum poster: 819 posts
 
Re: Linking from a lookup edit to an Opportunity RecordYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 18 Feb 08 4:12 PM
Please provide the following properties of the lue control:

Lookup
LookupID
LookupMainTable
LookupMode
Text

Is it your intention to store the associated Opportunity ID as a new field on the Ticket table?

Phil
[Reply][Quote]
Andrew Fink
Posts: 41
 
Re: Linking from a lookup edit to an Opportunity RecordYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 18 Feb 08 4:23 PM
Phil,
Yes that is correct. I have created a new field on the Ticket table to store the Opportunity Id.

Lookup: OPPORTUNITY:Description
LookupID: TICKET:OpportunityID
LookupMainTable: OPPORTUNITY
LookupMode: ImTable
Text: TICKET:OPPORTUNITYNAME - With my Sage business partner I tried binding to OPPORTUNITYID and creating a local join...Something about this didn't work and every time I attemped to go to detail view I got an "Invalid Record" error message.

BTW...The text is bound TICKET:OPPORTUNITYNAME becuase I am using the GetField function to populate a hidden edit box with the Opportunity ID.
[Reply][Quote]
Phil Parkin
Posts: 819
Top 10 forum poster: 819 posts
 
Re: Linking from a lookup edit to an Opportunity RecordYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 18 Feb 08 4:45 PM
If you inspect the values of the Ticket.OpportunityID field, are they valid opportunity IDs?
[Reply][Quote]
Andrew Fink
Posts: 41
 
Re: Linking from a lookup edit to an Opportunity RecordYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 18 Feb 08 5:10 PM
Yes the values are the correct IDs and that works great, the primary goal though is to be able to click the Opportunity stored in the lue and be taken to that record.
[Reply][Quote]
Phil Parkin
Posts: 819
Top 10 forum poster: 819 posts
 
Re: Linking from a lookup edit to an Opportunity RecordYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 18 Feb 08 5:18 PM
Hmmm, you must be damn close to getting this working!

If you look at lveContact on the Ticket Detail form, you'll see that the .text property is populated in code, not directly via a property setting - maybe you could consider taking the same approach with the Opportunity Name?

Phil
[Reply][Quote]
Andrew Fink
Posts: 41
 
Re: Linking from a lookup edit to an Opportunity Record Your last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 19 Feb 08 8:59 AM
Phil, yes I was very close. Guess I just needed the night off.

Here is how I got it to work.

Sub lkpOpportunityClick(Sender)
InvokeMainView strOpportunityID, "System:" & Right(Sender.Name, Len(Sender.Name) - 3) & " Details"
End Sub

Thanks for your help!

[Reply][Quote]
Andrew Fink
Posts: 41
 
Re: Linking from a lookup edit to an Opportunity Record Your last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 13 Jul 09 8:24 AM
In SLX 7.5 InvokeMainView is no longer available use Application.BasicFunctions.ShowDetails "TABLENAME", recordID instead.
[Reply][Quote]
Kris Halsrud
Posts: 88
 
Re: Linking from a lookup edit to an Opportunity Record Your last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 13 Jul 09 4:36 PM
.
[Reply][Quote]
 Page 1 of 1 
  You can subscribe to receive a daily forum digest in your user profile. View the site code of conduct for posting guidelines.

   Forum RSS Feed - Subscribe to the forum RSS feed to keep on top of the latest forum activity!
 

 
 slxdeveloper.com is brought to you courtesy of Ryan Farley & Customer FX Corporation.
 This site, and all contents herein, are Copyright © 2025 Customer FX Corporation. The information and opinions expressed here are not endorsed by Sage Software.

code of conduct | Subscribe to the slxdeveloper.com Latest Article RSS feed
   
 
page cache (param): 8/29/2025 8:18:38 AM