Powershell Variable from Excel.VBA Macro

Hi Guys!
I don't know if what i'm asking you is achievable.
I've learned how to pass variables/arguments from powershell to Excel/VBA Macro but i need to do the opposite thing.
This is an example of what  i want:
Powershell                                                                      
                   Excel/VBA Macro
$Input=1   ---------------------------------------------------------------->   Sub Macro(input)
$excel.Run("Macro",$Input)                                                              
  Output=input +6
$output (Expected 7)   <----------------------------------------------------  return Output
I don't know how to do this can you help me please?
A

Ok guys those are the script.
Macro:
Sub CreatePWD()
Dim PWD As String
Dim i As Integer
Dim Max As Integer
Dim F1 As Worksheet
Set F1 = ThisWorkbook.Worksheets("Foglio1")
Max = F1.Range("A1").Value
For i = 1 To Max
If Int((2 * Rnd) + 1) = 1 Then
PWD = PWD & Chr(Int((90 - 65 + 1) * Rnd + 65))
Else
PWD = PWD & Int((9 - 0 + 1) * Rnd + 0)
End If
Next i
MsgBox PWD
End Sub
Powershell:
$Excel = New-Object -ComObject excel.application
$Excel.visible=$false
$Version = "C:\Users\Alberto Corona\Desktop\Cartel1.xlsm"
$WorkBook= $Excel.workbooks.open($Version)
$WorkSheet= $WorkBook.worksheets.item(1)
$WorkSheet.cells.item(1,1)=5
$Excel.Run("CreatePWD")
$WorkBook.save()
$WorkBook.close()
$Excel.quit()
The result of macro is like "52UT7" i want a variable in powershell called $PWD that contain the value of the macro. 
Hope the problem is clear now.
Thanks
A

Similar Messages

  • Call Transaction from Excel VBA macro and download ALV list object results

    I have a situation that must be very common u2013 but I canu2019t find any clear information on how to get it done! 
    We frequently run SAP transactions, download the results (orders or inventory) into Excel, do some calculations and create a spreadsheet report. 
    I would like to automate this process using Excel VBA so that a macro will perform these steps:
    1. Run our custom SAP report "YSD033" that summarizes orders using the previous day as the [From Date] parameter.  (The user already has an active ECC 6 R3 session running.)   If possible, can the TC be run using a specific variant "G111BIZ" ?
    2. Download the list object that appears in an ALV grid as a table to an empty spreadsheet in the active workbook (export XXL list object)
    3. Save the resulting workbook and close Excel.
    Should the solution use u201Ccall transactionu201D or a GuiXT script?
    Any help would be much appreciated, and some sample VBA code would be great!
    Thanks.
    Glenn

    Good suggestion, but
    I get "permission denied" for   SapGuiAuto.GetScriptingEngine
    I also tried the method below, but received this RFC error message:
    User PPPPPPP  has no RFC authorization for function group SYST.
    Sub LoginCheck()
    If login = False Then
        ' Setting the necessary variables for R/3 connection
        Set objBAPICortrol = CreateObject("SAP.Functions")
        Set objConnection = objBAPICortrol.Connection
        ' Establish a connection
    If objConnection.Logon(0, False) Then
        login = True
        MsgBox "Connection Established"
        CommandButton1.Caption = "Disconnect"
    End If
    Else
        CommandButton1.Caption = "Connect 2 SAP"
        login = False
        objConnection.Logoff
        Set objConnection = Nothing
        Set objBAPICortrol = Nothing
    End If
    End Sub
    I was told that these kinds of authority open up too big of a window that can't be monitored adequately...
    I'm considering an approach like what is below if I can't convince security to grant me permissions...
        Application.Wait Now + TimeValue("00:00:01")
        SendKeys EnterKey, False
    Since blocked RFC security settings are preventing the solution from being installed, I am markgin this question as answered. 
    I will post different questions about 1. how to convince the security team that it will be safe to allow the use of RFC calls, and /or 2. how use some windows-level scripting code to run the SAP jobs.
    Thanks.
    Edited by: GlennWebster on Mar 1, 2010 4:34 PM

  • Problem with controlling Annotations from Excel VBA

    Hi,
    I have a PDF document that has plenty of sticky notes attached to it. These sticky notes have been added by multiple authors on all pages of the document. I am trying to import the contents of these sticky notes, their author and the page number to an excel spreadsheet.  I am using Excel 2007 and Acrobat Professional 9.0.
    This is the code that I am currently using to import the sticky notes, but the problem that I am facing is that when I run the macro -
    Same sticky note contents, author and page numbers are imported multiple times
    Not all sticky notes are imported, only some of them appear in the final excel spreadsheet
    When I compare the number of sticky notes to that in the original PDF file, the number is correct. But the content is repeated content and that is the reason why only some of the sticky notes are imported.
    This is an activity that I need to do on regular basis and the number of sticky notes that I need to import to excel may range between 100 to 200. It is really difficult to do this task manually, so an excel VBA macro could prove really helpful.
    Sub ImportComments_Click()
    Dim Fpath As String
    Dim WordObj As Object
    Dim wbkOutput As Excel.Workbook
    Dim iRow As Integer
    Dim i, j, k As Integer
    Dim lRet As Long
    Dim objAcroAVDoc As New Acrobat.acroAVDoc
    Dim objAcroPDDoc As Acrobat.AcroPDDoc
    Dim numPages As Long
    Dim lAnnotscnt As Long
    Dim Subtype As String
    Dim NumComments As Long
    Dim AcroApp As Acrobat.AcroApp
    Dim objAcroPDPage As Acrobat.AcroPDPage
    Dim annot As Acrobat.AcroPDAnnot
    Sheets("Defect Log").Select
    Range("L3").Activate
    Fpath = ActiveCell.Value
    Sheets("Defect Log").Select
    Range("A1").Activate
    i = 0
    Do While (Not (IsEmpty(ActiveCell.Value)) Or Not (IsEmpty(ActiveCell.Offset(0, 1).Value)) Or Not (IsEmpty(ActiveCell.Offset(0, 2).Value)) Or Not (IsEmpty(ActiveCell.Offset(0, 3).Value)) Or Not (IsEmpty(ActiveCell.Offset(0, 4).Value)) Or Not (IsEmpty(ActiveCell.Offset(0, 5).Value)) Or Not (IsEmpty(ActiveCell.Offset(0, 6).Value)) Or Not (IsEmpty(ActiveCell.Offset(0, 7).Value)) Or Not (IsEmpty(ActiveCell.Offset(0, 8).Value)) Or Not (IsEmpty(ActiveCell.Offset(0, 9).Value)) Or Not (IsEmpty(ActiveCell.Offset(0, 10).Value)) Or Not (IsEmpty(ActiveCell.Offset(0, 11).Value)) Or Not (IsEmpty(ActiveCell.Offset(0, 12).Value)) Or Not (IsEmpty(ActiveCell.Offset(0, 13).Value)) Or Not (IsEmpty(ActiveCell.Offset(0, 14).Value)))
    i = i + 1
    ActiveCell.Offset(1, 0).Select
    Loop
    iRow = i + 1
    Set wbkOutput = ActiveWorkbook
    lRet = objAcroAVDoc.Open(Fpath, "")
    Set objAcroPDDoc = objAcroAVDoc.GetPDDoc
    numPages = objAcroPDDoc.GetNumPages()
    Set objAcroPDPage = objAcroPDDoc.AcquirePage(0)
    For k = 1 To numPages
    lAnnotscnt = objAcroPDPage.GetNumAnnots()
    For m = 0 To lAnnotscnt - 1
    If lAnnotscnt = 0 Then Exit For
    Set objAcroPDAnnot = objAcroPDPage.GetAnnot(m)
    If (objAcroPDAnnot.GetContents <> "" And objAcroPDAnnot.GetSubtype = "Text") Then
    Cells(iRow, 5).Value = k
    Cells(iRow, 2).Value = objAcroPDAnnot.GetContents()
    Cells(iRow, 11).Value = objAcroPDAnnot.GetTitle()
    iRow = iRow + 1
    End If
    Next m
    Set objAcroPDPage = objAcroPDDoc.AcquirePage(k)
    Next k
    lRet = objAcroAVDoc.Close(1)
    Set objAcroAVDoc = Nothing
    Set objAcroPDAnnot = Nothing
    Set objAcroPDPage = Nothing
    Set objAcroPDDoc = Nothing
    End Sub

    Make sure you are current with 9.x patches, just on general principles.
    The code seems fine – nothing jumping out at me.
    You can also look at using the JSObject methods and trying this via the JavaScript stuff – that will give you more access to the Annotation information…
    From: Adobe Forums <[email protected]<mailto:[email protected]>>
    Reply-To: "[email protected]<mailto:[email protected]>" <[email protected]<mailto:[email protected]>>
    Date: Thu, 24 Nov 2011 04:25:12 -0800
    To: Leonard Rosenthol <[email protected]<mailto:[email protected]>>
    Subject: Problem with controlling Annotations from Excel VBA
    Problem with controlling Annotations from Excel VBA
    created by apreeti<http://forums.adobe.com/people/apreeti> in Acrobat SDK - View the full discussion<http://forums.adobe.com/message/4044740#4044740

  • How to call a labview dll from excel-VBA?

    How to call a simple Labview DLL from Excel VBA?
    I have seen examples of DLL calls from VB but does it work the same way for VBA? I have 2000 excel and Labview 8.5. I created the DLL and tried to call it from VBA using the same type of code as in NI's website example(ofcourse its a bit diff with 8.5)
    http://zone.ni.com/devzone/cda/tut/p/id/...
    BUT it errors out when called from excel
    ERROR: The object invoked has disconnected from its client

    You would need to provide more details about the LabVIEW DLL, such as the prototypes of the functions (VIs) that you're trying to call, and your actual VBA code. Specifically, what object you're trying to create. You should also make sure the Run-Time Enginer is installed, as well as any required libraries such as the VISA Run-Time if you're using VISA. Have you made sure to enable the ActiveX server for the DLL?
    A search yielded the following items that you may wish to peruse:
    http://forums.ni.com/ni/board/message?board.id=170&message.id=261345&requireLogin=False
    http://forums.ni.com/ni/board/message?board.id=170&message.id=45099&requireLogin=False
    http://forums.ni.com/ni/board/message?board.id=170&message.id=299209&requireLogin=False
    http://forums.ni.com/ni/board/message?board.id=170&message.id=195846&requireLogin=False

  • Acrobat 9.0 Standard. Setting PDF file password from Excel VBA

    Acrobat 9.0 Standard. Setting PDF file password from Excel VBA
    Hi: I am trying to find a call to set the password of a PDF file that I am creating from Excel Workbook using a VBA call.
    I basically have this Excel VBA code that works fine and creates a file.
                pBook.PrintOut Copies:=1, preview:=False, ActivePrinter:="Adobe PDF", _
                               PrintToFile:=True, collate:=True, PrToFileName:=PSFileName
                ' Convert the postscript file to .pdf
                Dim myPDF As PdfDistiller
                Set myPDF = New PdfDistiller     
                myPDF.FileToPDF PSFileName, "", ""
    BUT, I need to set the password on this PDF file and do not see an option to do so.
    Can you provide a solution for this situation? Appreciate your response in advance.
    Thanks.

    There is no way to set password programmatically using any other dll or any other kit?
    I am creating a bunch of PDF files for users programmatically but then they have to go in and set password themselves? This is very inconvenient for users.

  • Copying Graphs and Pie Charts generated in Analysis View to Email item using Excel VBA Macro Code

    Hi
    I am currently working on an exce VBA macro code that would help me take snapshots of the Graphs and Pie charts generated in QC for a particular application and copy the same to an email item using excel VBA macro code.
    I was able to write the code to create an email item. But I have no clue of how i can take snapshot of the graphs in Analysis View using excel VBA
    Any help would be highly appreciated.
    Thanks in Advance
    Regards
    Amit

    useramit,
    You are in the consumer end products forum.  You will also want to ask your question over at the Enterprise Business Community.
    Click the plus sign (+) next to Discussion Boards to drop down all the options for servers, networking and any other professionally related problems.
    http://h30499.www3.hp.com/

  • How to read ssas cube and role from Excel vba

    Hi,
    I want to read all roles and cubes in SSAS Db from Excel Vba.
    1. First i want to read all the roles which was assigned to me
    2. based on the role, i have to read all cube name
    Please help me to
    accomplish this task.

    Hi Jack,
    In Analysis Services, Each role contains members, by Windows username or by Windows group, and permissions (read, process, administrator). If the user has the permission to access SSAS database, then the account was contained in one or more roles. When connect
    to SSAS database, we need to use an account to log on it, and SSAS will list all the cubes' name based on the role automatically.
    Reference
    Using Excel to interact with a SSAS cube
    Regards,
    Charlie Liao
    TechNet Community Support

  • Starting Edata From a VBA Macro

    I am using the
    Application.Run "MNU_eDATA_SELECTPACKAGE", "GL_Data_Extract", "System Files/GL_Data_Extract.dtsx", "Company", "Data Management"
    It works fine as long as you start edata first.  Is there a way that I can start edata from a VBA macro.  That way the user does not have to sign into BPC and hit edata before running the macro.
    Please let me know if there is a VBA command that will do this?
    Thanks
    Phil

    As I understand the issue you are trying to use MNU_eDATA_SELECTPACKAGE in a VBA macro.
    As stated here and elsewhere -- that is not possible but I have a workaround that seems to work OK.
    In our case we are trying to use a Button to both send the data and then kickoff a DataManager macro.
    So the macro we assigned to the button is as follows:
    Sub SendandStartPackage()
        Application.Run ("MNU_eSUBMIT_REFSCHEDULE_BOOK_CLEARANDREFRESH")
        Range("J61").Select
    End Sub
    Then in cell J61 we put the EVMNU as follows:
    =EVMNU("MNU_eDATA_SELECTPACKAGE","run DM","Import MasterData,/CPMB/IMPORT_MASTER,Company,Data Management")
    Now when we click the button, the first macro runs and then the cell J61 is selected which starts the second macro.
    I have not tested this extensively but it worked when I tried it.
    Note: This is NW version syntax.

  • Doing telnet from excel VBA?

    Is it possible to do 'telnet' from excel VBA? The code should get host name/server ip , then username and password from the user. After, it will telnet to the server by providing the username and password...
    It should execute some commands in the server too...
    Any help appreciable

    Hi,
    For coding issue, you can ask the question in the Excel for Developers forum:
    http://social.msdn.microsoft.com/Forums/en/exceldev/threads
    Best Regards,
    Sally Tang

  • Need to checkout MS Project file from Excel VBA

    I have a VBA Excel macro that can open an MS Project file, and extract data.  It works fine when the MS Project file is on my hard drive or other location where no check out is required.  But often the MPP files I need to access are stored in SharePoint,
    in document libraries, that have checkin/checkout enabled.  I am aware of the the way to do this for an Excel file, such as the following code snippet.
     ' Determine if workbook can be checked out.
     If Workbooks.CanCheckOut(Filename:=docCheckOut) = True Then
      Workbooks.CheckOut (Filename:=docCheckOut)
     Else
      MsgBox "You are unable to check out this document at this time."
     End If
    I need to be able to do the same thing for MPP files.  Here is the code I have; however, I get a compile error on the CheckOut line, indicating "wrong number of arguments or invalid property assignment".  My research suggests that I should
    get this compile error, as it only works on certain collections.  Even the line containing "CanCheckOut", while it does not give me a compile or run time error, it does not return the proper response.
     Dim mpApp As MSProject.Application
     Set mpApp = New MSProject.Application
     AppActivate "Project Professional"
     ' Determine if mpp file can be checked out.     
     If mpApp.CanCheckOut(mppFileToOpen) = True Then
      mpApp.CheckOut (mppFileToOpen)
         Else
             MsgBox "Unable to check out this document at this time."
        End If
    Is there a way to checkout an MS Project file stored in SharePoint from within Excel VBA?  Thanks.
    Ray

    Rod,
    Thanks very much.  This was, indeed, the solution.  Don't know how I could have missed this.  
    I did run into some issues with ensuring proper object references, checking back in, and being able to handle files that may be on a laptop, SharePoint site with checkout requirements, or SharePoint site without checkout requirements.  Also faced an
    issue checking back in; part of my macro opens the MPP file (that is checked out), acquires various pieces of data, then runs a macro in the MPP file that exports data to an excel spreadsheet.  After this macro runs (does a save-as using a map), check
    in is no longer possible.  Fortunately, I could checkout the MPP file, open it, get all the required data elements, make a few changes to the MPP file, check it back in (but not close), then run the macro, then close without saving.  In the end,
    it all works like a champ.  Thanks very  much for your advice.
    Ray

  • Calling UDF (MS Access) from Excel VBA

    Hi,
    I need to run a query on an MS Access database that has to perform a weekday calculation between two date columns,
    and this query has two date parameters that it receives dynamically. I am using Excel VBA as the front end.
    Select AgeRange, count(*) from
    (Select IIF(networkdays(date1,date())<=2, "0-2 days","over 2 days")) as AgeRange
    from table1
    where date2 >= startdt
    and date2 <=enddt
    ) d
    group by AgeRange
    The actual query is more complex, but this will help illustrate the issue. I build a string variable with
    the query, and substitute Startdt and enddt variables with the actual values. I then create a new QueryDef object and get the results from OpenRecordSet.
    Except, Networkdays is not a valid function in MS Access. So, this query fails.
    I created a WorkDays UDF in MS Access, and used that instead - the query works fine in MS Access, but when
    I try to pass it in the QueryDef object, it fails with 3085 error (function not available).
    I'm not sure how to get around this, and could use some help.
    In summary, I need to run a select query that will calculate weekdays or workdays between two columns (query
    is dynamic - dates are variable) from VBA to MS Access, get the results back to VBA so that I can populate the results. Any suggestions are appreciated and welcome.
    Thanks!
    I tried using datediff with the "w" parameter, but that doesn't work as I had hoped - it gives the
    number of weeks between the dates instead of weekdays
    I realize that I could get all the data (without doing the group by) down into Excel and then, do the networkdays
    formula calculation there, and summarize after that, but that is a very inefficient way - and defeats the purpose of having an access database in the first place. Getting tens of thousands of records is going to cause space issues in Excel too.

    Hi Bob,
    One solution is to create a table in the Access database storing all the dates in these years, add a column to determine if this date is a week day or not. And create another table to store the dates that are to be excluded from the working days.
    In this way, you need to create a separate query to count the valid working days based on the two tables. So the most difficult thing is to create the table that contains all the dates, please check this VBA code snippet which helps you to insert all the
    dates into the table.
    Sub InsertDatesIntoTable()
    Dim StartDate As Date
    Dim EndDate As Date
    Dim d As Date
    Dim w As Integer
    Dim IsWorkDay As Boolean
    StartDate = #1/1/2015#
    EndDate = #12/31/2015#
    For d = StartDate To EndDate
    Debug.Print d
    w = Weekday(d, vbSunday) 'first day of the week is Sunday
    If w = 1 Or w = 7 Then ' if the current day is Sunday or Satuday
    IsWorkDay = False
    Else
    IsWorkDay = True
    End If
    'Here you can insert d and IsWorkDay into the table
    Next d
    End Sub
    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.

  • Running BEX7 workbook repeatedly from excel vba

    On a monthly basis I have about 300 reports to run,all from the same bex7 workbook,  just with slightly different variables.
    I was able to setup a macro in bex 3.5 that would refresh a report and fill in values into the SAPBEXqueries hidden sheet.  This would adjust each time and save each report with an individual name.  Saved me about 3 hrs of sitting and running each report manually.
    My company is now upgrading to BEX7 and I am having difficulty getting my head around how to run the same workbook in BEX7 through a VBA Macro and pass the variables to it.
    I understand you can use SAPBEXsetVariables to pass variables along to the workbook but what format do the variables have to be in to communicate successfully with the workbook
    Would someone have an example of the process?
    I do not have access to modify the query at all as I am an end user and I am forced to come up with a solution on my own.
    Any help would be appreciated.
    Thank you
    Dan Gerling

    Hi Dan, in the same situation I'm afraid. Just posted this in a similar thread:
    "Hi Alfredough, I'm afraid I'm in pretty much the same situation as yourself (although possibly slightly further down the line). The reason I add that possibility is because I'm pretty certain that SAPBEXsetVariables has been removed in 7.x.
    It looks like there are some cludges which can be done to work through this (possibly), but the entire comparison of bexanalyzer.xla to sapbex.xla seems to involve features being removed, rather than added.
    Here's the thread which seems to give a cludge, which I'm having trouble getting working: How to set variables values via VBA.
    There's also some work which someone's done here around script objects: List BEx Analyzer 7.X variables and generate the associated PROCESS_VARIABLES commands

  • Using AppleScript to Launch Excel VBA Macro

    Using MS Office 2004 and AppleScript 1.9.3. I want to use AppleScript in MS Entourage to kick off a VBA macro in Excel. But no luck.
    To test things, I created an Excel file ("test.xls") with a one-line VBA macro named "test." It just puts up a dialog box with the message "success." I'm calling it from A.S as follows (per the AppleScript Dictionary for Excel 2004):
    tell application "Microsoft Excel"
    run VB macro "hard disk:users:xxx:desktop:test.xls!test"
    end tell
    I get two successive error messages:
    1. 'test.xls' cannot be accessed. The file may be read-only or you may be trying to access a read-only location."
    2. "Microsoft Excel got an error: "hard disk:users:xxx:desktop:test.xls!test" doesn't understand the run VB macro message."
    "test" file permissions are -rw-r--r-- and it is sitting right on the desktop.
    FWIW, I did not remove the old Office vX yet, but renamed old Excel "Microsoft ExcelOld". I read on some other site that this may cause problems.
    This has been endlessly frustrating. HELP!!??
    Steve

    Hi Steve,
    Have you tried dealing with the return value from your macro? If you are invoking the MsgBox function in your test macro, you may need to allow the return value from MsgBox to pass thru back to AS. Something like :
    set MyRetCode to run VB macro "Macintosh HD:Users:xxx:Desktop:test.xls!test"
    (Note unless you've changed the hard drive name to "hard drive", the default boot drive name will probably be "Macintosh HD". Case does matter here)
    I also suspect you'll need to have Entourage up as well in the full case of running a macro in Entourage from Excel (or the other way around). Hence, the command ActivateMicrosoftApp in the Excel dictionary may also be useful.
    Second, you can have a macro, in a startup template, in Entourage call a macro in a startup template in Excel to accomplish what you want without going into AppleScript at all. This latter, VB-only, method will require a "Reference", as it's called in VBA, to be added to the TemplateProject in Entourage that points to the Excel macro you want to fire off. The added benefit of this latter method is that you will have access to the full range of VBA commands/options, rather than the smaller dictionary available in AS.
    Ed
    PB G4   Mac OS X (10.2.x)  

  • Download Data From Excel - VBA Code to SAP Using BDC

    Hi ,
    I am Sudhir Dure, working with Satyam Computers.
    I need help on the below query:
    I have an excel file which download data from Excel to SAP using RFC function & with the help of VBA interface.
    In this VBA code I have used BDC recording of SAP Transaction KE21N to post data into SAP.
    Now I am facing problem to find sub screen (tab page screen ) in SAP from VBA code .
    How to pass BDC Subscreen details from VBA code to SAP using below code?
    BDCTABLE.Rows.Add
    BDCTABLE.Cell(J, "PROGRAM") = PROGRAMNAME
    BDCTABLE.Cell(J, "DYNPRO") = "0200"
    BDCTABLE.Cell(J, "DYNBEGIN") = "X"
    BDCTABLE.Cell(J, "FNAM") = "BDC_OKCODE"
    BDCTABLE.Cell(J, "FVAL") = "=NEXT"
    Thanks,
    Sudhir Dure
    9972097464

    can anyone tell me how to get the PurchaseOrder number and item quantity from the Salesorder...? what are the fields here as given below..??
    For Each oItem In oSalesOrder.items
    wsTemplate.Range(cols(3) & Indexv).Value = oItem.material.material
    'wsTemplate.Range(cols(4) & Indexv).Value = ' I need item quantity here ????
    wsTemplate.Range(cols(1) & Indexv).Value = sapSoNumber
    wsTemplate.Range(cols(2) & Indexv).Value = ' I need purchase order number here>???
    Indexv = (Indexv + 1)
    Next
    reply fast. please .. thanks

  • Send SMS from excel (VBA)

    I need help to find a solution that always works to my current problem:
    Using Excel 2007 VBA I need to send a similar text message to say 50-100 people using Nokia PC suite. Has anyone found a way of doing this?
    I have found a way of opening and then initially controlling PC Suite in VBA by using sendkeys, however it always falls over at some point as it loops through all the staff.
    Scenario is simple - I have built a rota for where I work. Each employee receives an email with their rota in it for the coming week; I also want to send a short text message to each employee telling them that their rota is in their email inbox and details of their next shift.
    So, the VBA code loops through each staff member, customises the text message contents but always falls over for no apparent  part way through the loop. I have succeeded in getting it to work for 5 people, but it falls over when it gets into double figures.
    I could get it to send bundles of 5 but there must be an easier way; someone must have tried doing what i'm doing and succeded!
    Thanks

    Hi,
    I would like to know the way in which I can achieve the above. i.e. Send SMS from Excel. even 2-5 sms will work for me..
    Thanks...

Maybe you are looking for

  • Communication problem MYSQL PHP XML Flash.

    I have driven myself into a corner with this so I hope someone here knows a solution. I am building a photogallery with a simple html layout but with a flash slideshow. The data for each album and photo are stored in a mysql database. Each photo-imag

  • How can I get rid of a virus

    I have a virus and it won't allow me to use mouse, keyboard or wifi

  • Show data labels vertically

    Is there a way to show the data labels of a column chart vertically?

  • Spot healing brush alignment problem

    Using Photoshop CS4 (11.0) on a Mac with 10.5.6. Sometimes the spot healing brush works as expected. However, after working for a while, the alignment seems to be off--I hover the cursor over the spot I want to retouch, but when I click the mouse the

  • OS X Hangs 3 times in a row

    Hi, I started having this problem yesterday. Basically OS X hangs "windows style". It means that the cursor stops responding, everything freezes... keyboard does nothing... trackpad does nothing.. mouse does nothing. Have to hold the power button dow