Gemini Community Support Site

This Gemini community support site can be used to find solutions to product issues. You can log in using Open Id, Google Profile and even Facebook. Feel free to ask a question or browse FAQs and documentation. Product tour videos are also available along with how-to videos demonstrating key Gemini capabilities.




Webservice Create Issue

web-app

I cannot get the create issue to work for the webservice calls.

If proxy.SetAuthenticationTokenOnAllServices("WebService", "Password") Then
   Dim user As New gemini.UserEN
   user = _proxy.AuthorisationServices.LogIn("WebService", "")   
   If user.UserID > 0 Then
    
proxy.UserID = user.UserID
    Return
   End If
   MessageBox.Show("error")

 End If

I created a user called WebService, since I could not get the Anon user to work. We are using Windows authentication. The code above appears to work ok. But when I try to create an issue I get an message saying the user is not allowed to create issues. I have both the user setup with that role, and I also have the project default schema to allow anonymous users to create issues.

is there a minimum amount of data that is necessary to create an issue? I thought I had the necessary info but maybe its missing.

 

ecathell
· 1
ecathell
Replies (11)
helpful
0
not helpful

The sample code above does not help us as it has got nothing to do with creating issues....

Please have a look at the web services sample app: http://www.countersoft.com/Downloads/CounterSoftGeminiServices_Samples.zip


Saar Cohen
· 5000
Saar Cohen
helpful
0
not helpful

Private Function createNewIssue() As Gemini.IssueEN

  issue.ProjectCode = "TSTPROJ"
  
issue.IssueSummary = "TestIssue"
  issue.IssueLongDesc = "THIS IS A TEST"


  Return _issue
End Function

 

Private Sub Button1Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click

  Try
   proxy.IssueServices.CreateIssue(createNewIssue)

  Catch ex As Exception
   MessageBox.Show(ex.ToString)

  End Try

End Sub

 

ERROR:

System.Web.Services.Protocols.SoapException: Server was unable to process request. ---> You do not have the privileges to create issues for this project
   at System.Web.Services.Protocols.SoapHttpClientProtocol.ReadResponse(SoapClientMessage message, WebResponse response, Stream responseStream, Boolean asyncCall)
   at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String methodName, Object[] parameters)
   at IssueServices.CreateIssue(IssueEN issue)
   at WavelengthIS.Referee.GUI.test.Button1
Click(Object sender, EventArgs e) in C:\VS2005 Projects\Projects\WavelengthIS\Referee\WavelengthIS.Referee.GUI\test.vb:line 43


ecathell
· 1
ecathell
helpful
0
not helpful

Can you create an issue via the web app using this user?


Saar Cohen
· 5000
Saar Cohen
helpful
0
not helpful

hmm...maybe that is part of the issue. I have gemini using windows authentication, but the account is only a gemini account, not a windows account. Is there a way to allow anonymous users to use the webservice? This is so that users in our organization can report bugs or offer suggestions without having to be part of the user database? Or is there a way to use just forms authentication for the webservice?


ecathell
· 1
ecathell
helpful
0
not helpful

You can use the non WSE web services to create issues (Gemini.asmx) without user info.

If you do want to use WSE, then you will have to create a user in Gemini and use that user.


Saar Cohen
· 5000
Saar Cohen
helpful
0
not helpful

ok. That is what I have done so far hehe...Webservice is a user in gemini, but its not a windows user account.

I had originally started to use just the gemini.asmx, but saw most things were returned as a generic object.

If I use the gemini.asmx is there a proxy for returning typed objects? I will look through the example webservices again to see if I can see some examples. Thanks for your patience.

 

ETA: Ok I looked through the example app and it appears to be using nothing but WSE. SO....

I have the create issue working with Gemini.asmx now. BUT, How can I create lookup combo boxes? as I stated earlier many of the get (getcomponent, getproject) return generic array objects. This is what I have tried to do...maybe you can point me in the right direction because its not working.

 

Private Sub fillComponentsCombobox()

  Dim comps() As GeminiWebservice.ComponentEN
  comps() = ws.GetAllComponents(My.Resources.AccessCode, My.Resources.ProjectID)
 

  For i As Integer = 0 To comps.GetUpperBound(0)
   Me.cboComponents.Items.Add(comps(i).CompName)
  Next

  End Sub

its not working because i have to dimension the comps() array, but I dont know how many dimensions to use. So any suggestions would be great. Thanks again.


ecathell
· 1
ecathell
helpful
0
not helpful

You should do it like:

 Dim comps() As GeminiWebservice.ComponentEN
  comps = ws.GetAllComponents(My.Resources.AccessCode, My.Resources.ProjectID)
 


Saar Cohen
· 5000
Saar Cohen
helpful
0
not helpful

right, I had tried that before. On the chance I had done something wrong I did it again...this is the error I am getting.

System.InvalidCastException: Unable to cast object of type 'System.Object[]' to type 'WavelengthIS.Referee.GUI.GeminiWebservice.ComponentEN[]'.

at WavelengthIS.Referee.GUI.test.fillComponentsCombobox() in C:\VS2005 Projects\Projects\WavelengthIS\Referee\WavelengthIS.Referee.GUI\test.vb:line 66

 

i even tried to use a Ctype() conversion, but that didnt work. I did some digging and tried to use a datatable like I had seen in an example from 1.9.1 but that didt work either.

 

Eric


ecathell
· 1
ecathell
helpful
0
not helpful

Seems like an issue with the proxy you have created.

Try and use this one: http://www.countersoft.com/Downloads/CounterSoftGeminiServicesv22_0.zip


Saar Cohen
· 5000
Saar Cohen
helpful
0
not helpful

is this file still available for download somewhere?

We only have version 2.0.5 and the current version that is available for download (3.04) is of no use to us.

 

Thanks,

Cory

 

 


cct
· 1
cct
helpful
0
not helpful

This is under the code samples of the 2.0.5 zip file:

http://countersoft.com/downloads/csfiles/old/Geminiv20_5.zip


Saar Cohen
· 5000
Saar Cohen