Finding Angle with respect to X axis in VB?

In my VB program, I used the FindStraightEdge function to get a line for a particular edge. I would like to know what is the angle with respect to X axis. In the Measurement Studio, I use the "Caliper" to find this angle; however, in VB the Caliper function doesn't seems to have an option of measuring angle. Am I missing something here???
I found the "FindAngleBetweenLines" function. Is this the only method to measure angle?
Thanks,
Simon Teng

Simon,
Probably the easiest way to do it is to create a variable that contains a line going from 0,0 to 1,0 and use the "FindAngleBetweenLines".
Another way is to use the endpoints of the line to calculate its angle relative to horizontal. You can use atan(dy/dx).
Bruce
Bruce Ammons
Ammons Engineering

Similar Messages

  • Interval in y axis displays numbers off with respect to x axis

    I am working on chart SQL 2008 R2. In my x-axis, I have three payers and in y axis I have Amount paid by each payer. If I define interval in y axis then x axis graph is not showing correct values. If I remove the interval in Y axis then my x-axis graph is
    correct but y axis numbers are wrong(see graph1). 
    Please see Graph2 where I have correct interval. Payer 1 has paid 29,000,000 and payer2 has paid 3,843,537 and payer3 has paid 270,000,000. I have set the interval min - auto. max - max ( of data value) and interval - 10,000,000 on y axis.
    x-axis is category. Please help me with this. Is there any property I need to set. Thanks for your help.
    Graph1

    Hi Rachel_P,
    According to the pictures, the Y-Axis shows incorrect values when you don’t specify the interval value. While when you specify the interval value, the columns in the chart doesn’t show correctly. Based on my research, I think this issue can be caused by
    incorrect data type of the Amount field. When we add a string type field to the Values pane, it uses [Count(Amount)] as the values. Then the Y-Axis displays the number of amount values for each payer.
    To fix this issue, we can add a calculated field with integer type amount values in the dataset, then display the new field in the Y-Axis. For more details, please see the following steps:
    Right-click the DataSet of the chart to add a calculated field as below:
    Field Name: Num                   Field Source: =CInt(Fields!Amount.Value)
    Insert Num field to replace the Amount field in the Values pane.
    The following screenshot is for your reference:
    If there are any misunderstanding, please elaborate the issue for further investigation.
    Thanks,
    Katherine Xiong
    Katherine Xiong
    TechNet Community Support

  • Find Reference with gearing Error 70166

    Hello,
    I have an xy-Table with 2 linear motors per axis. The motors of one axis are fixed together. An axis is configured with gearing (X: master: axis1, slave: axis2; Y: master: axis3, slave: axis4;). Vector Space 1 are the master motors. With the settings I can move the axis with MAX. X and Y has respectively a limit switch that is connected to the ForwardLimit Switch of the master.
    After Initialise and Configure Vector SpacesI wanted to execute the example "simultaneous Two-Axis Finnd Reference.vi". The Input Parameter are: Board ID: 1, First Reference Move: Forward Limit, Timeout: 4294967295.
    When started the axis (X, Y) move forward then jumps. Seems to be that the slaves HALT and the master move forward until the position error is reached. Then I get for axis 1 and 3 (masters) the Error 70166.
    Whats wrong.
    Best Regards,
    Andy
    PCI-7356@UMI7764; PCIe-6320@SCB-68; LV2011; Motion Assistant 2.7; NI Motion 8.3; DAQmx 9.4; Win7

    Hey,
    I updated the Motion driver to 8.5.1 with no result.
    I removed the mechanical joints between the master and slave axis. I changed the "Load Velocity" in the example "Master Axis - Slave Axis Gearing.vi" (attachement) to move one axis. To use the vi I executed the "Initialisierung 3D Gearing.vi" before, wich is the initialise VI for the program I develope. So some VIs were executed twice. The initialise VI I executed with the shown parameters (attachement). In MAX the gearing for master axis is disabled, for slave axis is enabled, relative, 1/1 to axis1 respectively 3. This setting are set in the programs too, so they will be overwritten.
    The "Master Axis - Slave Axis Gearing.vi" runs perfectly.
    To execute the "Simultaneous Two-Axis Find Reference.vi" example I run the "Initialisierung 3D Gearing.vi" before too. Because of the initialisaton all four motors are enabled. By finding the references only the master axis were moved until the switches were enabled. Then all motors HALT, but the "Wait Reference.vi" is not executed completely. This is reproducible. forward limit switches from Master are always enabled. I tried the situation with enable/disable forward limit switches for slave axis. Both with the same result.
    I think the HALT slave motors generated in mechanically fixed situation the error 70166. But why they HALT? Why the  "Wait Reference.vi" is not executed completely?
    To the Situation:
    LV2011
    NI Motion 8.5.1
    PCI-7356@2xUMI7764
    LinMot B1100-VF for every motor with  analog current command (http://www.linmot.com/fileadmin/doc/Manuals/E1100/​QuickStartGuide_B1100-VF_e_recent.pdf)
    The digital signals (5V@PCI-7350 <--> 24V@B1100-VF)were fitted with a self made amplifier board.
    Four linearmotors LinMot: stator: PS01-37x240-C; coil: PL01-20x365/220
    The Limit switches give 0V or 5V to Forward Limit Switches of master axis (axis 1 and 3). The voltage source is the UMI-7764@PULS ML-15.
    I will send the pictures of XY-table in next post.
    If you need some more information, I can post it.
    Best Regards,
    Andy
    PCI-7356@UMI7764; PCIe-6320@SCB-68; LV2011; Motion Assistant 2.7; NI Motion 8.3; DAQmx 9.4; Win7
    Attachments:
    Master_Axis_-_Slave_Axis_Gearingd.png ‏20 KB
    Initialisierung_3D_Gearingp.png ‏15 KB
    Initialisierung_3D_Gearingd.png ‏18 KB

  • How do you integrate a column with respect to another column

    I have two columns of data, one is time and the other is velocity. I want to be able to integrate velocity with respect to time, but I can not find a function which will let me do this. Preferably, I'd like to do a cumulative trapezoidal integration, such as the one in Matlab. The function "cumtrapz" does not work the same in mathscript as it does in matlab. The "trapz" function did not seem to integrate the columns in the way that I wanted it to, leaving me with just a number.
    Is there any way I can recreate the "cumtrapz" function from Matlab in Mathscript?
    Thanks.

    The cumtrapz in MathScript can not accept a time array as input. Then, you have to write your own script to calculate the cumulative trapezoid integration. For example, the following script generates a sin wave and calculates the cumulative trapezoidal integration.
    t = 0:0.1:pi;
    x = sin(t);
    y = 0.5*(x(1:(end-1))+x(2:end)).*(t(2:end)-t(1:(end-1)​)); %trapizoidal integration
    y = cumsum(y); %cumulative sum

  • How to find Material Document respect to incoming excise invoices?

    When stock is transfered from one plant to another,
    in sending plant, material document is created, with respect to this material document out bound delivery is created further out bound excise invoices.
    In receiving plant when the incoming stock reached the plant with incoming excise
    invoice, material document is created .
    how to find the this receiving plant material document with respect to incoming excise invoice.?
    how to get the receiving plant material documents with respect to sending plant material documents?

    when  the material is transferred from the one plant to another.
    before going to transfer the material.
    one material document is created
    with respect to multiple item  of material document delivery documents created.
    for every delivery one invoice is generated.
    when the stock is reached to plant with invoice
    with respect to this invoice one material document is created for quality check.
    I this case we may have multiple invoices may have the multiple material documents in receiving plant .
    how to find for which excise invoice it is creating material document in receiving plant?

  • Most efficient way to handle Image sizes with respect to Mobile Screen Size

    Hi all,
    I and trying to find the best possible way to manage Images with respect to the size of mobile screen.
    If I have an image that is best fit on mobile screen size (176 x 144) then how can I make it best fit for (128 x 128) screen size ?
    rizzz86

    Hey Rizzz86,
    You could also scale down a higher resolution image to fit smaller screens, however you will find that resizing by factors other than 2, 4, 8 is harder to achieve with a decent quality and much slower on lower spec devices.
    You could also display 128x128 image centered on 176 x 144 screen with black borders around it.
    It will look not that bad (i.e. borders of 24 pixels top and bottom and 8 pixels left and right) and will cost you nothing in terms of space or processing.
    In the end having an image in 3 different sizes will not increase the MIDlet size by much, unless you are having tens of such images (for example custom UI elements).
    Best solution is to have a bit of both I think. Personally I use scaling down by factors that are powers of 2 and displaying with the black borders.
    Daniel

  • Csv file reading and voltage and current plotting with respect to time samples XY plotting

    Hallo,
             I've been struggling with reading  a comma separated value (csv) file from another instrument (attached). I need to plot this data for analysis. I have 5 column of data with numbers of rows, the first three row is the information of the measurement. I want to read 4th row as string and rest of the row as numbers. I want to plot 2nd column (i1)  with respect to TIMESTAMP; 4th column(u2) wrt TIMESTAMP. And finally plotting i1 (x-axis) vs.. u2 (y-axis) in labview. Could anyone help me.
    In excel its so easy to plot  but I don't know how its done in labview.
    Attachments:
    labview forum test.csv ‏30 KB
    excel plot.jpg ‏88 KB

    Start by opening the file.  Then use the Read Text File function.  You can right-click on it and configure it to read lines.  First make it read 3 lines (this is your extra header data).  Then make it read a single line.  That will give you your channel names.  Then read the rest of the file (disable the read by line and wire a -1 into the number of bytes to read).  Then use the Spreadsheet String to Array function to give you your data.
    I would recommend going through the LabVIEW tutorials if you are really new at this.
    LabVIEW Basics
    LabVIEW 101
    There are only two ways to tell somebody thanks: Kudos and Marked Solutions
    Unofficial Forum Rules and Guidelines

  • T.Code to display Transfer Order with respect to Deliver

    Hi all,
    Can anybody let me know,what is the transaction code to display Transfer Order Created with respect to delivery.
    Thanks in Advance.

    Hi Joginder,
    Thanks for early early.
    Do you know the steps to create TO with respect to delivery.?(by any chance)
    I a technical consultant. I dont have any idea on this.
    I have searched in SDN/Google but couldnt find steps to create TO with delivery.
    Thanks

  • Pan no with respect to vendor in userexit  zxf05u01( package fbk)

    Dear Sir ,
    In below code, Is exit for fk01, now my question is when we use fk02 then through debug mode we get into this exit
    and depending on vendor we find pan no ,but i  do not know from where   pan no coming with respect to vendor in corresponding memory id  .
    so how can we traced out that memory id.
    user exit - ZXF05U01
    DATA : PANCHK TYPE C,
    INPUT TYPE J_1IPANNO.
    TYPES : BEGIN OF ITAB," OCCURS 0,
    TEXT(400) TYPE C,
    END OF ITAB.
    DATA : ITAB TYPE STANDARD TABLE OF ITAB,
    WA_ITAB LIKE LINE OF ITAB,
    WA_PAN TYPE J_1IMOVEND,
    WA_LFA1 TYPE LFA1,
    NAME1 TYPE STRING.
    DATA : K TYPE J_1IPANNO.
    DATA : ST_AUTH TYPE ZFK01.
    *SELECT SINGLE * FROM ZFK01
    INTO CORRESPONDING FIELDS OF ST_AUTH
    WHERE BNAME = SY-UNAME.
    *export ist_resb to memory id 'ZPPC0122_FD'.
    *import *ist_resb *= ist_resb from memory id 'ZPPC0122_FD'.
    *IMPORT ITAB FROM MEMORY ID 'TD'.
    IF I_LFA1-KTOKK = 'Z003' OR I_LFA1-KTOKK = 'Z014'.
    IMPORT PANCHK_1 TO PANCHK FROM MEMORY ID 'PAN01'.
    IF PANCHK NE 'X'.
    MESSAGE 'Enter PAN Number in CIN Detals.' TYPE 'E'.
    MESSAGE E054(ZMM).
    ELSE.
    FREE MEMORY ID 'PAN01'.
    ENDIF.
    ENDIF.
    IMPORT PANACT_1 TO INPUT FROM MEMORY ID 'PANACT'.
    SELECT SINGLE *
    FROM J_1IMOVEND
    INTO CORRESPONDING FIELDS OF WA_PAN
    WHERE J_1IPANNO = INPUT.
    IF SY-SUBRC EQ 0.
    SELECT SINGLE *
    FROM LFA1
    INTO WA_LFA1
    WHERE LIFNR = WA_PAN-LIFNR.
    CONCATENATE '(' WA_LFA1-NAME1 ')' INTO NAME1. " SEPARATED BY SPACE.
    CONCATENATE '@0A@' 'PAN number' WA_PAN-J_1IPANNO 'already exist for vendor' WA_PAN-LIFNR NAME1
    INTO WA_ITAB-TEXT SEPARATED BY SPACE.
    APPEND WA_ITAB TO ITAB.
    IF ITAB[] IS NOT INITIAL.
    CALL FUNCTION 'OIJ_POPUP_TO_DISPLAY_TABLE'
    EXPORTING
    ENDPOS_COL = 100
    ENDPOS_ROW = 10
    STARTPOS_COL = 5
    STARTPOS_ROW = 5
    TITLETEXT = 'Repetition of PAN Number.'
    LINE_WIDTH = 130
    TKT_YEAR = '2010'
    TABLES
    I_TABLE = ITAB[]
    TEST_DOCFLOW =
    DOC_SET_TAB =
    EXCEPTIONS
    BREAK_OFF = 1
    OTHERS = 2.
    FREE MEMORY ID 'PANACT'.
    MESSAGE E055(ZMM) WITH WA_PAN-J_1IPANNO WA_PAN-LIFNR NAME1.
    CLEAR : WA_PAN, WA_LFA1, INPUT.
    ENDIF.
    ENDIF.
    Thanks and regards
    victor

    Dear sir ,
    I found this in as per your given path prabhu, i am not getting which i want.
    "when in fk02 i fill the entry for pan detail then how it come in memory id " PANACT"
    WHICH USED IN USEREXIT OF SAPMF02K WHOSE CODE I PASTED BEFORE.
    ?          help
    SMEM       SAP memory (SPA-GPA)
    MEMORIES   EXPORT/IMPORT memories
    ITAB-ADMIN Internal table administration
    ITAB-HEADS Internal tables: Table headers
    ITAB-PAGES Internal tables: Table body pages
    ITAB-REGIS Internal tables: Registry for references/field-symbols
    ITAB-TOP25 Internal tables: top 25 concerning storage costs
    STRINGHEAD Strings: Header table
    SCREEN     SCREEN table
    DATASETS   datasets / files
    VERSION    system version
    PROGRAMS   programs loaded
    CUA        CUA status data
    DSEG       data segments and work areas
    ES         extendend memory segments (system wide)
    ZTTA       task type area
    SPA        system program area
    PXA        program execution area
    PXA64      program execution area
    Regards
    Victor
    Edited by: victor ezaz on Oct 13, 2011 8:17 AM
    Edited by: victor ezaz on Oct 13, 2011 8:17 AM

  • List of materials with respect to Class type/

    Dear all,
    In which Tcode or table can i find the list of materials with respect to any class type ?
    Table name for Batch Class ?
    or
    How to find KLART ?
    Edited by: Shailesh2510 on Feb 22, 2010 10:55 AM

    hiii
    To get the class type and class , go to table TCLA or TCLAT.
    And one more thing , here standard system , there is transaction code to get class wise materials list.
    If u want u can cevelop custom reports with help of ABAPer.
    If u give the functional details to technical consuiltant , they easily build the report how ever and what ever u want in custom transaction code.
    Any clarification revert,.

  • How to find ANGLE B/W two edges in Oracle Spatial

    How to find ANGLE B/W two edges in Oracle Spatial. I have two edge connected on same node. I wanted to know the angle betwwn them. Can somebody help me out????

    Ok. My first example was an approximation. The farther you get north or south of equator, the more inacurate it gets.
    This one should do the trick with some degree of accuracy.
    declare
      PI constant number := 3.14159265358979;
      g1 sdo_geometry;
      g2 sdo_geometry;
      g3 sdo_geometry;
      angle1 number;
      angle2 number;
      FUNCTION POINT(P_LAT  IN number
                    ,P_LONG IN number)
        RETURN MDSYS.SDO_GEOMETRY IS
      BEGIN
        -- we load both the ordinate array and the point type because some spatial functions show inconsistent behavior
        -- it is not important for this example, just something to be aware of
        return(mdsys.sdo_geometry(2001,8307 -- WGS84
                                 ,mdsys.sdo_point_type(p_long,p_lat,null)
                                                      ,mdsys.sdo_elem_info_array(1,2,1)
                                                      ,mdsys.sdo_ordinate_array(p_long,p_lat)));
      END;
    begin
      -- For the example, project in WGS84
      -- g1,g2,g3 could also come straight out of the database as sdo_geometry
      g1 := point(50, 7);          -- Point A
      g2 := point(51, 7);          -- Point B
      g3 := point(50,10);          -- Point C
      angle1 := atan2(g2.sdo_point.x - g1.sdo_point.x,
                      g2.sdo_point.y - g1.sdo_point.y);
      angle2 := atan2(g3.sdo_point.x - g1.sdo_point.x,
                      g3.sdo_point.y - g1.sdo_point.y);
      -- depending on rotation and where we are on the planet, adjustments may be needed
      if angle1 < 0      then angle1 := angle1 + 2 * PI; end if;
      if angle2 < 0      then angle2 := angle2 + 2 * PI; end if;
      if angle2 < angle1 then angle2 := angle2 + 2 * PI; end if;
      dbms_output.put_line('Angle between the lines A-B and A-C: '||
                           round(sdo_util.convert_unit(angle2-angle1,'Radian','Degree'),1));
    end;
    Angle between the lines A-B and A-C: 90

  • Capabillities of xMII with respect to TIBCO in integrating shop floor

    Can any  one tell capabilities of xMII  in comparision with TIBCO with respect to shop floor integration  and KPI generation . which is better.

    First off, Like Ryan I too am bias towards xMII. Secondly I don't know that much about TIBCO, but here are some questions you ask in order to compare xMII with TIBCO:
    1.) xMII is a very good data aggregate where you the customer determines what you need and how to use it. Does TIBCO have this functionality? Your applications come first in xMII, the functionality is not limited to just a set of canned KPIs, you can quickly and easily add new KPIs dependant on your needs.
    2.) Shop floor connectivity is critical, Does TIBCO have the connectivity that xMII offers?
    3.) xMII has great performance and is light weight. Unlike most 'Enterprise Level' application platforms, SAP xMII considers real-time to be in the order of seconds to minutes, not days or weeks. The largest overhead in an xMII installation (minus any other SAP systems) is NetWeaver.
    Try to figure out you scenario, find all the business requirements you need, then check out xMII's abilities vs TIBCO. I think you'll agree that xMII can handle what ever TIBCO offers and most likely even more.
    Martin.

  • Authorization  with respect to Project profile

    Dear All
    i have one problem pl suggest me
    I'm implementing one project ... i'm in authorization matrix i need to give the authorization with respect to Project profile
    Ex .  one controlling area
            two company code
            ten project profile
    each profile have different  responsible  person (some time five to six person are in single project)
    In one plant they are using six different project profile .this my concertino
    now i need to control the authorization with respect to Project profile .i'm not able to find the any object in the authorization matrix . pl suggest me . if know the technical object name pl suggest me

    You can use the following objects for controlling authorisations:
    Co Area
    Cost Center
    Profit Center
    Project Manager
    Project Type
    I don not believe there is an auth object for Project Profile.   If you have a 1 : 1 relationship between your project profile and project type, than it would be possible to use this to secure authorisations.
    C_PRPS_ART.
    I hope this helps.
    Ian

  • "Currency settings with respect to country code"

    Folks,
    Kindly l;et me know where can we see "Currency settings with respect to country code"

    hi,
    For Country Currency
    R/3 4.7C
    SPRO > IMG >  General Setting > Set Countries > Define Countries in my SAPsystem
    ECC 6.00
    SPRO > IMG > SAP Netviewer > General Setting > Set Countries > Define Countries in my SAPsystem
    Double Click on Country you will find ther HArd Currency and Index currency
    For Company Code Currency
    SPRO > IMG > Enterprise Structure > Financial Accounting > Edit, Copy, Check, Delete Company Code > Edit Company Code Data
    Double click on your company code  you will find company code currency there.
    For Group Currency
    Check Client Setting
    thx.
    Ganpat

  • Blocked customers with respect to division

    hi,
       can anyone please tell me the field for blocked customers.....i guess aufsd from kna1 is used but it is with respect to the customernumber....but i want to find the blocked customers with respect to division(spart) which is in knvv table...
    thanks in advance,
    syed

    hi,
    its already available in the standard. we can do credit check at the sales area level. You can take wholesale and retail as two dist. channels. Now you will have two different sales areas.
    Allow the required credit. Please check the assignment part of enterprise structure in SD. by assigning your sales area to a credit contrl area you can do this.
    regards
    sadhu kishore

Maybe you are looking for

  • My safari keeps quitting and I can't for the life of me figure it out. Help PLEASE!

    Here is the information that keeps coming up. Process:         Safari [611] Path:            /Users/TaniaB/Desktop/Safari.app/Contents/MacOS/Safari Identifier:      com.apple.Safari Version:         5.0.6 (5533.22.3) Build Info:      WebBrowser-75332

  • Constant Contact + Address Book Exporter application

    Since installing Snow Leopard and Quickbooks 2010 (and turning back on Sync in QB) my Address Book Exporter application will not export names and email addresses without all having errors. Can no longer import them. Any suggestions and thank you.

  • Any Body tell me how to add JDesktoppane in contain panel for Mdi

    i want to create custome componet using JDesktoppane for using mdi application any body tell me how to create custome JDesktop pane like JNumberText feild as in JDeveloper HowTos please help and mail the slution on [email protected] ill be very thank

  • Can't get Contacts/Calendar to transfer from iPod Touch to iPhone 3Gs

    Just got the new iPhone 3Gs, and I have an iPod Touch (1st gen). I chose to sync manually because I didn't want my son's apps on my iPhone, but when I tried to sync my contacts and calendar from the iTouch to the iPhone, I get no contacts. How can I

  • Problem with site-to-site connection

    Guys, I have a problem with establishing site-to-site vpn connection between my 2911 and remote router. I have different site-to-site vpn on second WAN interface and it works like a charm. I performed same steps in order to configure new VPN to diffe