Home | Forums | Contact | Search | Syndication  
 
 [login] [create account]   Friday, November 22, 2024 
 
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 - ADO General
Forum to discuss ADO specific questions for use with SalesLogix. View the code of conduct for posting guidelines.
Forums RSS Feed


 Back to Forum List | Back to ADO General | New ThreadView:  Search:  
 Author  Thread: Not able to use SLXAPI in .net
Raj
Posts: 7
 
Not able to use SLXAPI in .netYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 23 Aug 07 3:05 PM
Hi,
I am new to SalesLogix development. We have tool in VB6 Which uses SLXAPI for data manipulations. We are migrating this into .net and I need to use this SLXAPI for creating Unique IDs. Is there .NET SLXAPI DLL availble or How to implement this. Please help me.

Thanks
Raj
[Reply][Quote]
Bob (RJ)Ledger
Posts: 1103
Top 10 forum poster: 1103 posts
 
Re: Not able to use SLXAPI in .netYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 24 Aug 07 12:18 AM
SLAPI is not used any more.. and no there is not a .NET SLAPI...

Ryan has examples on this site of using .NET w/ SalesLogix.

--
rjl
[Reply][Quote]
Raj
Posts: 7
 
Re: Not able to use SLXAPI in .netYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 24 Aug 07 8:57 AM
Is this SlxManagedLib? I am trying to execute that application. I am getting error when logging into Sales Logix.
[Reply][Quote]
Raj
Posts: 7
 
Re: Not able to use SLXAPI in .netYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 24 Aug 07 9:09 AM
When I execute the application of SlxApi.Vb of SlxManagedLib solution (Provided by Ryan) , Its logging into Sales Logix. But when I copy attach this module to different appication and trying to logon , I am getting the following error.

Unable to find an entry point named 'slapi_LogInto' in DLL 'SlgxApi.dll'.

Thanks
[Reply][Quote]
Ryan Farley
Posts: 2265
slxdeveloper.com Site Administrator
Top 10 forum poster: 2265 posts
 
Re: Not able to use SLXAPI in .netYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 24 Aug 07 3:37 PM
1) What version of SLX are you on?

2) Stop using SLAPI

3) SLAPI should still work, but I've not tested SLAPI with SLX for a couple years, so who knows. One thing you'd have to do for sure, the SLAPI DLL (SlgxApi.dll) is not found in the path. You'll have to either add the SLX dir to the PATH environment variable, or copy the file to the System32 directory.

4) SLAPI is junk, you really shouldn't be using it any more. I realize that this is easier said than done when you have a production application using it and no time to rewrite it. But, give it some thought.

-Ryan
[Reply][Quote]
Bob (RJ)Ledger
Posts: 1103
Top 10 forum poster: 1103 posts
 
Re: Not able to use SLXAPI in .netYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 25 Aug 07 11:18 AM
AMEN!
It's time for everyone to just say NO to SLAPI!

--
rjl
[Reply][Quote]
Raj
Posts: 7
 
Re: Not able to use SLXAPI in .netYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 27 Aug 07 1:00 PM
Can I use this wrapper instead of Slapi? We are upgrading our sales logix version from 5.2 to 7.
[Reply][Quote]
Ryan Farley
Posts: 2265
slxdeveloper.com Site Administrator
Top 10 forum poster: 2265 posts
 
Re: Not able to use SLXAPI in .netYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 27 Aug 07 1:12 PM
Quote:
Originally posted by Raj

Can I use this wrapper instead of Slapi? We are upgrading our sales logix version from 5.2 to 7.


It's not *instead of*. The wrapper simply wraps the SLAPI DLL to provide a managed wrapper to call it from .NET. Whether SLAPI works or not anymore, no idea. If SLAPI is still supported the wrapper should work fine.
[Reply][Quote]
Raj
Posts: 7
 
Re: Not able to use SLXAPI in .netYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 27 Aug 07 3:02 PM
I am sorry I didn't get this. In our application we are using SLAPI to generate unique iDS for each table. Since there won't be SLAPI in the future, Can I use this wrapper to generate IDs. To generate we need to log on to SALESLGIX. Does this wrapper LogOn functions work for future versions of SALES LOGIX 7.x?
[Reply][Quote]
Lloy Sanders
Posts: 69
 
Re: Not able to use SLXAPI in .netYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 27 Aug 07 3:35 PM
Instead of using SLAPI, with SalesLogix version 6.0 and higher, you can use the OLEDB providor and access SalesLogix through ADO or ADO.NET. To create Ids, you would do something like this

Public Function CreateSLXId(ByVal szTable As String) As String
Dim conSLX As New OleDbConnection(szgSLXStr)
Dim szSql As String

' Create New Id
conSLX.Open()
' Use OLEDB Provider stored procedure "SLX_DBIDs"
szSql = "SLX_DBIDs('" & szTable & "', 1)"
Dim cmdIDs As New OleDbCommand(szSql, conSLX)
Dim rdrIDs As OleDbDataReader
rdrIDs = cmdIDs.ExecuteReader(CommandBehavior.Default)
rdrIDs.Read()
CreateSLXId = rdrIDs.GetValue(0)
rdrIDs.Close()
cmdIDs.Dispose()
conSLX.Close()
End Function

szgSLXStr is a variable that should contain your ADO connection string.

Ryan has a great article on this site that talks about using ADO with SalesLogix. See here:
http://www.slxdeveloper.com/page.aspx?action=viewarticle&articleid=17


Lloy
[Reply][Quote]
Raul A. Chavez
Posts: 1300
Top 10 forum poster: 1300 posts
 
Re: Not able to use SLXAPI in .netYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 27 Aug 07 3:38 PM
You need to familiarize yourself with the SalesLogix OLEDB Provider. There are several articles about it on this site that will give you all what you need to know about it.

Here is the link to the section:

http://www.slxdeveloper.com/page.aspx?id=15
[Reply][Quote]
Snow Monkey
Posts: 214
 
Re: Not able to use SLXAPI in .netYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 28 Aug 07 8:53 AM
Lloy , i initially coded things that way.After a while things started failing on the create dbids proc and i was told that i needed to know the real "internals" of slx... So i had to code it this way

Function CreateSLXIDFor(ByVal sTableName As String) As String
Dim oRecordSet As Object
Dim oConnection As Object
Dim oCommand As Object
Dim oParameter As Object
Dim sCommandText As String
Dim sEntityAlias As String

sEntityAlias = sTableName
Select Case UCase(sTableName)
Case "ATTACHMENT"
sEntityAlias = "FILEATTACH"

Case "USERNOTIFICATION"
sEntityAlias = "USERNOTIFY"

Case "AGENTS"
sEntityAlias = "HOSTTASK"

Case "RESOURCELIST"
sEntityAlias = "RESOURCE"

Case "USEROPTION"
sEntityAlias = "USERVIEW"

Case "JOINDATA"
sEntityAlias = "JOIN"

Case "PROCEDURES"
sEntityAlias = "PROCEDURE"

Case "SEC_FUNCTIONOWNER"
sEntityAlias = "FUNCTIONHANDLER"

End Select

sCommandText = "slx_dbids ( '" & UCase(sEntityAlias) & "' , 1) "

oConnection = GetNewConnection()
oCommand = CreateObject("ADODB.Command")
oCommand.ActiveConnection = oConnection
oCommand.CommandType = adCmdText
oCommand.CommandText = sCommandText
oRecordSet = oCommand.Execute
CreateSLXIDFor = DBGetValue(oRecordSet, CStr(0))

oRecordSet = Nothing
CloseThis(oConnection)
End Function

hope this helps!!(creates some more confusion in you as that was the case with me ...)))
[Reply][Quote]
Ryan Farley
Posts: 2265
slxdeveloper.com Site Administrator
Top 10 forum poster: 2265 posts
 
Re: Not able to use SLXAPI in .netYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 28 Aug 07 1:06 PM
Quote:
Originally posted by Raj

I am sorry I didn't get this. In our application we are using SLAPI to generate unique iDS for each table. Since there won't be SLAPI in the future, Can I use this wrapper to generate IDs. To generate we need to log on to SALESLGIX. Does this wrapper LogOn functions work for future versions of SALES LOGIX 7.x?


The wrapper itself contains nothing. It just makes the SLAPI functions in SlgxApi.DLL accessible in .NET. However, if all you need is to create ID values, there are many better ways to do that not (as others have mentioned and linked to articles)
[Reply][Quote]
Lloy Sanders
Posts: 69
 
Re: Not able to use SLXAPI in .netYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 28 Aug 07 3:16 PM
I don't believe I have ever tried creating IDs for any of these tables, but I would call it a bug rather than FAD. Guess I'll try it out and see what happens. Thanks.
[Reply][Quote]
Bob (RJ)Ledger
Posts: 1103
Top 10 forum poster: 1103 posts
 
Re: Not able to use SLXAPI in .netYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 29 Aug 07 5:59 AM
Quote:
Originally posted by Lloy Sanders

I don't believe I have ever tried creating IDs for any of these tables, but I would call it a bug rather than FAD. Guess I'll try it out and see what happens. Thanks.


It really is FAD.. or rather a "poor practice".

These tables have their roots in the very earliest version(s) of SalesLogix and are really "internal" tables. Some of us have known about this for years.. They are what they are.
--
rjl
[Reply][Quote]
Lloy Sanders
Posts: 69
 
Re: Not able to use SLXAPI in .netYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 29 Aug 07 8:10 AM
Just pointing out the difference between FAD and correct
[Reply][Quote]
Bob (RJ)Ledger
Posts: 1103
Top 10 forum poster: 1103 posts
 
Re: Not able to use SLXAPI in .netYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 30 Aug 07 6:59 AM
Quote:
Originally posted by Lloy Sanders

Just pointing out the difference between FAD and correct


I could write a 1000 page book on bad FAD in SalesLogix.. and still not ever run out of material.. probably volumes...

On the other hand.. there's bad FAD everywhere...
--
rjl
[Reply][Quote]
RJ Samp
Posts: 973
Top 10 forum poster: 973 posts
 
Re: Not able to use SLXAPI in .netYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 30 Aug 07 8:42 AM
Quote:
Originally posted by Bob (RJ)Ledger


.. there's bad FAD everywhere...


Isn't that a Doors tune from the 60's?

[Reply][Quote]
Bob (RJ)Ledger
Posts: 1103
Top 10 forum poster: 1103 posts
 
Re: Not able to use SLXAPI in .netYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 31 Aug 07 7:10 AM
Quote:
Originally posted by RJ Samp



Isn't that a Doors tune from the 60's?



humm.. hum a few bars
--
rjl
[Reply][Quote]
RJ Samp
Posts: 973
Top 10 forum poster: 973 posts
 
Re: Not able to use SLXAPI in .netYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 31 Aug 07 9:03 AM
Dot Dot Dot De Dot Dot De Dot Duh
Dot Dot Dot De Dot Dot De Dot Duh
Come on, Come on, Come on, Come on, Come on
Touch Me Babe......(Horn section: Doot Doot Duh Dee!)
[Reply][Quote]
Bob (RJ)Ledger
Posts: 1103
Top 10 forum poster: 1103 posts
 
Re: Not able to use SLXAPI in .netYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 02 Sep 07 5:25 PM
Quote:
Originally posted by RJ Samp

Dot Dot Dot De Dot Dot De Dot Duh
Dot Dot Dot De Dot Dot De Dot Duh
Come on, Come on, Come on, Come on, Come on
Touch Me Babe......(Horn section: Doot Doot Duh Dee!)


Weren't they on acid at the time?
--
rjl
[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 © 2024 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): 11/22/2024 5:06:46 PM