
TXTechie
Active Members-
Posts
158 -
Joined
-
Last visited
Content Type
Forums
Downloads
Forum Articles
Events
Everything posted by TXTechie
-
Hello Everyone, Does anyone know whether or not AutoIt (a built-in function or a UDF) has a workaround or solution for dealing with Windows 7's Interactive Services Detection feature? For non-silent deployment packages (those that show some level of User Interface - UI) on Windows 7 (or Vista) how do you display a dialog box, progress bar, message, etc. to the user (Session 1) when deploying a software package that is being deployed by a software deployment solution that utilizes the Local System (SYSTEM) account (Session 0)? Regards, TX Techie
-
StringUpper not working on a variable?
TXTechie replied to TXTechie's topic in AutoIt General Help and Support
Oh wow! Now I feel like a complete newb! Thank you, UEZ & BrewManNH - of course that works! TX Techie -
This is weird. If I use the following code, StringUpper works: $PC = StringUpper(InputBox($ScriptTitle, "Enter the Computer Name:")) However, since I have to check for @error based on the input of the InputBox, I had to move it until after the $PC variable was populated, which I figured would work the same, but it's not. If I use the following code, the contents of the $PC variable does not get converted to UPPERCASE characters: $PC = InputBox($ScriptTitle, "Enter the Computer Name:") If @error = 1 Then Exit StringUpper($PC) Can someone assist me with how I can convert a variable to all UPPERCASE characters? Regards, TX Techie
-
No.
-
As I eluded to previously, I'm running the script on another PC that doesn't have AutoIt installed but the user has the appropriate AD privileges. So, I compile in order to run it there. I'm just wondering how everyone else deals with troubleshooting a compiled AutoIt script when it raises an error that you haven't already trapped/handled?
-
Yes, the Misc.au3 script.
-
How can I determine that from the error it raises (especially when there is now only 140 lines of actual code in the script)?:
-
I included the following error handling: If $objRR = 0 Or Not IsObj($objRR) Then ; Display a MessageBox dialog with a yellow Exclamation-point icon and the "OK" button MsgBox(48, $Title & " v" & $Version, "The [" & $strOwnerShortName & "] DNS Record was NOT found! Exiting the application.") ; Exit the script with error status = 1 Exit (1) EndIf But, I'm still getting the generic Error: Variable must be of type "Object". error. I'll look into the ObjEvent event in Help. Thanks!
-
Can someone assist me with how to better trap/handle the error I'm getting from the compiled script (Line 436) so that I can better determine where it is and what's going on? I'm receiving the Error: Variable must be of type "Object". from the compiled script when the DNS Record that it is expecting is actually not in AD (it has been deleted). I'm assuming it's during this code that the error is thrown, since the AD "object" (the DNS Record) doesn't exist: Dim $objRR = $objDNS.ExecQuery("SELECT * FROM MicrosoftDNS_ResourceRecord" & _ " WHERE ContainerName='" & $strDomainName & "' AND OwnerName='" & $strOwnerName & "'") For $objRR2 In $objRR ... Can anyone assist me?
-
Thank you, water. I'll modify my script to perform the same check as you use in your Office UDFs.
-
Hi water, Whlie this thread does not utilize the AD UDF, I specifically put AD in the subject line to differentiate between the Active Directory DNS service (which my script is manipulating) vs. local PC DNS settings (which I primarily saw when I searched through the forum).
-
Thank you, BrewManNH! Using ObjGet did the trick. In researching this in the forum (and in previous scripts where I've used objects), using ObjCreate seemed to be the primary way to use objects. I guess I still need to learn more about objects. Can you (or someone) give me a good rule of thumb for when to use ObjGet and when to use ObjCreate?
-
Hi BrewManNH, Yes, just like the original VBScript code that works: Set objDNS = GetObject("winMgmts:\\" & strDNSServer & "\root\MicrosoftDNS") Set objRR = objDNS.ExecQuery("SELECT * FROM MicrosoftDNS_ResourceRecord" & _ " WHERE ContainerName='" & strDomainName & "' AND OwnerName='" & strOwnerName & "'",,48) I even tried it without the [,,48] and while it compiled without error, I received the same "variable must be of type Object" error.
-
Hello Everyone, I've ported over the following script from VBScript (where it works fine) to AutoIt: Dim $objDNS = ObjCreate("winMgmts:\\" & $strDNSServer & "\root\MicrosoftDNS") Dim $objRR = $objDNS.ExecQuery("SELECT * FROM MicrosoftDNS_ResourceRecord" & _ " WHERE ContainerName='" & $strDomainName & "' AND OwnerName='" & $strOwnerName & "'",,48) I have to compile the script and run it on a PC where the logged on user has the appropriate AD privileges. When I attempt to compile it (with AU3Check turned on) I get the following error: If I turn off AU3Check and go ahead and compile the code, on the PC (where I know permissions is NOT the issue because I can run the same VBScript-syntaxed code on the same PC successfully) I get the following runtime error: Can someone please hep me?
-
How to split filename on 1st numeric digit?
TXTechie replied to TXTechie's topic in AutoIt General Help and Support
Thank you very much, GMK! That did the trick! -
I will have a folder full of files that look similar to this: RA_CUSTOMER_TRX_ALL_06o3415r7eobtvsr5965b7wrp0ha0200baq.xmlThe first part of the files ( words in ALL CAPS separated by underscore characters [ _ ] ) will be different for most every file as will the list of random-looking alpha-numeric characters that make up the second part of the files. I'm already looping through the folder of files parsing for some other things, but can someone help me with a way to parse out and capture the first part of the filename (RA_CUSTOMER_TRX_ALL_ in my example above - including the final underscore character) into a variable? I would very much appreciate the assistance! TX Techie
-
I appreciate your patience in working with me, PsaltyDS. When I use the following script: #include <XMLDomWrapper.au3> Global $debugging = True, $iRET, $configtype Global $sXML = @ScriptDir & "\Test.xml" $iRET = _XMLFileOpen($sXML) ConsoleWrite("$iRET = " & $iRET & @LF) I get a return of "1", which means it successfully opened the xml file, correct? Now what do I do?
-
Hi PsaltyDS, I've tried some of the examples but I keep getting a "-1". I don't know anything about XML structures and so I don't know what the <OBT_WF_RUN_ID> element is in order to know which function(s) within the XMLDomWrapper I should use in order to determine the value of the <OBT_WF_RUN_ID> element. So, I was hoping for some direction. Since I don't need to loop through the entire document enumerating values, I just need to obtain this one value - I've found it difficult to figure out how to do this from the many examples in this message thread. Any assistance is appreciated! TX Techie
-
Can someone give me an idea of how to get started using the XMLDomWrapper.au3 UDF to read my xml file? I just need to obtain the <OBT_WF_RUN_ID></OBT_WF_RUN_ID> record. Here's a portion of my XML file: <?xml version='1.0' encoding='UTF-8'?> <encapsulatedArchiveGroup xmlns="http://www.hp.com/EA/6.2.0/RA_CUSTOMER_TRX_ALL/1.0.0.0/06o3415r7eobtvsr5965b7wrp0ha0200baq/GROUP_XML" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.hp.com/EA/6.2.0/RA_CUSTOMER_TRX_ALL/1.0.0.0/06o3415r7eobtvsr5965b7wrp0ha0200baq/GROUP_XML RA_CUSTOMER_TRX_ALL_06o3415r7eobtvsr5965b7wrp0ha0200baq_group.xsd" fileInitialName="RA_CUSTOMER_TRX_ALL_06o3415r7eobtvsr5965b7wrp0ha0200baq_group_0.xml"> <groupSpec> <productName>EA</productName> <productVersion>6.2.0</productVersion> <workflowRunId>3357</workflowRunId> <runGuid>06o3415r7eobtvsr5965b7wrp0ha0200bax</runGuid> <archiveGuid>06o3415r7eobtvsr5965b7wrp0ha0200baq</archiveGuid> <groupGuid>06o3415r7eobtvsr5965b7wrp0ha0200bau</groupGuid> <sequence>0</sequence> <beginTime>2011-06-23T12:13:44.000000000-05:00</beginTime> <appsPack> <name>RA_CUSTOMER_TRX_ALL</name> <version>1.0.0.0</version> </appsPack> <source> <guid>06o3415r7eobtvsr5965b7wrp0ha0200bav</guid> <status>ACTIVE</status> <category>DATABASE</category> <type>Oracle</type> <locationProperty name="Port">10010</locationProperty> <locationProperty name="Host">auohseoai24.oracleoutsourcing.com</locationProperty> <locationProperty name="Database">oracle</locationProperty> <locationProperty name="DBServer">PEOAII</locationProperty> <locationProperty name="ConnType">default</locationProperty> <locationProperty name="UserID">obt_if</locationProperty> <locationProperty name="DriverType">Type 4</locationProperty> <locationProperty name="CharacterSet">UTF8</locationProperty> </source> <destination> <guid>06o3415r7eobtvsr5965b7wrp0ha0200baw</guid> <status>ACTIVE</status> <category>BACKEND</category> <type>Filesystem</type> <locationProperty name="Host">auohseoai14</locationProperty> <locationProperty name="UserID">obt</locationProperty> <locationProperty name="Directory">/peoaii/3rdparty/HP/D2F/AR</locationProperty> <file> <id xsi:nil="true"/> <preProcessName>RA_CUSTOMER_TRX_ALL_06o3415r7eobtvsr5965b7wrp0ha0200baq_group_0.xml</preProcessName> <postProcessName>RA_CUSTOMER_TRX_ALL_06o3415r7eobtvsr5965b7wrp0ha0200baq_group_0.xml</postProcessName> <type>DATA</type> <groupGuid>06o3415r7eobtvsr5965b7wrp0ha0200bau</groupGuid> <checksum> <algorithm>NONE</algorithm> </checksum> <compression>NONE</compression> </file> </destination> </groupSpec> <attInstances> <attInstance guid="3357-1"> <RA_CUSTOMER_TRX_ALL> <CUSTOMER_TRX_ID>68683</CUSTOMER_TRX_ID> <LAST_UPDATE_DATE>2003-04-02T12:25:35.000000000-06:00</LAST_UPDATE_DATE> <LAST_UPDATED_BY>1261</LAST_UPDATED_BY> <CREATION_DATE>2003-04-02T12:25:02.000000000-06:00</CREATION_DATE> <CREATED_BY>1261</CREATED_BY> <LAST_UPDATE_LOGIN>967894</LAST_UPDATE_LOGIN> <TRX_NUMBER>406338</TRX_NUMBER> <CUST_TRX_TYPE_ID>1000</CUST_TRX_TYPE_ID> <TRX_DATE>2003-04-02T00:00:00.000000000-06:00</TRX_DATE> <SET_OF_BOOKS_ID>1</SET_OF_BOOKS_ID> <BILL_TO_CONTACT_ID xsi:nil="true"/> <BATCH_ID>3413</BATCH_ID> <BATCH_SOURCE_ID>1029</BATCH_SOURCE_ID> <REASON_CODE xsi:nil="true"/> <SOLD_TO_CUSTOMER_ID>5244</SOLD_TO_CUSTOMER_ID> <SOLD_TO_CONTACT_ID xsi:nil="true"/> <SOLD_TO_SITE_USE_ID xsi:nil="true"/> <BILL_TO_CUSTOMER_ID>5244</BILL_TO_CUSTOMER_ID> <BILL_TO_SITE_USE_ID>6109</BILL_TO_SITE_USE_ID> <SHIP_TO_CUSTOMER_ID>5244</SHIP_TO_CUSTOMER_ID> <SHIP_TO_CONTACT_ID xsi:nil="true"/> <SHIP_TO_SITE_USE_ID>9155</SHIP_TO_SITE_USE_ID> <SHIPMENT_ID xsi:nil="true"/> <REMIT_TO_ADDRESS_ID>1020</REMIT_TO_ADDRESS_ID> <TERM_ID>1000</TERM_ID> <TERM_DUE_DATE xsi:nil="true"/> <PREVIOUS_CUSTOMER_TRX_ID xsi:nil="true"/> <PRIMARY_SALESREP_ID>100000042</PRIMARY_SALESREP_ID> <PRINTING_ORIGINAL_DATE>2003-04-03T05:11:31.000000000-06:00</PRINTING_ORIGINAL_DATE> <PRINTING_LAST_PRINTED>2003-08-08T15:03:43.000000000-05:00</PRINTING_LAST_PRINTED> <PRINTING_OPTION>PRI</PRINTING_OPTION> <PRINTING_COUNT>5</PRINTING_COUNT> <PRINTING_PENDING>N</PRINTING_PENDING> <PURCHASE_ORDER>03/28/2003</PURCHASE_ORDER> <PURCHASE_ORDER_REVISION xsi:nil="true"/> <PURCHASE_ORDER_DATE xsi:nil="true"/> <CUSTOMER_REFERENCE xsi:nil="true"/> <CUSTOMER_REFERENCE_DATE xsi:nil="true"/> <COMMENTS xsi:nil="true"/> <INTERNAL_NOTES xsi:nil="true"/> <EXCHANGE_RATE_TYPE xsi:nil="true"/> <EXCHANGE_DATE xsi:nil="true"/> <EXCHANGE_RATE xsi:nil="true"/> <TERRITORY_ID xsi:nil="true"/> <INVOICE_CURRENCY_CODE>USD</INVOICE_CURRENCY_CODE> <INITIAL_CUSTOMER_TRX_ID xsi:nil="true"/> <AGREEMENT_ID xsi:nil="true"/> <END_DATE_COMMITMENT xsi:nil="true"/> <START_DATE_COMMITMENT xsi:nil="true"/> <LAST_PRINTED_SEQUENCE_NUM>0</LAST_PRINTED_SEQUENCE_NUM> <ATTRIBUTE_CATEGORY>ORDER</ATTRIBUTE_CATEGORY> <ATTRIBUTE1 xsi:nil="true"/> <ATTRIBUTE2>AS400</ATTRIBUTE2> <ATTRIBUTE3>03-MAY-03</ATTRIBUTE3> <ATTRIBUTE4 xsi:nil="true"/> <ATTRIBUTE5 xsi:nil="true"/> <ATTRIBUTE6 xsi:nil="true"/> <ATTRIBUTE7 xsi:nil="true"/> <ATTRIBUTE8 xsi:nil="true"/> <ATTRIBUTE9>(BACKORDER) B030861133</ATTRIBUTE9> <ATTRIBUTE10 xsi:nil="true"/> <ORIG_SYSTEM_BATCH_NAME xsi:nil="true"/> <POST_REQUEST_ID xsi:nil="true"/> <REQUEST_ID>903184</REQUEST_ID> <PROGRAM_APPLICATION_ID>222</PROGRAM_APPLICATION_ID> <PROGRAM_ID>20428</PROGRAM_ID> <PROGRAM_UPDATE_DATE>2003-04-02T12:25:02.000000000-06:00</PROGRAM_UPDATE_DATE> <FINANCE_CHARGES xsi:nil="true"/> <COMPLETE_FLAG>Y</COMPLETE_FLAG> <POSTING_CONTROL_ID>-3</POSTING_CONTROL_ID> <BILL_TO_ADDRESS_ID xsi:nil="true"/> <RA_POST_LOOP_NUMBER xsi:nil="true"/> <SHIP_TO_ADDRESS_ID xsi:nil="true"/> <CREDIT_METHOD_FOR_RULES xsi:nil="true"/> <CREDIT_METHOD_FOR_INSTALLMENTS xsi:nil="true"/> <RECEIPT_METHOD_ID xsi:nil="true"/> <ATTRIBUTE11 xsi:nil="true"/> <ATTRIBUTE12 xsi:nil="true"/> <ATTRIBUTE13 xsi:nil="true"/> <ATTRIBUTE14>Customer_Pays-Customer_Pays</ATTRIBUTE14> <ATTRIBUTE15 xsi:nil="true"/> <RELATED_CUSTOMER_TRX_ID xsi:nil="true"/> <INVOICING_RULE_ID xsi:nil="true"/> <SHIP_VIA>UPS</SHIP_VIA> <SHIP_DATE_ACTUAL>2003-04-02T00:00:00.000000000-06:00</SHIP_DATE_ACTUAL> <WAYBILL_NUMBER>0</WAYBILL_NUMBER> <FOB_POINT xsi:nil="true"/> <CUSTOMER_BANK_ACCOUNT_ID xsi:nil="true"/> <INTERFACE_HEADER_ATTRIBUTE1>16201</INTERFACE_HEADER_ATTRIBUTE1> <INTERFACE_HEADER_ATTRIBUTE2>DOM_LENS_DAILY_CNV</INTERFACE_HEADER_ATTRIBUTE2> <INTERFACE_HEADER_ATTRIBUTE3>F90-0001012966</INTERFACE_HEADER_ATTRIBUTE3> <INTERFACE_HEADER_ATTRIBUTE4>0</INTERFACE_HEADER_ATTRIBUTE4> <INTERFACE_HEADER_ATTRIBUTE5>0</INTERFACE_HEADER_ATTRIBUTE5> <INTERFACE_HEADER_ATTRIBUTE6>485028</INTERFACE_HEADER_ATTRIBUTE6> <INTERFACE_HEADER_ATTRIBUTE7>0</INTERFACE_HEADER_ATTRIBUTE7> <INTERFACE_HEADER_ATTRIBUTE8>0</INTERFACE_HEADER_ATTRIBUTE8> <INTERFACE_HEADER_CONTEXT>ORDER ENTRY</INTERFACE_HEADER_CONTEXT> <DEFAULT_USSGL_TRX_CODE_CONTEXT xsi:nil="true"/> <INTERFACE_HEADER_ATTRIBUTE10>45</INTERFACE_HEADER_ATTRIBUTE10> <INTERFACE_HEADER_ATTRIBUTE11>0</INTERFACE_HEADER_ATTRIBUTE11> <INTERFACE_HEADER_ATTRIBUTE12> 1</INTERFACE_HEADER_ATTRIBUTE12> <INTERFACE_HEADER_ATTRIBUTE13> 0</INTERFACE_HEADER_ATTRIBUTE13> <INTERFACE_HEADER_ATTRIBUTE14> 0</INTERFACE_HEADER_ATTRIBUTE14> <INTERFACE_HEADER_ATTRIBUTE15 xsi:nil="true"/> <INTERFACE_HEADER_ATTRIBUTE9>0</INTERFACE_HEADER_ATTRIBUTE9> <DEFAULT_USSGL_TRANSACTION_CODE xsi:nil="true"/> <RECURRED_FROM_TRX_NUMBER xsi:nil="true"/> <STATUS_TRX>OP</STATUS_TRX> <DOC_SEQUENCE_ID xsi:nil="true"/> <DOC_SEQUENCE_VALUE xsi:nil="true"/> <PAYING_CUSTOMER_ID xsi:nil="true"/> <PAYING_SITE_USE_ID xsi:nil="true"/> <RELATED_BATCH_SOURCE_ID xsi:nil="true"/> <DEFAULT_TAX_EXEMPT_FLAG xsi:nil="true"/> <CREATED_FROM>RAXTRX</CREATED_FROM> <ORG_ID>52</ORG_ID> <WH_UPDATE_DATE xsi:nil="true"/> <GLOBAL_ATTRIBUTE1 xsi:nil="true"/> <GLOBAL_ATTRIBUTE2 xsi:nil="true"/> <GLOBAL_ATTRIBUTE3 xsi:nil="true"/> <GLOBAL_ATTRIBUTE4 xsi:nil="true"/> <GLOBAL_ATTRIBUTE5 xsi:nil="true"/> <GLOBAL_ATTRIBUTE6 xsi:nil="true"/> <GLOBAL_ATTRIBUTE7 xsi:nil="true"/> <GLOBAL_ATTRIBUTE8 xsi:nil="true"/> <GLOBAL_ATTRIBUTE9 xsi:nil="true"/> <GLOBAL_ATTRIBUTE10 xsi:nil="true"/> <GLOBAL_ATTRIBUTE11 xsi:nil="true"/> <GLOBAL_ATTRIBUTE12 xsi:nil="true"/> <GLOBAL_ATTRIBUTE13 xsi:nil="true"/> <GLOBAL_ATTRIBUTE14 xsi:nil="true"/> <GLOBAL_ATTRIBUTE15 xsi:nil="true"/> <GLOBAL_ATTRIBUTE16 xsi:nil="true"/> <GLOBAL_ATTRIBUTE17 xsi:nil="true"/> <GLOBAL_ATTRIBUTE18 xsi:nil="true"/> <GLOBAL_ATTRIBUTE19 xsi:nil="true"/> <GLOBAL_ATTRIBUTE20 xsi:nil="true"/> <GLOBAL_ATTRIBUTE21 xsi:nil="true"/> <GLOBAL_ATTRIBUTE22 xsi:nil="true"/> <GLOBAL_ATTRIBUTE23 xsi:nil="true"/> <GLOBAL_ATTRIBUTE24 xsi:nil="true"/> <GLOBAL_ATTRIBUTE25 xsi:nil="true"/> <GLOBAL_ATTRIBUTE26 xsi:nil="true"/> <GLOBAL_ATTRIBUTE27 xsi:nil="true"/> <GLOBAL_ATTRIBUTE28 xsi:nil="true"/> <GLOBAL_ATTRIBUTE29 xsi:nil="true"/> <GLOBAL_ATTRIBUTE30 xsi:nil="true"/> <GLOBAL_ATTRIBUTE_CATEGORY xsi:nil="true"/> <EDI_PROCESSED_FLAG xsi:nil="true"/> <EDI_PROCESSED_STATUS xsi:nil="true"/> <MRC_EXCHANGE_RATE_TYPE xsi:nil="true"/> <MRC_EXCHANGE_DATE xsi:nil="true"/> <MRC_EXCHANGE_RATE xsi:nil="true"/> <PAYMENT_SERVER_ORDER_NUM xsi:nil="true"/> <APPROVAL_CODE xsi:nil="true"/> <ADDRESS_VERIFICATION_CODE xsi:nil="true"/> <OLD_TRX_NUMBER xsi:nil="true"/> <BR_AMOUNT xsi:nil="true"/> <BR_UNPAID_FLAG xsi:nil="true"/> <BR_ON_HOLD_FLAG xsi:nil="true"/> <DRAWEE_ID xsi:nil="true"/> <DRAWEE_CONTACT_ID xsi:nil="true"/> <DRAWEE_SITE_USE_ID xsi:nil="true"/> <REMITTANCE_BANK_ACCOUNT_ID xsi:nil="true"/> <OVERRIDE_REMIT_ACCOUNT_FLAG xsi:nil="true"/> <DRAWEE_BANK_ACCOUNT_ID xsi:nil="true"/> <SPECIAL_INSTRUCTIONS xsi:nil="true"/> <REMITTANCE_BATCH_ID xsi:nil="true"/> <PREPAYMENT_FLAG xsi:nil="true"/> <CT_REFERENCE>16201</CT_REFERENCE> <CONTRACT_ID xsi:nil="true"/> <BILL_TEMPLATE_ID xsi:nil="true"/> <REVERSED_CASH_RECEIPT_ID xsi:nil="true"/> <OBT_ROW_SEQ>1</OBT_ROW_SEQ> <OBT_TIMESTAMP>2007-11-20T16:46:26.000000000-06:00</OBT_TIMESTAMP> <OBT_WF_RUN_ID>160</OBT_WF_RUN_ID> <OBT_SAVED_ROWID>AAGb8DAKBAAAJLHAAD</OBT_SAVED_ROWID> <CC_ERROR_CODE xsi:nil="true"/> <CC_ERROR_TEXT xsi:nil="true"/> <CC_ERROR_FLAG xsi:nil="true"/> </RA_CUSTOMER_TRX_ALL> </attInstance> Thank you, TX Techie