Notification - reference object/reference documents

hi all,
When I create a new notification number for a given notification type in our system, there is a subscreen for reference object (such as material number) and reference document (such as production order number)
Is it possible to have a notification created for more than one material number or more than one production order?
Does this have to be with ABAP defining new screens?
Thanks,
neo

Hi Neo,
there's a new feature since EHP 5.
Check this:
Assigned Objects - Quality Notifications (QM-QN) - SAP Library
This is the only way I know to assign more than one object to a notification (without ABAP),
Chris

Similar Messages

  • Quality notification - more reference objects

    Hello,
    business need is to have quality notification with possibility to refer either production order or purchase order under one notification type.
    By standard this seems not possible as:
    Complaint Against Vendor references to Purchase order
    Internal Problem Report references to Production order.
    But in section "User-specific notification" is mentioned
    A user-specific notification type has the same basic structure as the standard, predefined notification types. The screen layouts, reference objects, and tab indexes, however, may differ from those in the predefined notification types, depending on how you customize the user-specific notification type.
    But I have not found a way in customizing to enable this.
    Advice appreciated.
    Br, Jan

    Thanks for the asnwer, but I think this does not solve my problem.
    In the configuaration for "Notification Header and Screen Areas" I do have
    - notification header screen H500
    - customized screen O550 (BADI)
    and both are needed.
    The BADI is used to customize refernce object screen, not reference documents screen. But my idea was to change reference document screen area in a way, that both purhcasing and production reference documents are visible in there.
    I only managed to get the vendor screen by adding screen area 037 to "Extended View: Tabstrips and Screen Areas" But adding purhcase document as reference to Reference documents remains my problem.
    I am kind of able to make the vendor screen visible by e.g. adding screen area 037 Partner overview screen (table control).But creating a new pop-up window for notification reference, where both options (pur ord, prod ord) would be available with copying functionality - in my opinion this requiers completely custom coding.

  • "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

  • Notification: Set priority and dates, based on the reference object

    Hello,
    I'm searching for an idea/solution, to set the priority of a notification automatically, depending on the entered reference object (F/L or equi).
    I.e. I want to classify the F/Ls and equis with a priority (e.g. via the classification, or F/L / equi master data). When the user creates a notification, and enters a F/L or equi, the priority should be selected from the object and set automatically.
    Thanks for your answers!
    Best regards
    Stephan

    Hello Pete,
    thank you for your answer. Unfortunatelly both user-exits seem not to work for my problem.
    QQMA0025: Default values when adding a notification
    Priority and dates can be modified, but in this step you don't have the functional location. I thought, I can send a popup in this user-exit, to ask for the functional location, but the functional location is deleted in a later step (before the 1st display of the notification header), i.e. the user has to enter it again.
    QQMA0018: Deadline setting based on entered priority
    Here you can only modify the dates / times, but not the priority.
    Another show stopper is, that the exits will only be processed once, i.e. in both cases, a change of the functional location doesn't adjust the dates/times.
    It seems, that exit "Before saving the notification" (as far as I remember QQMA0014) could be a solution.
    I see 2 problems ->
    1. the user enters the F/L or equi and nothing happens to the priority / dates -> sending a popup in the saving process to inform the user about the changes, could be a solution.
    2. What to do, when the user has already maintained priority and/or dates/times?
    I will have a look, if there are enhancement spots in the notification program. Perhaps this can help me (or better - my boss ).
    Best regards
    Stephan

  • Inserting Object link as reference object in Maint Order/Notification

    Dear all,
    I've mapped pipe line using obejct link,now when i create Maint Order or Notification system displays below mentioned message,
    Select a link object as reference object
    Message no. IH101
    Diagnosis
    You are trying to create an order or a notification for a link object, but have not yet selected an object.
    Procedure
    Place the cursor on a link object. This object will be entered in the notification or order as the object referred to.
    In std Screen RefObject thers is no ref object for Link,
    Please guide me how we can create Maint.Order/Notification against Object Link,as it is required to track cost as well as history of repairs in pipe line.
    Thanks in advance
    Regards
    Parshil
    Edited by: PM_in_SAP on Jul 27, 2010 9:19 AM

    Hi,
    i refer page no 18 of SAP book Object Networking (CS-BD/PM-EQM-ON) SAP AG Release 4.6C,
    To select a particular link from the list, (IN18)select the object link and choose one of the following options:
    Goto --> Change/Display --> link, You reach the object link data screen.
    Goto -->Create notification  --> Notification type
    You reach the screen where you can create a maintenance notification for the link. If a link object is entered for the selected link, the system automatically uses it as a reference object for the notification.
    Goto --> Create order
    You reach the screen where you can create a maintenance order for the link. If a link the system automatically uses it as a
    reference object for the order.
    Regards
    Parshil
    Edited by: PM_in_SAP on Jul 27, 2010 11:22 AM

  • Microsoft Visual Studio is unable to load this document: Object reference is not set to an instance of an object

    Hi Everyone,
    Please help me on this issue. I'm a new SSIS User.
    I've installed Sql Server 2005 Developer Edition
    When I create a new SSIS Project in Business Intelligence Development Studio,
    I get the following message:
    "Microsoft Visual Studio is unable to load this document: Object reference is not set to an instance of an object".
    Error loading 'package.dtsx'bject reference is not set to an instance of an object
    When I try to debug the package, I get the below message:
    parameter Component(System.Design) is null.
    I've uninstalled and installed SS 2005 several times, yet the problem persists.
    Please help.
    This is the package.dtsx
    <?xml version="1.0"?><DTS:Executable xmlnsTS="www.microsoft.com/SqlServer/Dts" DTS:ExecutableType="MSDTS.Package.1"><DTSroperty DTS:Name="PackageFormatVersion">2</DTSroperty><DTSroperty DTS:Name="VersionComments"></DTSroperty><DTSroperty DTS:Name="CreatorName">US\kothand1</DTSroperty><DTSroperty DTS:Name="CreatorComputerName">US6051KOTHAND1</DTSroperty><DTSroperty DTS:Name="CreationDate" DTSataType="7">4/8/2008 10:53:39 AM</DTSroperty><DTSroperty DTS:Name="PackageType">5</DTSroperty><DTSroperty DTS:Name="ProtectionLevel">1</DTSroperty><DTSroperty DTS:Name="MaxConcurrentExecutables">-1</DTSroperty><DTSroperty DTS:Name="PackagePriorityClass">0</DTSroperty><DTSroperty DTS:Name="VersionMajor">1</DTSroperty><DTSroperty DTS:Name="VersionMinor">0</DTSroperty><DTSroperty DTS:Name="VersionBuild">0</DTSroperty><DTSroperty DTS:Name="VersionGUID">{FBD98635-EDDE-4F58-9D53-356E8CB653FB}</DTSroperty><DTSroperty DTS:Name="EnableConfig">0</DTSroperty><DTSroperty DTS:Name="CheckpointFileName"></DTSroperty><DTSroperty DTS:Name="SaveCheckpoints">0</DTSroperty><DTSroperty DTS:Name="CheckpointUsage">0</DTSroperty><DTSroperty DTS:Name="SuppressConfigurationWarnings">0</DTSroperty><DTSroperty DTS:Name="ForceExecValue">0</DTSroperty><DTSroperty DTS:Name="ExecValue" DTSataType="3">0</DTSroperty><DTSroperty DTS:Name="ForceExecutionResult">-1</DTSroperty><DTSroperty DTS:Name="Disabled">0</DTSroperty><DTSroperty DTS:Name="FailPackageOnFailure">0</DTSroperty><DTSroperty DTS:Name="FailParentOnFailure">0</DTSroperty><DTSroperty DTS:Name="MaxErrorCount">1</DTSroperty><DTSroperty DTS:Name="ISOLevel">1048576</DTSroperty><DTSroperty DTS:Name="LocaleID">1033</DTSroperty><DTSroperty DTS:Name="TransactionOption">1</DTSroperty><DTSroperty DTS:Name="DelayValidation">0</DTSroperty>
    <DTS:LoggingOptions><DTSroperty DTS:Name="LoggingMode">0</DTSroperty><DTSroperty DTS:Name="FilterKind">1</DTSroperty><DTSroperty DTS:Name="EventFilter" DTSataType="8"></DTSroperty></DTS:LoggingOptions><DTSroperty DTS:Name="ObjectName">Package</DTSroperty><DTSroperty DTS:Name="DTSID">{191D188C-EA6E-46D6-A46A-8C9F3C21C321}</DTSroperty><DTSroperty DTS:Name="Description"></DTSroperty><DTSroperty DTS:Name="CreationName">MSDTS.Package.1</DTSroperty><DTSroperty DTS:Name="DisableEventHandlers">0</DTSroperty></DTS:Executable>
    Thanks
    Best Regards

    No I have not yet. I've applied just the windows updates. I rebooted after the updates, but the problem persists.
    I evern tried importing the .vssettings file from my co-worker's. Also, I tried resetting the user settings
    using "%programfiles%\Microsoft Visual Studio 8\Common7\IDE\devenv.exe" /resetuserdata.
    I'm on Windows xp 2002 service pack 2. Sql server 2005 Developer edition.
    Visual Studio info:
    Microsoft Visual Studio 2005
    Version 8.0.50727.762  (SP.050727-7600)
    Microsoft .NET Framework
    Version 2.0.50727 SP1
    Installed Edition: IDE Standard
    Microsoft Visual Studio 2005 Premier Partner Edition - ENU Service Pack 1 (KB926601)  
    This service pack is for Microsoft Visual Studio 2005 Premier Partner Edition - ENU.
    If you later install a more recent service pack, this service pack will be uninstalled automatically.
    For more information, visit http://support.microsoft.com/kb/926601
    SQL Server Analysis Services  
    Microsoft SQL Server Analysis Services Designer
    Version 9.00.1399.00
    SQL Server Integration Services  
    Microsoft SQL Server Integration Services Designer
    Version 9.00.1399.00
    SQL Server Reporting Services  
    Microsoft SQL Server Reporting Services Designers
    Version 9.00.1399.00
    Thanks
    Best regards

  • Sharepoint 2010 Error: System.NullReferenceException: Object reference not set to an instance of an object when trying to upload a document

    Hi,
    Environment: Windows server 2008 R2 , Sharepoint2010
    Getting the below error while uploading a document.  Below is the stack trace.
    System.NullReferenceException: Object reference not set to an instance of an object.    
    at Microsoft.Office.RecordsManagement.PolicyFeatures.ApplicationPages.UploadPage.GetEditFormUrl(SPWeb web, SPList currentList, SPFolder currentFolder, SPContentTypeId id, String comments, SPFile spfile, String sourceUrl, HttpRequest request)     
    at Microsoft.Office.RecordsManagement.PolicyFeatures.ApplicationPages.UploadPage.GetEditFormUrl(SPFile spfile)     
    at Microsoft.Office.RecordsManagement.PolicyFeatures.ApplicationPages.UploadPage.OnSubmit(Object o, EventArgs e)     
    at Microsoft.Office.RecordsManagement.PolicyFeatures.ApplicationPages.UploadExPage.OnSubmit(Object o, EventArgs e)     
    at System.Web.UI.HtmlControls.HtmlInputButton.OnServerClick(EventArgs e)     
    at System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument)     
    at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
    Still new in sharepoint, so no idea where to start.  Please advice.
    Thanks.

    Hi Alex,
    Do you have any update?
    Best Regards,
    Eric
    Eric Tao
    TechNet Community Support

  • F2 Notification type not picking reference object tab data

    Hello experts,
    I am facing a problem while creating notification. I have one lot of 01 inspection type(which is created after GRN) to which F2 notification type is attached. When i am trying to create notification against that lot, system is not fetching data in Reference Object Tab i.e. Material number, Plant, Material Doc, etc,.
    Please give me some solution on this.

    Dear all,
    i am adding screen shots of process which i am doing. Please have a look on it.
    1. I have done result recording in which i have rejected one parameter and closed RR. As i have not activated automatic defect recording it will allow me to save RR. Now i clicked on Defect recording.
    2. Selected report type 00000010 & defect recording at Inspection Lot Level.
    3. Added defect & clicked on Notification.
    4. Here no data is fetched.

  • Reference object in Notification and Order

    Hi ,
    I have a requirement to capture following in the reference Object for notification and  Order
    1. Functional Location
    2. Equipment
    3. Material
    4. Serial Number
    Configuration setting for overview of notification type doesn't have  the option to capture all the above fields.
    I am able to get all fields except Functional Location...
    Please guide me
    Regards
    Anil Kumar

    Anil,
    I have just been looking at this same requirement.
    Unfortunately you can only use the standard options for reference objects which does not allow for your requirement.
    There are no user-exits/BADIs either, you would need to build a new screen and screen-logic which is a system modification.
    The best I could do within the standard system is to include these fields on the Enhancement tab (user-exit IWO10018) or build a bespoke front-end via ABAP or HTML. GUIXT is another option.
    PeteA

  • Notification: Free Reference Object (BADI)

    Hi All,
    When we define Screen areas in Notification Header for any notification type, in Screen Type Object drop down there option O550 Object: Free Reference Object (BADI).
    Can anyone tell:
    1. What is the meaning of it
    2. Does this changes the options in Screen Structure in Extended View (while defining the screen areas)
    3. 'Free reference means, can we define our own fields in this
    Your answer will be really helpful.

    I suppose you can use this screen type object to define your own subscreen for the notification header (the three lines above the tabstrip). I played around with it a little, but I didn't do the complete implementation. There is a BADI "QM00_SUBSCR_5000". When you implement that BADI you can specify a custom program and dynpro for the screen header. Also, you will have to implement the methods to transport the notification data between your custom subscreen and the calling program.
    This is the documentation of the BADI "QM00_SUBSCR_5000":
    You can use this BAdI to implement the user-defined reference object screen according to your requirements. This implementation is dependent on the notification type.
    To perform this implementation, you must first have selected the value 0550 (object: user-defined reference object) in the "Object" screen type in Customizing for the notification type. You do this when maintaining the screen areas for the notification header.
    This Business Add-In allows you to display and maintain data related to notifications (VIQMEL).
    The following notification data is available in the subscreen that is called in the Business Add-In implementation:
    VIQMEL Notification header
    TQ80 Notification type
    MODUS Processing mode  ( H = Add, V = Change, A  = Display)
    You can return the complete VIQMEL (with changes) to the calling program.
    An active implementation of the Business Add-In already exists in the PLM Addon for the notification types QS (stability study with material reference and QR (stability study without material reference), which are delivered with the standard Customizing.
    Use this active implementation as a template for your customer-specific implementations.
    If you do not use the PLM Addon package, and want to implement this Business Add-In, use the delivered sample coding for the implementation of the methods as a template.

  • Reference Object Screens in QM notification

    Hi All,
    There are many fields in Reference object screen, but how do i see the fields while creating a QM notification. I see the standard screens 0520, 0500, etc.. and initial screens.
    How can i have these fields show up in the Notification header?
    Thanks
    Jithin

    We can execute action box to execute follow-up function. With a follow-up function, the system executes the corresponding function module as soon as we execute the follow-up function in the action box.
    With action box if you want to move stock to quality for inspection then you need to assign inspection type in material master. Once system will transfer stock in QI then it will create inspection lot for testing. If you don't want to create inspection lot then no need to assign inspection type.
    For more information please refer following SAP help link.
    [SAP Help1|http://help.sap.com/saphelp_erp60_sp/helpdata/en/dc/edbd3c793511d295d000a0c930e04c/content.htm]
    [SAP help2|http://help.sap.com/saphelp_erp60_sp/helpdata/en/6a/9927b6e8ad11d1954800a0c930e04c/content.htm]
    I hope it would help you.
    Thanks!!!

  • Reference object in Notification

    Dear All,
    I am new person in  the SAP-PM module but I need to work on it. I have a quarry, what is reference object and reference object key in notification creation, in which table I need to see the values of the same.
    Thanks and regards,
    Krish....

    Hi
       Notification we create with reference to some object.
    whch means it is refering some functional location , equipment etc.
    So it is address some object against wihc notification is creating.
    check  table QMFE
    regards
    Krishna

  • Web-UI error message "Access via 'NULL' object reference not possible"

    I need some help, I'm not a Basis person but I need to get this connection problem resolve.
    This problem is in our DEV ICWeb system.  After logging in to Web-UI, I got a error message "Access via 'NULL' object reference not possible".  We have 3 clients (100, 220, & 310) in DEV and all 3 clients are giving me the same error message.
    From the help.sap.com, I found this topic http://help.sap.com/saphelp_nwes70/helpdata/en/84/43f0d786304e19a652a8f80909a8ec/content.htm
    but in the document it asked to go to SM59 to check the ESH_APPL_WS_TEMPLATEENGINE destination.  But we don't have that destination setup in all our systems.
    Here is the complete error message:
    Error when processing your request
    What has happened?
    The URL http://crm-dev.staff.copa:8000/sap/bc/bsp/sap/crm_ui_frame/BSPWDApplication.do was not called due to an error.
    Note
    ■The following error text was processed in the system CD1 : Access via 'NULL' object reference not possible.
    ■The error occurred on the application server CRM-DEV_CD1_00 and in the work process 0 .
    ■The termination type was: RABAX_STATE
    ■The ABAP call stack was:
    Method: GET_DATA_LOSS_HANDLER of program CL_CRM_UI_CORE_APPL_CONTROLLERCP
    Method: GET_DATA_LOSS_HANDLER of program CL_CRM_UI_CORE_APPL_CONTROLLERCP
    Method: EH_TRIGGER_NAVIGATION of program CL_CRM_UI_CORE_APPL_CONTROLLERCP
    Method: SET_WORKAREA_CONTENT of program CL_CRM_UI_CORE_APPL_CONTROLLERCP
    Method: PROCESS_NAV_QUEUE of program CL_BSP_WD_VIEW_MANAGER========CP
    Method: DO_INIT of program CL_CRM_UI_FRAME_APP_CONTROLLERCP
    Method: DO_INIT of program CL_BSP_CTRL_ADAPTER===========CP
    Method: GET_PAGE_CONTEXT_CURRENT of program CL_BSP_CONTEXT================CP
    Method: ON_REQUEST_ENTER of program CL_BSP_RUNTIME================CP
    Method: ON_REQUEST of program CL_BSP_RUNTIME================CP
    What can I do?
    ■If the termination type was RABAX_STATE, then you can find more information on the cause of the termination in the system CD1 in transaction ST22.
    ■If the termination type was ABORT_MESSAGE_STATE, then you can find more information on the cause of the termination on the application server CRM-DEV_CD1_00 in transaction SM21.

    Hi Michael,
    Refer to the link below and check the procedure.
    http://help.sap.com/saphelp_nwes70/helpdata/en/84/43f0d786304e19a652a8f80909a8ec/content.htm
    Regards,
    Arjun

  • How to convert from Finder Object reference to POSIX path

    I'm new to AppleScript. I'm super close to getting what I need done, but I've ran across a snag in the middle.
    The error I'm getting is Can’t make quoted form of POSIX path of item 1 of {«class docf» \"filename\" of «class cfol» \"foldername\" of «class cfol» \"Desktop\" of «class cfol» \"Username\" of «class cfol» \"Users\" of «class sdsk» of application \"Finder\"} into type Unicode text. the problem area is highlighted and notated below. I've looked all around online but can't find what I need.
    Thanks in advance for any and all help!
    set text item delimiters to "."
    tell application "Finder"
      set theFilestoChoose to every item of (choose file with prompt "Please select the file(s) you would like to move and rename" with multiple selections allowed) as list
      display dialog "Would you like to move these files to an existing folder and then rename them, or create a new folder and then rename them?" buttons {"Move to an existing folder and rename", "Create a new folder and rename"}
      if result = {button returned:"Move to an existing folder and rename"} then
      set firstnewname to "Aauuttoommaattoorr"
      repeat with index from 1 to the count of theFilestoChoose
      set theFilesChosenbeingrenamedfirsttime to item index of theFilestoChoose
      set filenamecount to text items of (get name of theFilesChosenbeingrenamedfirsttime)
      if number of filenamecount is 1 then
      set fileextension to ""
      else
      set fileextension to "." & item -1 of filenamecount
      end if
      set the name of theFilesChosenbeingrenamedfirsttime to firstnewname & index & fileextension as string
      end repeat
      log theFilesChosenbeingrenamedfirsttime
      set choosingtheplacetomove to choose folder with prompt "Select the folder to move to"
      set thechosenfoldersname to name of folder choosingtheplacetomove -- sets the folder name as text
      set AppleScript's text item delimiters to {"-"}
      set Numberofthemonthatthebeginningofthefoldername to text item 1 of thechosenfoldersname as string -- for later to append the number back on without having to ask again!
      set shortenedname to text item 2 of thechosenfoldersname as string
      set the name of choosingtheplacetomove to shortenedname as string
      set thefolderstemporarynameaslocation to choosingtheplacetomove as string
      move theFilestoChoose to folder thefolderstemporarynameaslocation
      log theFilestoChoose
      set allfilesindestinationfolder to every file in choosingtheplacetomove as alias list --
      set aInitials to the text returned of (display dialog "Whose camera were this/these pictures taken on?" default answer "")
      set filteredList to my filterList(allfilesindestinationfolder, aInitials) as list
      log filteredList
      -- everything above this is correct so far and works perfect
      --TROUBLE SECTION BELOW
      set theSortedfilterList to (sort filteredList by creation date) -- something happens here with the theSortedfilterList that makes it unintelligible to convert to POSIX later. but I need the files in the order that this line puts them.
      log theSortedfilterList
      set timetorenamelasttime to theSortedfilterList
      set newbasename to shortenedname
      repeat with index from 1 to the count of timetorenamelasttime
      set theonefile to item index of timetorenamelasttime
      set theonefilenamecount to text items of (get name of theonetwothreefile)
      if number of theonefilenamecount is 1 then
      set fileextensionone to ""
      else
      set fileextensionone to "." & item -1 of theonefilenamecount
      end if
      tell application "System Events" to set CreaDate to creation date of file theonefile
      set CreaDate2 to CreaDate as text -- need to trim down to the first 10 characters and eliminate the "-"
      set AppleScript's text item delimiters to {""}
      set shorteneddatename to text items 1 thru 10 of CreaDate2 as string
      set the name of theonefile to shorteneddatename & {"-"} & newbasename & {"-"} & aInitials & {"-"} & index & fileextensionone as string
      end repeat
      --Trouble section above
      set the name of choosingtheplacetomove to Numberofthemonthatthebeginningofthefoldername & "-" & shortenedname as string -- returns the month prefix to the foldername
      else if result = {button returned:"Create a new folder and rename"} then
      set repeatConfirmation to true --Boolean to decided if script should be repeated; default is to repeat
      repeat while (repeatConfirmation = true) --Repeat if Any Tests Are Failed
      set thefirstquestion to choose from list {"January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"} with title "Event Month Selection" with prompt "Select the month in which the event started. Select only one month:"
      set theMonthAnswer to result
      if theMonthAnswer = false then --"For historical reasons, choose from list is the only dialog command that returns a result (false) instead of signaling an error when the user presses the “Cancel” button."
      set repeatConfirmation to false
      set exitingeventmonth to display dialog ("You are exiting selecting the event month phase of the program. You will need to manually fix this decision") buttons {"OK"} with title "Exiting Event Month Selection"
      if button returned of exitingeventmonth = "OK" then
      set theMonthAnswer to ""
      end if
      else
      set confirmationanswer to display dialog "You selected " & theMonthAnswer & ", is this correct? " buttons {"Yes, that's correct.", "No, the picture(s) are from a different month."} with title "Confirm Event Month Selection"
      if button returned of confirmationanswer = "Yes, that's correct." then
      set repeatConfirmation to false
      else
      display dialog ("That's okay, you can select another again!") buttons {"OK"} with title "Return to Event Month Selection"
      end if
      end if
      end repeat
      log theMonthAnswer
      if theMonthAnswer = "" then
      set monthtonumber to "You have cancelled this action."
      log monthtonumber
      else if theMonthAnswer = {"January"} then
      set monthtonumber to "01"
      log monthtonumber
      else if theMonthAnswer = {"February"} then
      set monthtonumber to "02"
      log monthtonumber
      else if theMonthAnswer = {"March"} then
      set monthtonumber to "03"
      log monthtonumber
      else if theMonthAnswer = {"April"} then
      set monthtonumber to "04"
      log monthtonumber
      else if theMonthAnswer = {"May"} then
      set monthtonumber to "05"
      log monthtonumber
      else if theMonthAnswer = {"June"} then
      set monthtonumber to "06"
      log monthtonumber
      else if theMonthAnswer = {"July"} then
      set monthtonumber to "07"
      log monthtonumber
      else if theMonthAnswer = {"August"} then
      set monthtonumber to "08"
      log monthtonumber
      else if theMonthAnswer = {"September"} then
      set monthtonumber to "09"
      log monthtonumber
      else if theMonthAnswer = {"October"} then
      set monthtonumber to "10"
      log monthtonumber
      else if theMonthAnswer = {"November"} then
      set monthtonumber to "11"
      log monthtonumber
      else if theMonthAnswer = {"December"} then
      set monthtonumber to "12"
      log monthtonumber
      end if
      set theNameofFoldertoMake to text returned of (display dialog "Please enter the name of the new folder you are creating:" default answer "" with title "New Folder Name")
      set LocationOfNewFolder to choose folder with prompt "Choose the location of the new folder you are creating:"
      set theNewNameofFoldertoMake to monthtonumber & "-" & theNameofFoldertoMake
      set newfolderaction to make new folder at LocationOfNewFolder with properties {name:theNewNameofFoldertoMake}
      move theFilestoChoose to newfolderaction
      end if
    end tell
    --function
    on filterList(allfilesindestinationfolder, aInitials)
      set patterns to {aInitials as string, "Aauuttoommaattoorr"}
      set output to {}
      repeat with aFile in the allfilesindestinationfolder
      repeat with aPattern in patterns
      set filepath to aFile as string
      if filepath contains aPattern then
      set end of the output to aFile
      exit repeat
      end if
      end repeat
      end repeat
      return output
    end filterList

    Okay, so you wanted the debugging and error messages. Thank you for the coaching. Here is what I get from the following line:
    set theSortedfilterList to (sort filteredList by creation date)
    log theSortedfilterList
    Log returns:
    (*document file Aauuttoommaattoorr3.AVI of folder SnowDay of folder Desktop of folder Username of folder Users of startup disk, document file Aauuttoommaattoorr2.MOV of folder SnowDay of folder Desktop of folder Username of folder Users of startup disk, document file Aauuttoommaattoorr1.mov of folder SnowDay of folder Desktop of folder Username of folder Users of startup disk*)
    set pxFile to POSIX path of ((theSortedfilterList) as alias)
    Error: "Can’t make {«class docf» \"Aauuttoommaattoorr3.AVI\" of «class cfol» \"SnowDay\" of «class cfol» \"Desktop\" of «class cfol» \"Username\" of «class cfol» \"Users\" of «class sdsk» of application \"Finder\", «class docf» \"Aauuttoommaattoorr2.MOV\" of «class cfol» \"SnowDay\" of «class cfol» \"Desktop\" of «class cfol» \" Username \" of «class cfol» \"Users\" of «class sdsk» of application \"Finder\", «class docf» \"Aauuttoommaattoorr1.mov\" of «class cfol» \"SnowDay\" of «class cfol» \"Desktop\" of «class cfol» \" Username \" of «class cfol» \"Users\" of «class sdsk» of application \"Finder\"} into type alias." number -1700 from {«class docf» "Aauuttoommaattoorr3.AVI" of «class cfol» "SnowDay" of «class cfol» "Desktop" of «class cfol» "Username" of «class cfol» "Users" of «class sdsk», «class docf» "Aauuttoommaattoorr2.MOV" of «class cfol» "SnowDay" of «class cfol» "Desktop" of «class cfol» "Username" of «class cfol» "Users" of «class sdsk», «class docf» "Aauuttoommaattoorr1.mov" of «class cfol» "SnowDay" of «class cfol» "Desktop" of «class cfol» "Username" of «class cfol» "Users" of «class sdsk»} to alias
    That is why I labeled it with Finder Object reference won’t return POSIX path, because I tried what was suggested about using the POSIX path of line. I thought seeing the lines above and around it would help set the context.
    So I need those files, but I need them sorted by creation date so that they’re in that order for the next renaming step.

  • Dump - Access using NULL object reference is not possible!!!

    Hi,
    I'm using the BCS class for sending HTM format email so i use the below code for that its working,
    DATA: gr_document      TYPE REF TO cl_document_bcs,
    gr_document = cl_document_bcs=>create_document(
                          i_type    = 'HTM'
                           i_text    = t_html
                           i_importance = '5'
                           i_subject = gc_subject ).
    Next task is to send the image so i'm creating an another object to the same class, below code
    *Image from MIME
    DATA: o_mr_api         TYPE REF TO if_mr_api.
    DATA is_folder TYPE boole_d.
    DATA l_img1 TYPE xstring.
    DATA l_img2 TYPE xstring.
    DATA l_loio TYPE skwf_io.
    DATA: lo_document   TYPE REF TO cl_document_bcs.
    IF o_mr_api IS INITIAL.
       o_mr_api = cl_mime_repository_api=>if_mr_api~get_api( ).
    ENDIF.
    CALL METHOD o_mr_api->get
       EXPORTING
         i_url              = '/SAP/PUBLIC/ZDEMO/tick.png'
       IMPORTING
         e_is_folder        = is_folder
         e_content          = l_img1
         e_loio             = l_loio
       EXCEPTIONS
         parameter_missing  = 1
         error_occured      = 2
         not_found          = 3
         permission_failure = 4
         OTHERS             = 5.
    CALL METHOD o_mr_api->get
       EXPORTING
         i_url              = '/SAP/PUBLIC/ZDEMO/Delete.png'
       IMPORTING
         e_is_folder        = is_folder
         e_content          = l_img2
         e_loio             = l_loio
       EXCEPTIONS
         parameter_missing  = 1
         error_occured      = 2
         not_found          = 3
         permission_failure = 4
         OTHERS             = 5.
    *Convert XSTRING to ITAB
    DATA :lt_hex1 TYPE solix_tab,
           lt_hex2 TYPE solix_tab,
           ls_hex LIKE LINE OF lt_hex1,
           lv_img1_size TYPE sood-objlen,
           lv_img2_size TYPE sood-objlen.
    CLEAR : lt_hex1, lt_hex2, ls_hex, lv_img1_size, lv_img2_size.
    WHILE l_img1 IS NOT INITIAL.
       ls_hex-line = l_img1.
       APPEND ls_hex TO lt_hex1.
       SHIFT l_img1 LEFT BY 255 PLACES IN BYTE MODE.
    ENDWHILE.
    WHILE l_img2 IS NOT INITIAL.
       ls_hex-line = l_img2.
       APPEND ls_hex TO lt_hex2.
       SHIFT l_img2 LEFT BY 255 PLACES IN BYTE MODE.
    ENDWHILE.
    *Findthe Size of the image
    DESCRIBE TABLE lt_hex1 LINES lv_img1_size.
    DESCRIBE TABLE lt_hex2 LINES lv_img2_size.
    lv_img1_size = lv_img1_size * 255.
    lv_img2_size = lv_img2_size * 255.
    *Attach Images
    clear: lo_document.
    lo_document->add_attachment(
       EXPORTING
         i_attachment_type     =  'png'                  " Document Class for Attachment
         i_attachment_subject  =  'img1'                " Attachment Title
         i_attachment_size     =  lv_img1_size           " Size of Document Content
         i_att_content_hex     =  lt_hex1  " Content (Binary)
    lo_document->add_attachment(
       EXPORTING
         i_attachment_type     =  'png'                  " Document Class for Attachment
         i_attachment_subject  =  'img2'                " Attachment Title
         i_attachment_size     =  lv_img2_size           " Size of Document Content
         i_att_content_hex     =  lt_hex2  " Content (Binary)
    but it throws the dump " Access using NULL object reference is not possible"  when i tries to access for method add_attachment...
    Thanks,
    Siva

    Yes there is commit work after that, Below code
          gr_document = cl_document_bcs=>create_document(
                           i_type    = 'HTM'
                            i_text    = t_html
                            i_importance = '5'
                            i_subject = gc_subject ).
    *Image from MIME
    DATA: o_mr_api         TYPE REF TO if_mr_api.
    DATA is_folder TYPE boole_d.
    DATA l_img1 TYPE xstring.
    DATA l_img2 TYPE xstring.
    DATA l_loio TYPE skwf_io.
    DATA: lo_document   TYPE REF TO cl_document_bcs.
    IF o_mr_api IS INITIAL.
       o_mr_api = cl_mime_repository_api=>if_mr_api~get_api( ).
    ENDIF.
    CALL METHOD o_mr_api->get
       EXPORTING
         i_url              = '/SAP/PUBLIC/ZDEMO/tick.png'
       IMPORTING
         e_is_folder        = is_folder
         e_content          = l_img1
         e_loio             = l_loio
       EXCEPTIONS
         parameter_missing  = 1
         error_occured      = 2
         not_found          = 3
         permission_failure = 4
         OTHERS             = 5.
    CALL METHOD o_mr_api->get
       EXPORTING
         i_url              = '/SAP/PUBLIC/ZDEMO/Delete.png'
       IMPORTING
         e_is_folder        = is_folder
         e_content          = l_img2
         e_loio             = l_loio
       EXCEPTIONS
         parameter_missing  = 1
         error_occured      = 2
         not_found          = 3
         permission_failure = 4
         OTHERS             = 5.
    *Convert XSTRING to ITAB
    DATA :lt_hex1 TYPE solix_tab,
           lt_hex2 TYPE solix_tab,
           ls_hex LIKE LINE OF lt_hex1,
           lv_img1_size TYPE sood-objlen,
           lv_img2_size TYPE sood-objlen.
    CLEAR : lt_hex1, lt_hex2, ls_hex, lv_img1_size, lv_img2_size.
    WHILE l_img1 IS NOT INITIAL.
       ls_hex-line = l_img1.
       APPEND ls_hex TO lt_hex1.
       SHIFT l_img1 LEFT BY 255 PLACES IN BYTE MODE.
    ENDWHILE.
    WHILE l_img2 IS NOT INITIAL.
       ls_hex-line = l_img2.
       APPEND ls_hex TO lt_hex2.
       SHIFT l_img2 LEFT BY 255 PLACES IN BYTE MODE.
    ENDWHILE.
    *Findthe Size of the image
    DESCRIBE TABLE lt_hex1 LINES lv_img1_size.
    DESCRIBE TABLE lt_hex2 LINES lv_img2_size.
    lv_img1_size = lv_img1_size * 255.
    lv_img2_size = lv_img2_size * 255.
    *Attach Images
    create object lo_document type cl_document_bcs.
    lo_document->add_attachment(
       EXPORTING
         i_attachment_type     =  'png'                  " Document Class for Attachment
         i_attachment_subject  =  'img1'                " Attachment Title
         i_attachment_size     =  lv_img1_size           " Size of Document Content
         i_att_content_hex     =  lt_hex1  " Content (Binary)
    lo_document->add_attachment(
       EXPORTING
         i_attachment_type     =  'png'                  " Document Class for Attachment
         i_attachment_subject  =  'img2'                " Attachment Title
         i_attachment_size     =  lv_img2_size           " Size of Document Content
         i_att_content_hex     =  lt_hex2  " Content (Binary)
           "Add document to send request
           CALL METHOD gr_send_request->set_document( gr_document ).
           TRY.
             CALL METHOD gr_send_request->SET_SEND_IMMEDIATELY
               EXPORTING
                 I_SEND_IMMEDIATELY = 'X'.
    *    CATCH CX_SEND_REQ_BCS INTO BCS_EXCEPTION .
    **Catch exception here
           ENDTRY.
           DATA: LO_SENDER TYPE REF TO IF_SENDER_BCS VALUE IS INITIAL.
           TRY.
             LO_SENDER = CL_SAPUSER_BCS=>CREATE( SY-UNAME ). "sender is the logged in user
    * Set sender to send request
             gr_send_request->SET_SENDER(
             EXPORTING
             I_SENDER = LO_SENDER ).
    *    CATCH CX_ADDRESS_BCS.
    ****Catch exception here
           ENDTRY.
           "Send email
           CALL METHOD gr_send_request->send(
             EXPORTING
               i_with_error_screen = 'X'
             RECEIVING
               result              = gv_sent_to_all ).
           IF gv_sent_to_all = 'X'.
             WRITE 'Email sent!'.
           ENDIF.
           "Commit to send email
           COMMIT WORK.
           "Exception handling
         CATCH cx_bcs INTO gr_bcs_exception.
           WRITE:
             'Error!',
             'Error type:',
             gr_bcs_exception->error_type.
       ENDTRY.

Maybe you are looking for