I need to write a vbscript script to retrieve the size of an access database

Could someone help me write a vbscript script to retrieve the size of an access database. I need to put this in my schedular system to run every morning.

Hi Rob,

Your question is more complex than what is generally answered in the Microsoft Answers forums. It is better suited for the IT Pro TechNet public. Please post your question in the Office IT Pro. You can follow the link to your question:

http://social.technet.Microsoft.com/forums/en-us/officeitpro/threads

Tags: Windows

Similar Questions

  • How can I run a VBScript script of in the handler script in Photoshop CS5?

    I need to run a VBScript script on each file that is opened in Photoshop. The script event handler allows only to JS. There is no work around for this?

    Thanks for any help.

    You write a little JavaScript to call VB script.

    var myVBscript = File ("pathToYourScript/vbscript.vbs");

    myVBscript.execute ();

  • Can write us "PowerCLI Script" to get the details of card RAID HP (Firmware & Driver)?

    Can write us "PowerCLI Script" to get the details of card RAID HP (Firmware & Driver)

    For example: native ESX command below shows desired output for me.

    But we needed equality PowerCLI ESX command below script

    # cat/proc/driver/cciss/cciss0

    cciss0: HP Smart Array P400i controller

    Board ID: 0x3235103c

    Firmware version: 7.22# cat/proc/driver/hpsa/hpsa0

    hpsa0: HP Smart Array P410i controller

    Board ID: 0x3245103c

    Firmware version: 5,70

    Driver version: HP HPSA driver (v 5.0.0 - 17vmw)

    The extracted following PowerCLI you will get server and type of controller, firmware version and the hpsa/Smart Storage Array controllers driver version based of:

    Get-VMhost | Sort | Select Name, Model,@{N='Controller Type'; E={(Get-VMHostHba -VMHost $_ | ? {$_.Model -imatch '.*(hpsa|smart).*'}).Model}},@{N='Controller Firmware'; E={($_.ExtensionData.Runtime.HealthSystemRuntime.SystemHealthInfo.NumericSensorInfo | ? {$_.Name -like '*hpsa*firmware*'}).Name}},@{N='hpsa Driver Version'; E={($_.ExtensionData.Runtime.HealthSystemRuntime.SystemHealthInfo.NumericSensorInfo | ? {$_.Name -like '*scsi-hpsa*'}).Name}} | Format-Table -Autosize
    

    The sample output:

    
    Name                     Model                Controller Type   Controller Firmware                           hpsa Driver Version----                     -----                ---------------   -------------------                           -------------------esxihost1022.local    ProLiant DL380 G6    Smart Array P410i    HP Smart Array Controller HPSA1 Firmware 6.40    Hewlett-Packard scsi-hpsa 5.0.0.60-1OEM.500.0.0.472560 2014-05-15 15:32:23.000esxihost1023.local    ProLiant DL380 G6    Smart Array P410i    HP Smart Array Controller HPSA1 Firmware 6.40    Hewlett-Packard scsi-hpsa 5.0.0.60-1OEM.500.0.0.472560 2014-05-15 15:32:23.000esxihost1024.local    ProLiant DL380 G6    Smart Array P410i    HP Smart Array Controller HPSA1 Firmware 6.40    Hewlett-Packard scsi-hpsa 5.0.0.60-1OEM.500.0.0.472560 2014-05-15 15:32:23.000esxihost1033.local    ProLiant DL360p Gen8    Smart Array P420i    HP Smart Array Controller HPSA1 Firmware 5.42    Hewlett-Packard scsi-hpsa 5.0.0.60-1OEM.500.0.0.472560 2014-05-15 15:32:23.000esxihost1034.local    ProLiant DL360p Gen8    Smart Array P420i    HP Smart Array Controller HPSA1 Firmware 5.42    Hewlett-Packard scsi-hpsa 5.0.0.60-1OEM.500.0.0.472560 2014-05-15 15:32:23.000esxihost1041.local    ProLiant DL380 G5    Smart Array P400    HP Smart Array Controller HPSA1 Firmware 7.24    VMware scsi-hpsa 5.0.0-17vmw.500.0.0.469512 2011-08-19 01:58:59.000esxihost1042.local    ProLiant DL380 G5    Smart Array P400    HP Smart Array Controller HPSA1 Firmware 7.24    VMware scsi-hpsa 5.0.0-17vmw.500.0.0.469512 2011-08-19 01:58:59.000esxihost1160.local    ProLiant BL460c Gen8    Smart Array P220i    HP Smart Array Controller HPSA1 Firmware 5.22    Hewlett-Packard scsi-hpsa 5.0.0-40OEM.500.0.0.472560 2012-08-24 21:04:51.000esxihost1161.local    ProLiant BL460c Gen8    Smart Array P220i    HP Smart Array Controller HPSA1 Firmware 5.22    Hewlett-Packard scsi-hpsa 5.0.0-40OEM.500.0.0.472560 2012-08-24 21:04:51.000
    
  • Please share the Script to retrieve the name of host, HBA, HBAstatus, WWN, pathpolicy and dualpathinfo

    Please share the Script to retrieve the name of host, HBA, HBAstatus, WWN, pathpolicy and dualpathinfo

    Take a look on Re: information on the host hardware with information about the HBA drivers and nic

  • Is it possible to use the batch is script to retrieve the value window server political group?

    Y at - it a batch command that will allow me to recover the value of group policy in Windows server? Something like gpedit.msc did, but I want because of the command line I want to convert this value to format I want.

    Example: If I open gpedit.msc, then I go to Computer Configuration\Windows Settings\Security Settings\Local Policies\User Rights Assignment\Restore files and directories so I can get the value (administrators, backup operators) of this policy.

    All ways in the batch script can bring me to this path and capture value?

    Thanks, your help is very appreciated.

    Hello

    You could try to look at the list of Group Policy scripts or repost the question to the Scripting Guys or in Forum Windows Server forum.

    The guys from script

    Windows Server

  • Script to display the size of InDesign pages instead of the size of the Document format

    Hello, I have been very kindly helped with the script (using a text variable), which displays the size of the current page within an InDesign document below.

    The result gives it is based on Document format, and I was wondering if it was possible to amend it to base the result on the size of the Page instead (as you can now change the size of the page regardless of the configuration Document in InDesign using the Page tool). I don't know anything about the scripts by the way!

    Thank you very much in advance for any help.

    var doc = app.activeDocument;

    doc.viewPreferences.horizontalMeasurementUnits = MeasurementUnits.millimeters;

    doc.viewPreferences.verticalMeasurementUnits = MeasurementUnits.millimeters;

    var l = doc.documentPreferences.pageWidth,

    h = doc.documentPreferences.pageHeight,

    PageSize = app.activeDocument.textVariables.itemByName ("PageSize");

    pagesize.variableOptions.contents = h + w + "X mm", "mm";

    Try this,

    var doc = app.activeDocument;
    doc.viewPreferences.horizontalMeasurementUnits = MeasurementUnits.millimeters;
    doc.viewPreferences.verticalMeasurementUnits = MeasurementUnits.millimeters;
    for(var i =0;i
    

    Kind regards

    Cognet

  • The use of Scripts to detect the size of the document in inches?

    Is it possible that a script detects the size of the document in inches not in pixels?

    Thanks for the help!

    The size of an Image will print is a simple calculation the numbet of Pixel wide divided by the resolution in DPI imageg courses. And numbet of high Pixel divided by the resolution in DPI imageg courses. You can always change the DPI while maintaining the same number of pizels using checked DO NOT resample Image size to change the print size of the image. All information can be extracted in a script, and the script can change the print size of the image with or without resampling the image.

  • Need a little help. Script to export the single document for different types of files.

    Hey guys, I'm new to scripting. have looked everywhere but cannot find an answer to this, I'm sure it's pretty simple


    At work we export logos all the time in a few different formats for the clients.
    I looked in the script as a way to automate the process.

    So far, I thought a little script to export my Illustrator formats document... now I need to be able to export this document even outside as a res low and high PNG, low and high res JPEG, EPS, PDF and TIFF etc.
    I have scripts to do all these separately but just need to know how to put it all in a single script I can do all at once

    Here is an example of my two different scripts to export PNG. I just need to know how string together so I can add all of the formats without breaking it.

    function savePNG() {}
    var destFolder = Folder.selectDialog ("select the folder to export the PNG files to :');")
    If {(destFolder)
    If (app.documents.length > 0) {}
    var Nomdoc = app.activeDocument.name.match(/^.*[^.ai]/i);
    var destFile = new file (destFolder + ' /' + Nomdoc + "-HR.png");
    if(destFile == null) {return ;}
    var doc = app.activeDocument;
    var artRect = doc.artboards [0] .artboardRect;
    var exportOptions = new ImageCaptureOptions;
    exportOptions.resolution = 300;
    exportOptions.antiAliasing = true;
    exportOptions.transparency = true;
    doc.imageCapture (destFile, artRect, exportOptions);
    }
    }
    }
    savePNG();

    and here is the version low resolution

    function savePNG() {}
    var destFolder = Folder.selectDialog ("select the folder to export the PNG files to :');")
    If {(destFolder)
    If (app.documents.length > 0) {}
    var Nomdoc = app.activeDocument.name.match(/^.*[^.ai]/i);
    var destFile = new file (destFolder + ' /' + Nomdoc + "-LR.png");
    if(destFile == null) {return ;}
    var doc = app.activeDocument;
    var artRect = doc.artboards [0] .artboardRect;
    var exportOptions = new ImageCaptureOptions;
    exportOptions.resolution = 72;
    exportOptions.antiAliasing = true;
    exportOptions.transparency = true;
    doc.imageCapture (destFile, artRect, exportOptions);
    }
    }
    }
    savePNG();

    Thanks for any advice you can give!
    Eli

    Oh, you want to perform two functions, one after another at the same time? then just name with different names and perform one function after another, if all files will be saved in the same folder, the argument selectDialog move method on each of your functions to don't do only once.

    function savePNG_HR(){
        var destFolder = Folder.selectDialog('Select the folder to export the PNG files to:');
        if (destFolder) {
            if(app.documents.length > 0){
                var docName = app.activeDocument.name.match(/^.*[^.ai]/i);
                var destFile = new File(destFolder + '/' + docName + " - HR.png");
                if(destFile == null){return;}
                var doc = app.activeDocument;
                var artRect = doc.artboards[0].artboardRect;
                var exportOptions = new ImageCaptureOptions;
                exportOptions.resolution = 300;
                exportOptions.antiAliasing = true;
                exportOptions.transparency = true;
                doc.imageCapture(destFile, artRect, exportOptions);
            }
        }
    }
    
    function savePNG_LR(){
        var destFolder = Folder.selectDialog('Select the folder to export the PNG files to:');
        if (destFolder) {
            if(app.documents.length > 0){
                var docName = app.activeDocument.name.match(/^.*[^.ai]/i);
                var destFile = new File(destFolder + '/' + docName + " - LR.png");
                if(destFile == null){return;}
                var doc = app.activeDocument;
                var artRect = doc.artboards[0].artboardRect;
                var exportOptions = new ImageCaptureOptions;
                exportOptions.resolution = 72;
                exportOptions.antiAliasing = true;
                exportOptions.transparency = true;
                doc.imageCapture(destFile, artRect, exportOptions);
            }
        }
    }
    savePNG_HR();
    savePNG_LR();
    
  • Need help with changing PowerCLI script to get the interface driver NETWORK & firmware version?

    Hi all

    mattboren created the script below for a list of BIOS hardware version and firmware version:

    ## Script function: quickly get BIOS date, Smart Array FW version, and iLO FW version for HP hosts in a given location (folder, cluster, datacenter, etc.)
    ## Author: vNugglets.com -- Sep 2011
    
    ## folder in which hosts in which we are interested reside
    #$strHostsFolderName = "myFolder"
    #Get-View -ViewType HostSystem -Property Name, Runtime.HealthSystemRuntime.SystemHealthInfo.NumericSensorInfo -SearchRoot (Get-View -ViewType Folder -Property Name -Filter @{"Name" = "^$([RegEx]::escape($strHostsFolderName))$"}).MoRef | %{
    ## cluster in which hosts in which we are interested reside
    
    $strHostsClusterName = "Production"
    Get-View -ViewType HostSystem -Property Name, Runtime.HealthSystemRuntime.SystemHealthInfo.NumericSensorInfo -SearchRoot (Get-View -ViewType ClusterComputeResource -Property Name -Filter @{"Name" = "^$([RegEx]::escape($strHostsClusterName))$"}).MoRef | %{
        $arrNumericSensorInfo = @($_.Runtime.HealthSystemRuntime.SystemHealthInfo.NumericSensorInfo)
        # HostNumericSensorInfo for BIOS, iLO, array controller
        $nsiBIOS = $arrNumericSensorInfo | ? {$_.Name -like "*System BIOS*"}
        $nsiArrayCtrlr = $arrNumericSensorInfo | ? {$_.Name -like "HP Smart Array Controller*"}
        $nsiILO = $arrNumericSensorInfo | ? {$_.Name -like "Hewlett-Packard BMC Firmware*"}
        $nsiNXdev = $arrNumericSensorInfo | ? {$_.Name -like "nx_nic device*"}
        $nsiNXdrv = $arrNumericSensorInfo | ? {$_.Name -like "nx_nic driver*"}
    
      if ( $nsiNXdev.Count -gt 0 ) {
           $nsiNXdevice = $nsiNXdev[0].Name
      } else {
           $nsiNXdevice = "n/a"
      }
      if ( $nsiNXdrv.Count -gt 0 ) {
           $nsiNXdriver = $nsiNXdrv[0].Name
      } else {
           $nsiNXdriver = "n/a"
      }
    
        New-Object PSObject -Property @{
            VMHost = $_.Name
            "SystemBIOS" = $nsiBIOS.name
            "HPSmartArray" = $nsiArrayCtrlr.Name
            "iLOFirmware" = $nsiILO.Name
            "nx_nic device" = $nsiNXdevice
            "nx_nic driver" = $nsiNXdriver
        } ## end new-object
    } | Export-Csv C:\temp\Production-BLadeG7.csv  ## end Foreach-Object
    
    
    
    
    

    However, I would like to change the driver for the CARD and the version of the firmware but still appear.

    Any kind of help and suggestions would be greatly appreciated.

    Thank you.

    Try like this

    $strHostsClusterName = 'production '.

    Get-view ViewType - HostSystem-Property Name, Runtime.HealthSystemRuntime.SystemHealthInfo.NumericSensorInfo - SearchRoot (Get-View - Name ClusterComputeResource-property - ViewType filter @{'Name' = ' ^ $([RegEx]: escape ($strHostsClusterName)) $"" "}). MoRef | %{

    $arrNumericSensorInfo = @($_.) Runtime.HealthSystemRuntime.SystemHealthInfo.NumericSensorInfo)

    # HostNumericSensorInfo for controller table of BIOS, ILO,

    $nsiBIOS = $arrNumericSensorInfo |? {$_. {Name: like "* system BIOS *"}

    $nsiArrayCtrlr = $arrNumericSensorInfo |? {$_. {Name - like "HP Smart Array Controller *"}

    $nsiILO = $arrNumericSensorInfo |? {$_. {Name - like "Hewlett-Packard BMC Firmware *"}

    $esxName = $_. Name

    $esxcli = get-EsxCli - VMHost $_. Name

    $esxcli.network.nic.list () | %{

    $esxcli.network.nic.get ($_.) Name) | %{

    $props [ordered] = @ {}

    VMHost = $esxName

    "SystemBIOS" = $nsiBIOS.name

    "HPSmartArray" = $nsiArrayCtrlr.Name

    "iLOFirmware" = $nsiILO.Name

    "nx_nic device" = $_. Name

    'nx_nic pilot' = $_. DriverInfo.Driver

    "nx_nic driver version" = $_. DriverInfo.Version

    "nx_nic firmware version" = $_. DriverInfo.FirmwareVersion

    } # end new object

    New-object PSObject-property $props

    }

    }

    } | Export-Csv C:\temp\Production-BLadeG7.csv # end Foreach-Object

  • PS The Script to list the sizes (complete and used) of vmdk (slim type)

    Hello

    I'm looking for a way to list to each vmdk which are thin format, maximum and used size. In fact, I saw that we have information by the data store (VMware.Vim.VirtualMachineUsageOnDatastore, with other files as swap, cliché...), but I need by vmdk. Does anyone has an idea (it is possible)?

    Thank you

    See the to find the actual size of the VM disks post.

  • Call a jscript vbscript script and return a value

    Hello world

    I'm trying to simplify a tedious task: every day I have to fill in an InDesign document with 48 different numbers that go into 48 blocks of text. I would like to write a script to get these numbers (the temperatures that I get in an excel file) automatically and write them in the corresponding text blocks.

    So basically I use jscript to implement a document. So I want him to call a vbscript script (since only vbscript can retrieve an excel cell value) and have it return the value to the jscript in a variable.

    So far I managed to adapt a .vbs script that retrieves the number of the cell and the poster in a box:

    Option Explicit
    Dim objApp, objWbs, objWorkbook, objSheet

    Set objApp = New
    Set objWbs = objApp.WorkBooks
    objApp.Visible = False
    Set objWorkbook = objWbs.Open ("C:\Temperature")
    Set objSheet = objWorkbook.Sheets ("Sheet1")

    MsgBox objSheet.Range ("C5"). Value

    objWorkbook.Close False
    objWbs.Close
    objApp.Quit

    ObjSheet = Nothing set
    Set objWorkbook = Nothing
    Set objWbs = Nothing
    Set objApp = Nothing

    But it is only that. I always have trouble with:

    (1) the order doScript: How can I call the jscript vbscript script?

    (2) writes the value retrieved (or table) in a variable in vbscript script

    The rest is easy: in the jscript, write the table in the corresponding text blocks.

    Hope someone can help me. Thank you very much

    Maphio M.

    When you place an Excel file in InDesign, it becomes a table. From there on, it's a simple as myFrame.tables [0] .cells [x] .silence (myFrame being a reference to the image that you placed the Excel file in).

  • Can't find script engine "VBScript" script "FILE."

    I am developing an application compatible with Windows XP, but I have a problem.

    Whenever I try to run a VBScript script, I get the error

    "Impossible to find the"C:\DIRECTORY\file.vbs"script engine".

    I tried to re - install wsh on the PC, but it tells me that I already have the latest version and it won't do anything.

    What happens here?

    Is there a solution?

    Thank you

    -Fractured.Code

    This issue is beyond the scope of this site and must be placed on Technet or MSDN
  • Hello. I need help developing a PowerCli script that will show me the current configuration of the video Ram of each individual virtual machine on a host\cluster or a vcenter. Can you help me?

    I have a script that will allow me to change the configurations of VRAM, but I need a script that retrieves the configuration of all virtual machines VRAM in my infrastructure.
    I need to get out information to a csv file and run this report on a monthly basis... can you help me?

    Right now my environment is mixed. I have Windows XP virtual machines set to 4 MB, Windows 7 virtual computers set to 8 MB and a subset of sall of virtual machines set to automatic detection of settings.

    I need to be able to recover these settings in a CSV file in order to use this information for comparisons of trdouble-shot performance issues...

    Thank you.

    vram.JPG

    Try something like this

    Get - VM |

    Select Name,

    @{N = "OS"; E={$_. ExtensionData.Config.GuestFullName}},

    @{N = "VideoRamMB"; E = {}

    [math]: Round (($_.)) ExtensionData.Config.Hardware.Device |

    where {$_-is [VMware.Vim.VirtualMachineVideoCard]} |

    (Select VideoRamSizeInKB - ExpandProperty) / 1 Ko, 1).

    }} |

    Export-Csv vm - videoram.csv - NoTypeInformation - UseCulture

  • Need help to create a rule to monitor the "DSDeviceTotalLatency" under "VMWDatastore".

    Hello all, I am very new to vFoglight and tasked to create a rule to control the property 'DSDeviceTotalLatency' of type 'VMWDatastore' topology.  Looking at existing rules, I see that I need to write a mini script on the tab 'Conditions and Actions '.  The problem is that I do not know how to reference this property and the command to use to recover.  Thank you in advance.

    At, it is simple, can be as simple as:

    scope of the rule to the VMWDatastore type on the tab 1

    condition on tab 2:

    If (#totalLatency # 10 >) {return true;}

    return false

  • Basic conditional script based on the number of lines in a text layer?

    Just received help here to write a conditional script by using the font size of a text layer. Thank you all for this.

    The next hurdle is a conditional script using the number of lines in a text layer in the differential. Far as I can tell it not the layer details which specify the number of lines. Just '\r' for a return in the idTxt descriptor. Nothing seems to stand for a soft return as far as I can tell. I'll probably have to be able to count the lines with soft and hard returns.

    Any thoughts?

    I was playing around with this a bit and here is a small script to determine the number of rows. This is based on the self in the head, that I calculated to environ.108 times the size of the font.

    #target photoshop
    app.preferences.rulerUnits = Units.POINTS;
    var doc = activeDocument
    var tL = doc.activeLayer
    var h = tL.bounds[3]-tL.bounds[1]
    var per = ((h/5)-(tL.textItem.size))/tL.textItem.size
    var num = h/(tL.textItem.size *1.108)
    
    alert(Math.round( num))
    

Maybe you are looking for