473,396 Members | 1,832 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Problem connecting Groupwise system from ASP.NET

3
I am trying to Connect Groupwise and change password .It works fine in VS2005 environment but fails when deployed on IIS.

Here is my sample code...

Expand|Select|Wrap|Line Numbers
  1. Imports AdminTypeLibrary
  2.  
  3. Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As
  4. System.EventArgs) Handles Button1.Click
  5.  
  6. Dim PO, Dom As String
  7. Dim objDomain, objDom, objPOs, objPO, objCurPO As Object
  8. Dim objdlists, objdlist
  9. Dim DomPath As String = "Z:\GRPWISE\DOMAIN"
  10.  
  11. PO = "<PO String>"
  12. Dom = "<Domain>"
  13.  
  14. Try
  15. Dim objAdminSystem As Object
  16. objAdminSystem = CreateObject("NovellGroupWareAdmin")
  17.  
  18. <------------following line fails per error "COM Exception : could not connect to domain database" in IIS , but works fine when running it in the VS2005 environment
  19. objDomain = objAdminSystem.Connect("Z:\GRPWISE\DOMAIN")


i have tried impersonation to admin user using web.config,even added ASPNET user to admin group,given full permission to virtual directory and set IIS running in lowest secure mode,gave IIS Admin service rights to interact with desktop but nothing works...
Nov 24 '07 #1
6 2555
kenobewan
4,871 Expert 4TB
Have you created a domain or virtual directory to run under for IIS?
Nov 25 '07 #2
jpatel
3
Yes i have created virtual directory and i am accessing pages using http://localhost/MyDir/Mypage.aspx. Acutual problem is that IIS is blocking call to COM Library (or any executable that calls COM library) for some reason and VS2005 inter web server is not blocking it so code woeks fine in VS2005 but fails in IIS. I have tried everything with IIS from giving IIS worker process admin privilages to impersonating user in web.config and even giving NTFS permissions to ASPNET user to read/write to everything but nothing is working for me...
Nov 26 '07 #3
Shashi Sadasivan
1,435 Expert 1GB
is the firewall blocking it?

there should be incoming firewall rules (i am not aware of the setup of this)
probably it could be the firewall causing this issue.

You cud try diabling the firewall from admistraion and try it (this firewall is different to windows firewall)
Nov 26 '07 #4
kenobewan
4,871 Expert 4TB
Your reference Z:\GRPWISE\DOMAIN may be the problem in my opinion.
Nov 26 '07 #5
jpatel
3
Finally i have done it,no impersonatin or permission issue is there.following code to change password on groupwise
runs on IIS without any change in IIS
Configuration,only thing is i had to login in novel using code and map drive from code so that its available to whtever user
account IIS process is using. NovellGroupWareAdmin library(gwcmb1.dll) is part of groupwise client installation and NWsess.ocx is available from novell site and both should be included in project.

loNWSess = CreateObject("NWSessLib.NWSessCtrl.1")

loNWSess.Bindery = True
loNWSess.RunScripts = False
loNWSess.DisplayResults = False


' Attempt to log the user into the novell server
ValidateUser = loNWSess.Login(lsServer, _masterUser, _masterPassword, False)

loNWSess.DriveMappings.Add("y:", "Z:\GRPWISE\DOMAIN", True)


objAdminSystem = CreateObject("NovellGroupWareAdmin")

objDomain = objAdminSystem.Connect("y:")

Dim match As Match = New Regex("(\S+)\.(\S+)\.(\S+)").Match(UserName & "." & "PO.DOMAIN")

If Not match.Success Then
Throw New Exception("Unable to parse User ID")
End If

Dim user As Object
user = objAdminSystem.Users.Item(match.Groups.Item(1).Val ue.Trim, match.Groups.Item(2).Value.Trim,match.Groups.Item( 3).Value.Trim)
user.SetPassword(NewPassword)
Dec 22 '07 #6
veei
5
I think the reason NWSess.OCX and GroupWareAdmin only work when you use CreateObject rather than As New like you are supposed to in .NET, is because of something I was reading about called Apartment Threading mode (Single vs Multi). MTA vs STA. Works fine in VBScript but anything using .NET to call the API or COM won't work. I tried with PowerShell and ASP.NET. Both with the same results.

I tried using your solution and it worked for me as well..... for a while. But, because it keeps mapping a drive... after a while, it will lose the connection to the drive or have problems remapping.

Perhaps it is the way I'm putting in the code but it is not a stable solution for me. Wish I could just authenticate and access the \\servername\share\db instead of mapping a drive that doesn't even show on server.

Is your program running stable after a long period of time?
Feb 28 '08 #7

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: Xah Lee | last post by:
Python Doc Problem Example: os.system Xah Lee, 2005-09 today i'm trying to use Python to call shell commands. e.g. in Perl something like output=qx(ls) in Python i quickly located the...
4
by: Aaron Bellante | last post by:
I have been creating some pages that pull info from an SQL database located on my computer. I have an identical DB located on the production machine. The page runs fine on my PC (XP Pro), but...
9
by: Nathan Sokalski | last post by:
I am trying to connect to a Microsoft Access Database from my ASP.NET Application. I use the following code to create my connection string: cmdSelect.Connection = New...
4
by: kthiagar | last post by:
Hi I am trying to connect to a password protected access file from VB.NET. I have no problem in connecting to Access, if I remove the password. This is what I am doing: In the server explorer,...
9
by: RvGrah | last post by:
After much hair-pulling, I've finally found the answer to a problem that many are fighting with, difficulty connecting from Sql 2005 Server Management or VS2005 to a remote Sql Server running Sql...
0
by: mortenol | last post by:
Hi, I am trying to connect a MS SSIS package to an AS400/DB2 database, and I experience problem when I hit the "Create Package" button in the "Data Link properties window". I have understood that...
2
by: Patrick F | last post by:
Hi, i have SQL Server 2005 and a database set that is called, myCompany the problem is that i cant connect from my page to it, here is from the web.config: ( i have got this connectionstring from...
6
by: palani12kumar | last post by:
hi everybody... I've a problem in using system() functions. my program was: int main() { clrscr() system("dir"); getch(); }
2
by: orandov | last post by:
Hi, I am having a problem connecting my .net applications from the application server to the database server. When I run the application from my windows xp (sp2) box it works fine. When I try to...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.