类型“CRM_BusinessLayer.MM_Purchasing”未定义._ [英] Type 'CRM_BusinessLayer.MM_Purchasing' is not defined._

查看:53
本文介绍了类型“CRM_BusinessLayer.MM_Purchasing”未定义._的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我遇到此错误的问题。

我是否需要安装或引用某些内容?

Do I have to install or reference something?

'declaration
Public Class POPrinting
    Inherits System.Web.UI.Page
    Private mobjCRMBAL As CRM_BusinessLayer.MM_Purchasing

 
Private Sub DeleteOldTrans()
        mobjCRMBAL = New CRM_BusinessLayer.MM_Purchasing(Session("SQLConStr").ToString, Session("SAPConStr").ToString)
        mobjCRMBAL.DeleteTrans(Session.SessionID)
    End Sub

请帮忙。

谢谢

推荐答案

嗨Jerzon,



欢迎来到MSDN论坛。



1.请查看此官方文档:我是否必须安装或引用某些内容?



是的,我认为你确实需要安装和引用程序集(xx.dll),其中存在CRM_BusinessLayer和MM_P的定义u


2.根据您的代码结构,我认为CRM_BusinessLayer是NameSapce的名称,MM_Purchasing是其中的一个类。



我重现与您相同的问题和错误消息。我通过向vb项目添加自定义MM_Purchasing.vb文件来解决此问题。结构应该是这样的:

Hi Jerzon,

Welcome to MSDN forum.

1. Please check this official document: Do I have to install or reference something?

Yes, I think you do need to install and reference the assembly(xx.dll) where exists the definition of CRM_BusinessLayer and MM_Purchasing.

2. According to the structure of your code, I would think the CRM_BusinessLayer is name of NameSapce and MM_Purchasing is a class within it.

I reproduce the same issue and error message like yours. And I resolve the issue by adding a custom MM_Purchasing.vb file into the vb project. The structure should be like:

'declaration
Namespace CRM_BusinessLayer
    Friend Class MM_Purchasing
        Private toString1 As String
        Private toString2 As String

        Public Sub New(toString1 As String, toString2 As String)
            Me.toString1 = toString1
            Me.toString2 = toString2
        End Sub

        Friend Sub DeleteTrans(sessionID As String)
            Throw New NotImplementedException()
        End Sub
    End Class
End Namespace

您需要的是添加对程序集的引用,其中定义了CRM_BusinessLayer命名空间和MM_Purchasing类。之后,该项目可以很好地建立。

What you need is to add reference to the assembly in which defines the CRM_BusinessLayer namespace and MM_Purchasing class. After that the project can build well.

希望以上所有有帮助。如果我的回复有帮助,请给我一个反馈!

Hope all above helps. And if my reply is helpful or not, please give me a feedback!

最好的问候

Lance


这篇关于类型“CRM_BusinessLayer.MM_Purchasing”未定义._的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆