Answer Questions
jdang Help with a formula
I need to write a formula for Excel that calculates the amount of fuel that is in a tank. Here is what it is for. We have cylinder tanks that lay horizontaly. Each month we put a dipstick into the tank to measure how many inches of fuel is left in the tank. I need a formula that will take that and calculate it into gallons. Here is the formula I have to work with. / -1 r - h \ V = L * | [ r^2 * cos (--------)] - [sqrt(2rh - h^2) * (r - h)] | \ r / Any Help is appreciated (BTW I am not the best at math so if possible an explination of this formula would be greatly appreciated) Ok I need help ...Show All
LalitSRana Updating text in a text box on an Excel Graph
I am automating a spreadsheet, designed by someone else, which has 18 graphs on a worksheet. Most of these graphs have a text box on them which indicates the week commencing that the graph refers to. The text box appears to be a shape object on the chart. I want to loop through each chart on the sheet, then loop through each shape on the chart, and change the text if the shape is a text box. Can anyone put me on the right track, I did try using the macro recorder to get me started but this code does not work in my VBA module. Then this should do it: Option Explicit Private Sub Workbook_Open() Dim ws As Worksheet, o As ChartObject, c As Chart, s As Shape Set ws = Me.Worksheets("Sheet1&qu ...Show All
Charltonn 1004 - Application-Defined or Object-Defined Error - Help
I have an Excel workbook with 8 Sheets on it. On Sheet6 there are a number of named ranges. One of the ranges is: BreakTotal and the range is defined as: AuxTimesConv!$F$5:$F$100 where AuxTimeConv is the sheet name. On Sheet1 (Named: Formatting) there is a command button. Private Sub CommandButton1_Click() On Error GoTo 10 'Lets start with the Breaks Dim c As Range, r As Range Dim x As Integer Dim a As String Dim n As String x = 1 Set r = Range("BreakTotal") For Each c In r If c.Value = 0 Then Else a = c.Value n = Worksheets(Sheet6).Range("A" & c.Row) MsgBox n End If Next c 10 MsgBox Err.Description & Chr$(13) & Err.Source, ...Show All
Pisces Attaching Contents of a Folder
Hi all, Using a macro running on excel, I am trying to attach the contents of a folder in Outlook. The files contained in the folder change, so it is not as simple as writing the code to attach a specific file. I need it to attach all the files regardless of the file name. Is this possible Thanks in advance Hey Andy, When I tried to run your code I got this error message, " The specified module could not be found ". How do I fix it Best Regards Cathrine Hi, Yes it's possible. To include a reference to the Outlook library use the menu, within VBE, Tools > References... Browse for Microsoft Outlook ...Show All
Sudhakar.hcitek Backup and Restore Data/Metadata for a Novel Backend.
Hi, We have an application that behaves exactly like the NtBackup.exe and does some extra functionality based on our product. This has been working fine for almost all fileservers including EMC and NetAPP that support CIFS and windows based AD. We have a beta deployment in progress with a customer who has a Novel File Server and a Novel based AD. When we run our application to backup a Novel share from a windows client we observed that we could not backup the security stream. On further investigation we observed that even NTBackup cannot backup the security stream from a Novel Backend. We identified that tbackup.exe can be used to backup information from a Novel Backend but cannot restore security information on a windows backen ...Show All
DPotages Shift-Key bypass
Hi. I cant remember the way to bypass the possibility to open the database-window with the shift-key in Access-VBA. http://support.microsoft.com/kb/826765/en-us ...Show All
chazparks Access Doesn't Close after ActiveX is inserted
I've created an ActiveX control to be inserted in an Acces Form. This Control uses data from the database (file.mdb) where it is inserted and from other .mdb files more. Everything works well except that when I try to close the application the database is closed but a empty Access Widow stays opened (and it is not possible to close except using the TaskManager). Does anybody knows why it is happening and how to solve it If it could help...I think that the problem came from the use of DAO objects. The ActiveX control uses the object Workspace (workspaces(0)) and Database (CurrentDb) given by the access aplication, more objects Databases (in the same workspace) and recordsets to access the other .mdb files. The Access aplication us ...Show All
Subhosh Ajax in CRM
Hi, i have a problem in CRM. I have a custom field named "new_number" and this field is disabled in form Order. I want to fill this field with autonumbering system which it must working with CRM Web Services, so i make a code that will return the new_number data into the field new_number in CRM Order form. To do that, i think i must working with AJAX (for example if the last record of new_number is A0001, then ajax will return A0002), where i can write my ajax code in Order Form Properties (onSave function at Save button). This is my AJAX code : function OnSave() { var xmlHttp = null; if (window.XMLHttpRequest) xmlHttp = new XMLHttpRequest(); else if (window.ActiveXObject) xmlHttp = new ActiveXObject("Microsoft.XMLHTTP&quo ...Show All
GarrettM Text wraping on edit box of dialogsheet
I have created a form with an editbox and what I need to do is to make the text content wrap rather than continuing on to the right past the size of the box. Any ideas welcome please. With DialogSheets("FormAdd") .EditBoxes("Edit Box 144").Text = "" .Show End With Interesting, just turning the MultiLine on (and not using the code you supplied) makes the text wrap as I want. The height of the box is more than sufficient but it seems to limit content to what's probably 256 characters (didn't count them). Is there a simple way to extend this to allow more characters to be entered How would this be reflected on my original code for loading the f ...Show All
Marasma If a cell has value add a formula to neighbouring cell
I am trying to write a spreadsheet that would allow a user to enter a value say in A2 of a new row. if the value in A2 exists (i.e., an event has taken place in A2--it changed) then I want a formula set in B2 that uses A2. If A2 is blank, no formula will exist in B2 and the whole row remains blank. I can easily do this with a macro that would fill down the formula in B1 to the last row of data, but I do not want the user to have to run a macro every time they start a new line. Is there a way to kick off a macro by virtue that the A2 cell changed or lost focus--user hit enter or moused to another cell, etc. Thanks. here is someVBA pseudo code that will get ya going down the right path ...Show All
SanthaMind Adding a date from a specific cell into the DateAdd function
Hi Been trying to implement this piece of code into my program and can't seem to get the following bit to work: Range(eeDispatchDate) = DateAdd("yyyy", 5, " ") & Range(SenorityDate).Value I basically want the date as from the senority date cell to be input to the function so i can add 5 years to it. I haven't changed the rest yet but will once i get this working. here is the full code below: Sub cmdEMP_email_Dispatch_date_Click() Dim AwardDue, eeDispatchDate, SenorityDate As String Dim x, z As Integer For x = 2 To Module1.GlobalCount AwardDue = "G" & x 'where G is Award due i.e. 5 yrs SenorityDate = "J" & x 'where J is Senority Date eeDispatchDate = "L&qu ...Show All
Senkwe Chanda Newbie in VBA Drag and Drop..
Hi, Do not know if this is possible drag and drop effect of items in dropdown control inside a word application The task is to import and export data from and to database, but user can select from a list columns what they want to add, there will be a dialog will appear and allow user to select data to be included in a word document, how can this be done Thanks in advanced. den2005 Hi Derek, Ideally, there would be a web application where 1. you would export the data with word document and vice-versa, I am mentioning one of functions, and 2. when the user opens this word document, there is a dialog window would appear where user can drag and drop an item in t ...Show All
Michael Barrett Object Browser
I find the object browser very useful for finding out what objects are available to me. However, it would be more useful if I new what the small symbols or icons denote just to the left of each object/class (e.g. an easy one to describe would be a hand holding what looks like a card and another a green object with what looks like motion lines coming off of it). Would anyone who knows what I am referring to be able to list what they mean Cheers! No worries Keithyboy, The grey square with the red, green and yellow blocks on it is a class. (i.e. Application) The green moving thing represents a method of the class (i.e. Application.SetDefaultChart()) The finger pointing represents a property o ...Show All
Kate Boothby HTTP request - simple problem
I have a small server application (PHP) that is envoked with a URL and writes the attached parameters to a file. I want a client application to do the HTTP work. How do I call an URL from VBA without launcing a browser The URL (requested by a client application, not a browser) looks like http://www.test.com/fileWrite.php var1=234&var2=26&var3=4 Hi Derek, Thanks, that did it! Kristjan Hi, You can use MSXML's XMLHTTP object to make requests. Here's an example: Private Sub Command1_Click() Dim HttpReq As New MSXML2 .XMLHTTP40 HttpReq.open "GET", "http://XMLSampleServer/CatalogServer.asp", False HttpReq.send MsgBox HttpReq ...Show All
Speedie Userform Controls
I have created a data request form for the company in Excel. The form has quite a lot going on (e.g. frames, option buttons, tick boxes etc). I've created all the necessary code and event handlers so that the form behaves as it should. In an attempt to record the user's input, I've then gone on and written a bit of code, which executes when the user clicks OK after completing the form. This bit of code loops through each control on the form and, depending on the control type, writes its caption or value to a blank spreadsheet. The issue I'm having is the order in which it loops through the controls. The tab order for the whole form, including that within frames, is spot on, yet this bit of code loops through some of the controls in ...Show All
