Objects in a set

Hi im writing a program that holds names in a a class like
public class UserInfo
   private Set<String> Names= new HashSet<String>();
    * Constructor for objects of class UserInfo
   public UserInfo(String text)
      Names = text;
    * returns the values of Names to the receiver.
   public Set<String> getNames()
      return Names;
}really basic im having the problems with a second class that holds the instances of this class.
the second class has
public class seach
   Set<objects> nameshold;
   public seach()
       nameshold= new HashSet<object>();     
    * adds the arument to the nameshold Set.
   public void addSite(Object Names)
      nameshold.add(Names);
   public void Seach(String aArument)
      for (object eachObject : nameshold)
         eachObject.contains(aArument);
}it all works but i can not access the objects held by nameshold i guess its because its held in an object so i can't access it like a set
but how would i access the sets in the nameshold object.
this code i just write to show my problem so it may be full of bugs
Edited by: Kiith on Mar 18, 2008 12:53 PM

sorry this is the code i have its for college so no telling me how to but and im using bluej
First class
import java.util.*;
public class Names
   private Set<String> groupNames = new HashSet<String>();
   public Names(String text)
      groupNames = Names.breakWords(text); 
   public Set<String> getgroupNames()
      return groupNames;
   public static Set<String> breakWords(String text)
      String[] Array;
      Set<String> brokenWords = new HashSet<String>();
      Array = text.split(" ");
      for (String eachWord : Array)
         brokenWords.add(eachWord);
      return brokenWords;
}second class
import java.util.*;
public class seacher
   Set<Object> scannedNames;
   public seacher()
       scannedNames = new HashSet<Object>();     
   public void addGroup(Object groupNames)
      scannedNames.add(groupNames);
   public void searchFor(String aArument)
      for ( Object eachGroup : scannedNames)
         //eachGroup.contains("dan");                 
}and i am using Object here i could use names instead but im not shore if that would make a differance
this part is where im having problems //eachGroup.contains("Luke"); im trying to break down the group objects of names so i can test it
one at a time so each object i can check if it holds the name "dan"
when i run this code i have 2 instances of names called test1 and test 2 an instace of seacher called seach that hold both test1 and test2
i what to check the value that are held in test1 and test2 to so see if it holds the value dan or any value. both test1 and 2 hold "pual", "dan", "mark"
i do not know what they will hold in the end but for testing i use them.
Edited by: Kiith on Mar 18, 2008 1:16 PM
Edited by: Kiith on Mar 18, 2008 1:17 PM
Edited by: Kiith on Mar 18, 2008 1:27 PM

Similar Messages

  • "cacheHostInfo is null" and Add-SPDistributedCacheServiceInstance : Object reference not set to an instance of an object.

    I am working on a standalone install Sharepoint 2013 (no Active Directory). I found newsfeed feature is not available and checked Distributed Cache service is stopped. When start it “cacheHostInfo is null” is returned.
    I checked the Windows service “AppFabric caching service” is stopped because the default identity “Network Service” not work. Then I change the AppFabric service identity to use “.\administrator” (which is also the sp farm administrator) and the service can
    be started.
    However the “cacheHostInfo is null” when try to start Distributed Cache service in central admin.
    I searched on web and found this blog: http://rakatechblog.wordpress.com/2013/02/04/sharepoint-2013-spdistributedcacheserviceinstance-cachehostinfo-is-null/
    I tried to run the script but it return error:
    Add-SPDistributedCacheServiceInstance : Object reference not set to an
    instance of an object.
    At C:\root\ps\test.ps1:8 char:13
    + $whatever = Add-SPDistributedCacheServiceInstance
    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo : InvalidData: (Microsoft.Share…ServiceInstance:
    SPCmdletAddDist…ServiceInstance) [Add-SPDistributedCacheServiceInstance]
    , NullReferenceException
    + FullyQualifiedErrorId : Microsoft.SharePoint.PowerShell.SPCmdletAddDistr
    ibutedCacheServiceInstance
    I am not sure what went wrong. Please give me some idea? Thank you for any comment!

    Can you deploy Active Directory as installing without is not a supported installation scenario - http://support.microsoft.com/kb/2764086.
    Trevor Seward
    Follow or contact me at...
    &nbsp&nbsp
    This post is my own opinion and does not necessarily reflect the opinion or view of Microsoft, its employees, or other MVPs.

  • Test-OutlookConnectivity WARNING: An unexpected error has occurred and a Watson dump is being generated: Object reference not set to an instance of an object.

    Hi All,
    When we do a test-outlookconnectivity -protocol:http the result is a success but then we get the following:
    ClientAccessServer   ServiceEndpoint                               Scenario                           
    Result  Latency
    (MS)
    xxxxxxxxxxxx... xxxxxxxxxxxxxx                 Autodiscover: Web service request.  Success   46.80
    WARNING: An unexpected error has occurred and a Watson dump is being generated: Object reference not set to an instance
     of an object.
    Object reference not set to an instance of an object.
        + CategoryInfo          : NotSpecified: (:) [Test-OutlookConnectivity], NullReferenceException
        + FullyQualifiedErrorId : System.NullReferenceException,Microsoft.Exchange.Monitoring.TestOutlookConnectivityTask
    So it looks like it's not completing successfully.
    I can't find anything on this in particular, and don't really know how to go about solving it - We are fully up to date, Exchange 2010 Sp2 with Rollup 5-v2
    Any help appreciated!

    hi,
    I have the same issue also on Exchange 2010 SP2 RU5v2
    I ran your command and get the below
    [PS] C:\Installs\report\Activesync>Test-OutlookConnectivity -Protocol:http |FL
    RunspaceId                  : ebd2c626-1634-40ad-a17e-c9a713d1a62b
    ServiceEndpoint             : autodiscover.domain.com
    Id                          : Autodiscover
    ClientAccessServer          : CAS01.domain.com
    Scenario                    : Autodiscover: Web service request.
    ScenarioDescription         :
    PerformanceCounterName      :
    Result                      : Success
    Error                       :
    UserName                    : Gazpromuk.intra\extest_645e41faa55f4
    StartTime                   : 8/21/2013 4:08:50 PM
    Latency                     : 00:00:00.1250048
    EventType                   : Success
    LatencyInMillisecondsString : 125.00
    Identity                    :
    IsValid                     : True
    WARNING: An unexpected error has occurred and a Watson dump is being generated: Object reference not set to an instance of an object.
    Object reference not set to an instance of an object.
        + CategoryInfo          : NotSpecified: (:) [Test-OutlookConnectivity], NullReferenceException
        + FullyQualifiedErrorId : System.NullReferenceException,Microsoft.Exchange.Monitoring.TestOutlookConnectivityTask
     Any help would be greatly appreciated, I also get random failures of OWA, EAS and web services, very frustrating
    I have no errors in the app event log
    thanks
    Faisal Saleem Windows Systems Analyst 07595781867

  • "An error has occurred:Object reference not set to an instance of an object."

    This error message comes up with a user in InfoView.  The user schedules a report, updates parameters, and the report kicks off successfully.  But then a few minutes later, this error is received.    This occurs sporadically, regardless of the length of time of report or amount of data being retrieved.  Sometimes the report runs to completion.  Other times this error message occurs.
    Has anyone seen this before and have any thoughts?
    Thank you.
    “An error has occurred:Object reference not set to an instance of an object.”

    Are you able to replicate the issue both in Java and .NET InfoView?
    For .NET InfoView, sometimes the "An error has occurred: Object reference not set to an instance of an object" error shows up after the .NET Framework is upgraded to 2.0

  • "Object reference not set to an instance of an object" when opening designer

    I have a Windows Forms project which was originally developed in Visual Studio 2010. I migrated the project to VS2013, and now every time I open the project's main form, the designer complains of a null reference. If I hit "Ignore and Continue",
    the code compiles just fine. The error in question appears in the "Windows Form Designer generated code" region. Even more curious, the line in question is not the first reference to the object. It's as if the first few times it needs to interact
    with the object, it's fine, then at a certain point it becomes null.
    Here is the call stack for the error:
    at System.ComponentModel.ReflectPropertyDescriptor.SetValue(Object component,
    Object value)at
    Microsoft.VisualStudio.Shell.Design.VsTargetFrameworkPropertyDescriptor.SetValue(Object
    component, Object value)at
    System.ComponentModel.Design.Serialization.CodeDomSerializerBase.DeserializePropertyAssignStatement(IDesignerSerializationManager
    manager, CodeAssignStatement statement, CodePropertyReferenceExpression
    propertyReferenceEx, Boolean reportError)at
    System.ComponentModel.Design.Serialization.CodeDomSerializerBase.DeserializeAssignStatement(IDesignerSerializationManager
    manager, CodeAssignStatement statement)at
    System.ComponentModel.Design.Serialization.CodeDomSerializerBase.DeserializeStatement(IDesignerSerializationManager
    manager, CodeStatement statement) 
    And here is the code in question:
    this.optionsControl.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right))); 
    this.optionsControl.IsAsciiMode = false;           
    this.optionsControl.Location = new System.Drawing.Point(3, 3);
    this.optionsControl.LogControl = null;           
    this.optionsControl.Name = "optionsControl";           
    this.optionsControl.PlugInManager = null;           
    this.optionsControl.PortFacade = null;           
    this.optionsControl.Size = new System.Drawing.Size(613, 259);
    this.optionsControl.TabIndex = 0;
    The problem is reported at the third line, "this.optionsControl.Location = new System.Drawing.Point(3, 3);".

    Hi Eric,
    I have made a research about your issue, and I found it might be caused by the usercontrol in the project. Was “this.optionsControl” a UserControl? It seems that this issue was difficult to handle.
    If possible, I would recommend you recreate this control in a new project.
    In addition, I think you could turn to the links below, they may be useful to you:
    # How to get more information about exceptions thrown by the designer when switching from code to design view?
    http://community.sharpdevelop.net/forums/p/16124/43105.aspx
    # How to avoid WSODs in the Visual Studio 2005 Designer
    http://www.codeproject.com/Articles/13584/How-to-avoid-WSODs-in-the-Visual-Studio-Desig
    # design time error: object reference not set an instance of an object but runs fine
    https://social.msdn.microsoft.com/Forums/vstudio/en-US/b3676bef-e457-4aac-b438-d3ed8a667e3f/design-time-error-object-reference-not-set-an-instance-of-an-object-but-runs-fine?forum=winforms
    Best Regards,
    Edward
    This response contains a reference to a third party World Wide Web site. Microsoft is providing this information as a convenience to you. Microsoft does not control these sites and has not tested any software or information found on these sites; therefore,
    Microsoft cannot make any representations regarding the quality, safety, or suitability of any software or information found there. There are inherent dangers in the use of any software found on the Internet, and Microsoft cautions you to make sure that you
    completely understand the risk before retrieving any software from the Internet.
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

  • "object reference not set to an instance of an object" after update datasource lightswitch

    I'm using Latest Visual Studio 2013 Ultimate (2013.3) and when I attempt to open "update datasource"  it throws an error
    "Object reference not set to instance of an object." 

    It's quite possibly an issue with the data source definition being dependent on a newer version of a lightswitch framework DLL.  When I've hit these kinds of issues I've simply deleted the datasource, run a nuget refresh and added the datasource again.
     If you have any code or queries, save a copy of the code-behind files and jot down the details of the queries before you try this.

  • Object reference not set to an instance of an object. at Microsoft.Office.Server.Administration.UserProfileApplicationProxy.

    Hello.
    I just installed a new farm, the wizard was succesfull in all steps.  However when I try to load the default site it created I got this exception.
    Any idea?
    System.NullReferenceException: Object reference not set to an instance of an object.    at Microsoft.Office.Server.Administration.UserProfileApplicationProxy.get_ApplicationProperties()     at Microsoft.Office.Server.Administration.UserProfileApplicationProxy.get_PartitionIDs()
        at Microsoft.Office.Server.Administration.UserProfileApplicationProxy.IsAvailable(SPServiceContext serviceContext)     at Microsoft.Office.Server.WebControls.MyLinksRibbon.get_PortalAvailable()     at Microsoft.Office.Server.WebControls.MyLinksRibbon.EnsureMySiteUrls()
        at Microsoft.Office.Server.WebControls.MyLinksRibbon.get_PortalMySiteUrlAvailable()     at Microsoft.Office.Server.WebControls.MyLinksRibbon.OnLoad(EventArgs e)     at System.Web.UI.Control.LoadRecursive()     at
    System.Web.UI.Control.LoadRecu...
    Follow me on Twitter <<<

    I tried removing the user profile service application and creating it again, when I did that, and tried to navigate to the page to manager the user profile application it shows me an exception
    According to the uls log viewer its;
    Microsoft.Office.Server.UserProfiles.UserProfileApplicationNotAvailableException: This User Profile Application's connection is currently not available. The Application Pool or User Profile Service may not have been started. Please contact your administrator.
       at Microsoft.SharePoint.Portal.UserProfiles.AdminUI.ProfileAdminPage.get_CurrentApplicationProxy()     at Microsoft.SharePoint.Portal.UserProfiles.AdminUI.ProfileAdminPage.IsProfileSynchronizationRunning()     at Microsoft.SharePoint.Portal.WebControls.UserProfileServiceImportStatisticsWebPart.RenderSectionContents(HtmlTextWriter
    writer)     at Microsoft.SharePoint.Portal.WebControls.UserProfileServiceImportStatisticsWebPart.RenderWebPart(HtmlTextWriter writer)     at Microsoft.SharePoint.WebPartPages.WebPart.Render(HtmlTextWriter ...
    I checked and the sharepoint web services default was stopped, I started and still the same error,  that pool is under Local Service account.
    Follow me on Twitter <<<

  • "Object reference not set to an instance of an object" in WAD

    10:45:09.659 ########## --> com.sap.bi.et.wad.wadhtmlediting.WADctlWADHTMLControl.SwitchEditable ##########
    -EXCEPTION-START- 10:45:09.659: DEBUG ### Browser Init failed. 2nd try will be proceeded. ---
    Exception Message: Object reference not set to an instance of an object.
    Exception    at SAPWADMXHTML.IWADMXBrowser2.AttachAnnotator(Boolean On)
       at com.sap.bi.et.wad.AxSAPWADMXHTML.AxCWADMXBrowser2.AttachAnnotator(Boolean on)
       at com.sap.bi.et.wad.wadhtmlediting.WADctlWADHTMLControl.SwitchEditable(Boolean iBool)
    Full Stack:
         at com.sap.bi.et.wad.Debug.WriteTraceToFile(Level, String, Exception)
         at com.sap.bi.et.wad.Debug.Exception(Exception, String)
         at com.sap.bi.et.wad.wadhtmlediting.WADctlWADHTMLControl.SwitchEditable(Boolean)
         at com.sap.bi.et.wad.wadhtmlediting.WADctlWADHTMLControl.set_BrowserDesignMode(Boolean)
         at com.sap.bi.et.wad.wadhtmlediting.WADctlWADHTMLControl.Navigate(String, Boolean)
         at com.sap.bi.et.wad.wadhtmlediting.WADctlWADHTMLControl.SetHTMLsafe(String, Boolean)
         at com.sap.bi.et.wad.wadhtmlediting.WADctlWADHTMLControl.SetHTML(String, Boolean)
         at com.sap.bi.et.wad.man.WADctlEditViewLayout.SetDocumentHTML(String)
         at com.sap.bi.et.wad.man.WADctlEditViewLayout.TemplateXML2HTMLEdit()
         at com.sap.bi.et.wad.man.WADfrmTemplateMDIWindow.UpdateView(Int32, Int32, Boolean)
         at com.sap.bi.et.wad.man.WADfrmTemplateMDIWindow.tabLayoutTab_Switch(Object, EventArgs)
         at System.Windows.Forms.TabControl.OnSelectedIndexChanged(EventArgs)
         at System.Windows.Forms.TabControl.WmSelChange(Message&)
         at System.Windows.Forms.TabControl.WndProc(Message&)
         at System.Windows.Forms.ControlNativeWindow.OnMessage(Message&)
         at System.Windows.Forms.ControlNativeWindow.WndProc(Message&)
         at System.Windows.Forms.NativeWindow.Callback(IntPtr, Int32, IntPtr, IntPtr)
         at System.Windows.Forms.UnsafeNativeMethods.SendMessage(HandleRef, Int32, IntPtr, IntPtr)
         at System.Windows.Forms.Control.SendMessage(Int32, IntPtr, IntPtr)
         at System.Windows.Forms.Control.ReflectMessageInternal(IntPtr, Message&)
         at System.Windows.Forms.Control.WmNotify(Message&)
         at System.Windows.Forms.Control.WndProc(Message&)
         at System.Windows.Forms.ScrollableControl.WndProc(Message&)
         at System.Windows.Forms.ContainerControl.WndProc(Message&)
         at System.Windows.Forms.Form.WndProc(Message&)
         at System.Windows.Forms.ControlNativeWindow.OnMessage(Message&)
         at System.Windows.Forms.ControlNativeWindow.WndProc(Message&)
         at System.Windows.Forms.NativeWindow.Callback(IntPtr, Int32, IntPtr, IntPtr)
         at System.Windows.Forms.UnsafeNativeMethods.CallWindowProc(IntPtr, IntPtr, Int32, IntPtr, IntPtr)
         at System.Windows.Forms.NativeWindow.DefWndProc(Message&)
         at System.Windows.Forms.Control.DefWndProc(Message&)
         at System.Windows.Forms.Control.WmMouseDown(Message&, MouseButtons, Int32)
         at System.Windows.Forms.Control.WndProc(Message&)
         at System.Windows.Forms.TabControl.WndProc(Message&)
         at System.Windows.Forms.ControlNativeWindow.OnMessage(Message&)
         at System.Windows.Forms.ControlNativeWindow.WndProc(Message&)
         at System.Windows.Forms.NativeWindow.Callback(IntPtr, Int32, IntPtr, IntPtr)
         at System.Windows.Forms.UnsafeNativeMethods.DispatchMessageW(MSG&)
         at System.Windows.Forms.ComponentManager.System.Windows.Forms.UnsafeNativeMethods+IMsoComponentManager.FPushMessageLoop(Int32, Int32, Int32)
         at System.Windows.Forms.ThreadContext.RunMessageLoopInner(Int32, ApplicationContext)
         at System.Windows.Forms.ThreadContext.RunMessageLoop(Int32, ApplicationContext)
         at System.Windows.Forms.Application.Run(Form)
         at com.sap.bi.et.wad.BexWebApplicationDesigner.Launch.Main()
    -EXCEPTION-END----

    Hello Dieu,
    Have you found a solution of this exception?? i also come across this one.
    Kind Regards,
    Clark

  • "object reference not set to an instance of an object" error while running ssrs report locally

    Hi Folks,
    I am a bit new to SSRS.
    I am using ssrs 2012 and trying to use a method from a dll file. I am loaded the assembly file in reference of the report.
    Now I am trying to use a static method from the Dll. e.g. applicationName.classname.MethodName()
    But while running the report I am getting "object reference not set to an instance of an object" error.
    For a note I am trying execute the report locally.
    Any help would be highly appreciable.
    sarat chandra sahoo

    Sorry for late reply Sinaloe..
    I have added a dll file in my report reference. And in a textbox trying to execute this below.
    =Recall.Common.LocalizationEx.Localization.GetString(Parameters!Culture.Value, "RFID", "BICustomerPortal")
    where Getstring() is a static method in the dll.
    I guess some configuration setting I am missing here.
    1. I have copied these dlls in "C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\PrivateAssemblies" and "C:\Windows\Assembly".
    sarat chandra sahoo

  • Object reference not set to an instance of an object error with Import data

    Hi Experts,
    We are using BPC 7.5M with SQL Server 2008 in Multiserver environment, I am getting an error "Object reference not set to an instance of an object." while running Import data package, earlier we use to get this error sometime(once in a month) but it goes away if we reboot the application server but this time I have rebotted the Application server multiple times but still getting the same error.
    Please Advice.
    Thanks & Regards,
    Rohit

    Hi Rohit,
    please see the sap note 1615837, maybe this help you.
    Best regards
    Roberto Vidotti

  • Object reference not set to an instance of an object. in Query disigner

    Using the Bex query desingne we get the following message:
    An unhandled exception occured in your application etc
    Object reference not set to an instance of an object.
    Details are:
    System.NullReferenceException: Object reference not set to an instance of an object.
       at com.sap.bi.et.QueryDesigner.QDcElement.Contains(QDbElement iValue)
       at com.sap.bi.et.QueryDesigner.QDbElement.WhereUsedAdd(QDbElement iElement)
       at com.sap.bi.et.QueryDesigner.QDbStructureMemberFormula.WhereUsedAdd(QDbElement iElement)
       at com.sap.bi.et.QueryDesigner.QDbElement.FromUndoTable(RSZ_X_ELTXREF isWhereUsed, QDcElement iElements)
       at com.sap.bi.et.QueryDesigner.QDbElement.FromTables(Hashtable iTables, QDcElement iElements)
       at com.sap.bi.et.QueryDesigner.QDbElement.Undo(QDbUndoRedoBuffer cUndoBuffer, QDbUndoRedoBuffer& cRedoBuffer)
       at com.sap.bi.et.QueryDesigner.QDbCommandEditElement.Undo()
       at com.sap.bi.et.QueryDesigner.QDbCommandEditElement.EditFormula(IQDView iSelectedView)
       at com.sap.bi.et.QueryDesigner.QDbCommandEditElement.ExecuteCommand()
       at com.sap.bi.et.QueryDesigner.QDbCommandBase.Execute()
       at com.sap.bi.et.QueryDesigner.QDbCommandManager.CommandExecute(QDbCommandBase iCommand)
       at com.sap.bi.et.QueryDesigner.QDbCommandManager.InitialCommandExecute(QDbCommandBase iCommand)
       at com.sap.bi.et.QueryDesigner.QDbCommandManager.DoExecuteCommandInternal()
       at com.sap.bi.et.QueryDesigner.QDiButtonCommand.Execute()
       at com.sap.bi.et.QueryDesigner.QDiButtonCommand.OnClick(EventArgs e)
       at System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent)
       at Syncfusion.Windows.Forms.ButtonAdv.OnMouseUp(MouseEventArgs e)
       at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
       at System.Windows.Forms.Control.WndProc(Message& m)
       at System.Windows.Forms.ButtonBase.WndProc(Message& m)
       at System.Windows.Forms.Button.WndProc(Message& m)
       at System.Windows.Forms.ControlNativeWindow.OnMessage(Message& m)
       at System.Windows.Forms.ControlNativeWindow.WndProc(Message& m)
       at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

    Thanks for the suggestion Deepu. I looked at the available downloads and saw there was a SP13 available, so I downloaded that and will try this on Monday May 21st.
    I will also check the .NET 1.1 framwork and hotfixes.

  • "Object reference not set to an instance of an object" when I try to deploy my Azure Cloud Service via CLI

    I'm running this command in the Azure PowerShell to deploy my node project as a service:
    Publish-AzureServiceProject -ServiceName <name> -Location "East US"
    Using my service name instead of <name>.
    Each time I run this, I get an error:
    Publish-AzureServiceProject : Object reference not set to an instance of an
    object.
    At line:1 char:1
    + Publish-AzureServiceProject -ServiceName <name> -Location "East US"
    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo : CloseError: (:) [Publish-AzureServiceProject], N
    ullReferenceException
    + FullyQualifiedErrorId : Microsoft.WindowsAzure.Commands.CloudService.Pub
    lishAzureServiceProjectCommand
    I have added my certificate and verified it with Get-AzureSubscription.
    Can anyone help?

    When I run Get-AzureSubscription, the subscription already seems to be set. I assume this happened when I imported my publish settings. I tried your suggestion to do it manually, but this didn't fix my problem.
    I've started implementing the deployment script linked in the blog post, but I'm running into all sorts of problems as I try to do so. First, this seems to assume I have a service package and publish settings. I'm guessing the package is going to need to
    be generated for each deployment, but the script doesn't handle this. How can I also have the script generate the new package so that the service can be deployed? I've currently hard-coded the path of cspack into the script, but this seems like a bad way to
    do it.
    Since the publish settings have the certificate, I imagine I don't want to commit those to version control. Can I also generate this as part of the script? I want the script to be as hands-off as possible.
    Thank you for your help!

  • Object reference not set to an instance of an object.at Microsoft.SharePoint.ApplicationPages.VersionsPage.ItemVersion

    I am getting an object reference not found error when trying to view the version history of any list item within my web application, as well as view or edit any list item properties in general.  Below is what the ULS log generates when I try to view
    the version history of an item.
    System.NullReferenceException: Object reference not set to an instance of an object.   
     at Microsoft.SharePoint.ApplicationPages.VersionsPage.ItemVersion.get_CreatedBy()    
     at ASP._layouts_versions_aspx.__Render__control14(HtmlTextWriter __w, Control parameterContainer)    
     at System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children)    
     at System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children)    
     at System.Web.UI.HtmlControls.HtmlContainerControl.Render(HtmlTextWriter writer)    
     at System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children)    
     at System.Web.UI.HtmlControls.HtmlForm.RenderChildren(HtmlTextWriter writer)    
     at System.Web.UI.HtmlControls.HtmlForm.Render(HtmlTextWriter output)    
     at System.Web.UI.HtmlControls.HtmlForm.RenderControl(HtmlTextWriter writer)    
     at System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children)    
     at System.Web.UI.HtmlControls.HtmlContainerControl.Render(HtmlTextWriter writer)    
     at System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children)    
     at System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children)    
     at Microsoft.SharePoint.WebControls.UnsecuredLayoutsPageBase.RenderChildren(HtmlTextWriter writer)    
     at System.Web.UI.Page.Render(HtmlTextWriter writer)    
     at Microsoft.SharePoint.WebControls.UnsecuredLayoutsPageBase.Render(HtmlTextWriter writer)    
     at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
    I followed what was said in this blog post to remove any extraneous calls of the "Microsoft.Sharepoint.ApplicationPages.dll"
    in the GAC or the bin folder of the web application, yet I am still getting the same error.

    Hi Max, did you ever get this resolved? if yes, what were steps?  thanks
    Stacy www.sharepointpapa.com

  • "Object reference not set to an instance of an object" error while accessing document libraries after in place upgrade to SP 2010

    I performed an inplace upgrade on my sharepoint 2007 installation and post the upgrade while trying to browse the document libraries on the site i get the following Error. HAs anyone encountered a similair error?? What could be the cause and resolution
    for this
    Any pointers/solution appreciated.
    Description: An
    unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. 
    Exception
    Details: System.NullReferenceException: Object reference not set to an instance of an object.
    Source
    Error: 
    An unhandled exception was generated during the execution of the
    current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
    Stack
    Trace: 
    [NullReferenceException: Object reference not set to an instance of an object.]
    Microsoft.SharePoint.WebPartPages.ListViewWebPart.PrepareContentTypeFilter(SPList list, Hashtable[] excludedTransformers) +682
    Microsoft.SharePoint.WebPartPages.ListViewWebPart.GenerateDocConvScriptBlock(SPWeb web, SPList list) +482
    Microsoft.SharePoint.WebPartPages.XsltListViewWebPart.OnPreRender(EventArgs e) +571
    Microsoft.SharePoint.WebPartPages.WebPartMobileAdapter.OnPreRender(EventArgs e) +78
    System.Web.UI.Control.PreRenderRecursiveInternal() +11032094
    System.Web.UI.Control.PreRenderRecursiveInternal() +223
    System.Web.UI.Control.PreRenderRecursiveInternal() +223
    System.Web.UI.Control.PreRenderRecursiveInternal() +223
    System.Web.UI.Control.PreRenderRecursiveInternal() +223
    System.Web.UI.Control.PreRenderRecursiveInternal() +223
    System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +3393
    Version
    Information: Microsoft .NET Framework Version:2.0.50727.4952; ASP.NET Version:2.0.50727.4955
    My SharePoint Blog
    http://dhireny.blogspot.com

    How to be in my case??
    [NullReferenceException: Object reference not set to an instance of an object.]
    Microsoft.SharePoint.WebPartPages.ListViewWebPart.PrepareContentTypeFilter(SPList list, Hashtable[] excludedTransformers) +694
    Microsoft.SharePoint.WebPartPages.ListViewWebPart.GenerateDocConvScriptBlock(SPWeb web, SPList list) +482
    Microsoft.SharePoint.WebPartPages.XsltListViewWebPart.OnPreRender(EventArgs e) +571
    Microsoft.SharePoint.WebPartPages.WebPartMobileAdapter.OnPreRender(EventArgs e) +78
    System.Web.UI.Control.PreRenderRecursiveInternal() +11141054
    System.Web.UI.Control.PreRenderRecursiveInternal() +223
    System.Web.UI.Control.PreRenderRecursiveInternal() +223
    System.Web.UI.Control.PreRenderRecursiveInternal() +223
    System.Web.UI.Control.PreRenderRecursiveInternal() +223
    System.Web.UI.Control.PreRenderRecursiveInternal() +223
    System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +3393

  • "Object reference not set to an instance of an object" after view selection

    Hello,
    I have a Visual Studio LightSwitch project where I connect to a Oracle server and select a view as a new data source.
    I get a error message "Object reference not set to an instance of an object" after selecting the Oracle view as a data source.
    The Visual Studio Log shows me following details in the ActivityLog:
    362 End package load [Visual Studio Explorers and Designers Package] {8D8529D3-625D-4496-8354-3DAD630ECC1B} VisualStudio 2011/09/05 12:17:58.258
    *363 ERROR OracleConnectionUIControl.ProcessParentFormAcceptButtonClick - Exception opening the connection. Oracle Data Provider for .NET ORA-12560: TNS: Fehler bei Protokolladapter at Oracle.DataAccess.Client.OracleException.HandleErrorHelper(Int32 errCode, OracleConnection conn, IntPtr opsErrCtx, OpoSqlValCtx pOpoSqlValCtx, Object src, String procedure, Boolean bCheck) at Oracle.DataAccess.Client.OracleException.HandleError(Int32 errCode, OracleConnection conn, IntPtr opsErrCtx, Object src) at Oracle.DataAccess.Client.OracleConnection.Open() at Oracle.VsDevTools.DDEX.OracleConnectionProperties.Test() at Oracle.VsDevTools.DDEX.OracleConnectionUIControl.ProcessParentFormAcceptButtonClick(Object sender, EventArgs e) {D601BB95-E404-4A8E-9F24-5C1A462426CE} Oracle Developer Tools for Visual Studio 2011/09/05 12:18:05.652*
    364 OracleVSGPkg.QueryClose - Begin Oracle Developer Tools VS Package Query Close {D601BB95-E404-4A8E-9F24-5C1A462426CE} Oracle Developer Tools for Visual Studio 2011/09/05 12:18:32.001
    But this error ORA-12560 does not make any sense, because I have got a working connection to the Oracle server and can see tables and views.
    Any ideas?
    Environment:
    Visual Studio 2010 SP 1
    Windows Server 2008 R2
    ODAC 11.2.0.2.40 Beta 2 for Entity Framework and LINQ to Entities
    Regards
    Benjamin

    Hi, did you ever resolve this? I have the same problem.
    Thanks,
    Mike

  • Object reference not set to an instance of an object in treeView

    Hello
    I wrote this code. I have this Error "Object reference not set to an instance of an object" on  " MessageBox.Show(tn.Text);"
    in " MaintreeView_BeforeSelect ".
    #region Remove BackColor of all treeview nodes
    private void ClearBackColor()
    TreeNodeCollection nodes = MaintreeView.Nodes;
    foreach (TreeNode tn in nodes)
    ClearRecursive(tn);
    private void ClearRecursive(TreeNode treeNode)
    foreach (TreeNode tn in treeNode.Nodes)
    tn.BackColor = Color.Empty;
    if(tn.IsSelected == true)
    tn.TreeView.SelectedNode = null;
    ClearRecursive(tn);
    #endregion
    private void MaintreeView_BeforeSelect(object sender, TreeViewCancelEventArgs e)
    ClearBackColor();
    TreeNode tn = MaintreeView.SelectedNode;
    if (tn != null)
    MessageBox.Show(tn.Text);
    if (tn.Level == 7)

    Hi ARZARE,
    I tested your code, it can show the tn.Text when in the rootnode.
    I suggest you putting the ClearBackColor() at the last of the BeforeSelect Event. Or this method will clear the selectNode.
    private void treeView1_BeforeSelect(object sender, TreeViewCancelEventArgs e)
    //ClearBackColor();
    TreeNode tn = this.treeView1.SelectedNode;
    if (tn != null)
    MessageBox.Show(tn.Text);
    ClearBackColor();
    If you have any other concern regarding this issue, please feel free to let me know.
    Best regards,
    Youjun Tang
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

Maybe you are looking for

  • Order qty Based on ROH qty

    Hi I want to round off my order qty based on ROH. Say ROH is available multiples of 0.6 TONS.My Fert is need to plan so to that it consumes  0.6 ,1.2 , 1.8 etc TONS. Without using Material-Qty calculatiuon is it possible?? Because I am using Discrete

  • Can SID of R12 database be changed after installation?

    Hi We have R12 vision instance running on a server. Can SID of its database be changed without change in the data inserted by the development team ie keeping the data & rest all intact? Regards JIL

  • Web service - document style

    Hi all, I need to create web service component which will accept SOAPMessages as request. Pls find my requirement below. 1. I have to use document oriented style. 2. I should not use apache ant script rather that i need to use weblogic ant script 3.

  • How to view sent mail on iPad mini?

    I can find my sent mail on my iPad mini. Where is it?

  • No Scene Detect option in HDV project only SD

    When capturing my HD footages, I've noticed that the scene detect option is grayed out but when I downconvert the HD footage and capture into a SD project, the option then becomes avail. Does this feature only work in SD projects?