chase sapphire credit card deal gas credit cards bad credit visa credit card app iphone virgin credit card log on uk how to use a secured credit card to build credit walmart credit card 0 interest loans online decision bad credit credit card travel points canada credit cards visa applications prepaid credit cards canada visa how do i get a credit card us bank credit card payment zip code 200 bonus cash back credit card ge money amazon credit card payment does costco accept credit cards 2011 citibank credit cards balance transfer offers bad credit credit cards no credit check natwest credit card protection refund loan with bad credit and no job compare credit card benefits uk best credit cards 2013 us bank credit card processing reviews horizon credit card 1800 number blank automatic credit card billing authorization form credit cards with travel rewards for average credit compare american express delta credit cards cash advance rate definition getting a pay advance from employer credit card instant approval canada credit card consolidation loans calculator long term loans with bad credit canada compare credit card rates australia virgin credit card ppi reclaim best no annual fee credit card 2012 business credit cards comparison shopping tips icici credit card ebay offer 2013 online payday loans compare citibank credit card online application form post bankruptcy credit cards offers do you get free shipping with ann taylor credit card hdfc cash back credit card get online visa card current credit card apr average best credit card company in india square credit card app for iphone cash back credit card malaysia 2012 direct payday lenders bad credit ok compare 0 purchase credit cards southwest airlines credit card review 2013 target credit card visa application best travel insurance credit card canada virgin america credit card barclay yatra barclaycard platinum credit card cash back debit cards 2013 instant no credit check payday loans uk getting a credit card machine for my business credit cards for fair credit in canada mastercard credit cards applications quick payday loan lenders no credit check american express platinum card benefits regus credit card debt consolidation ontario canada mastercard debit card uk online loans instant decision south africa walmart mastercard payment address idbi credit card apply online can i get a home loan with bad credit credit card charges overseas travel bad credit loans canada pay off credit card debt or car loan does chase bank offer prepaid credit cards interest free credit card debt consolidation credit card verification web service westpac bank credit card balance transfer payday lenders only no credit check aspire credit card mailing address merchant account online credit card processing best travel reward credit cards canada 2013 formula to calculate monthly credit card interest credit card payment machine for iphone credit cards apply online ireland new hacked credit cards 2013 new credit card issuers uk address to pay orchard bank credit card american express air miles credit card platinum best uk credit card is it a good idea to consolidate your credit cards top best credit cards for college students amazon credit card points expire tesco 0 credit card limit how to get a credit card with bad credit disney chase reward cards where to buy prepaid credit cards best credit cards for good credit instant virtual visa card online capital one credit card payment western union bad credit payday loans direct lenders only guaranteed unsecured credit card approval canada free working visa credit card number 2013 bank of america credit card with travel rewards penfed credit card approval rates buy virtual credit card with bitcoin analysis of credit card fraud detection system unsecured credit card debt canada what is cash advance wells fargo real credit card numbers that work 2013 with security code how to change your credit card on itunes on iphone cash loans uk no bank account new payday loan lenders uk 2012 hsbc student credit card minimum payment instant cash loans no brokers low interest credit card balance transfer offers merchant cash advance software virgin credit cards contact address how much does a prepaid credit card cost at walmart chase credit card us consumer reports best credit card reward programs sbi credit card reward points redeem catalog canadian credit card debt help southwest credit card us bank credit card pay your lord and taylor credit card best mastercard credit card 2013 credit card insurance cover is usaa secured credit card good good credit card for 650 score best credit card transfer rate nz apply for hdfc credit card with no annual fee anz visa card exchange rate secured credit card for bad credit uk what;s the best secured credit card to rebuild credit credit card machine for iphone app axis bank online credit card application approved cash advance marriott chase business credit card hdfc online credit card application credit card approval no credit check capital one credit card application check credit cards after bankruptcy discharge 2012 visa mastercard prepaid credit cards how to get a prepaid credit card at walmart nissan visa cash card offer brought to you by edmunds com best credit card rate canada prepaid post office credit card online payday cash loans no credit check free credit card information that works 2013 mortgage loan with bad credit score real online cash loans charges for cash advances on credit cards paying chase credit cards online credit card for bad credit instant approval cape town money magazine best reward cards barclay credit card disney visa card offers obc sbi credit card status halifax credit card 0845 direct payday loan lender td visa credit card activation number credit card rewards points calculator loan to reduce credit card debt promotional code for american express prepaid credit card apply for walmart discover credit card credit card machine for iphone 3gs (canadian credit cards low interest balance transfer) calculate credit card interest on purchases hsbc premier credit card points fixed rate credit card applications lowest interest credit cards uk credit report free uk low interest credit card consolidation loans sear credit card payment usaa american express credit card review chase credit card poor credit direct payday loan lenders online credit card debt relief programs legitimate credit card numbers for testing with security code best credit card student canada danamon manchester united credit card hsbc canada credit card stolen best credit card interest rates 2011 apply online credit card natwest how to get a military pay advance best credit card offer in india should i close my first premier credit card do department store credit cards help your credit score my first credit card to build credit best american express credit card with no annual fee pay gap visa card natwest world credit card interest free best current credit card rates credit card applications pdf can i get a credit card without a job top 10 online loan companies best rewards visa credit card canada hsbc credit card minimum payment pay off jcpenney credit card best credit cards in canada for students new credit card charges bank america credit cards travel insurance comparison capital one secured credit card after bankruptcy virtual international credit card india apply for mastercard by phone apple credit card details change what are good credit cards to have for students bad credit loans guaranteed approval monthly payments cash loans for bad credit in south africa can you get a payday loan online application for target credit card visa travel reward credit cards for average credit paperless online cash loans south africa credit limits international quick payday loans no credit check no faxing $5000 bad credit loan australia best buy capital one credit card payment best visa mastercard rewards credit card small business credit card 0 balance transfer sears credit card canada customer service visa credit card verification phone number maybank credit card online application malaysia 100 guaranteed payday loan no credit checks best travel credit card australia 2012 who is liable to pay advance tax in india credit card number and cvv number app to store rewards cards best credit cards for students with no credit 2013 no credit credit cards instant approval sample us credit card number best credit card promotions 2013 credit cards for poor credit hdfc platinum credit card cash advance charges how much does it cost to accept credit cards online car hire credit card insurance uk credit card minimum payment interest prepaid visa card reloadable online prepaid credit card no annual fee average credit card processing charges no interest credit cards australia fbi credit card information form what is credit card apr rate student credit cards uk natwest 0 balance transfer card three reached credit limit best visa credit card offers can i transfer money from my halifax credit card to my current account low interest rate credit cards usa easy to get credit cards australia brand new payday loan lenders td bank visa debit card rewards login types of credit card frauds in india tesco credit card online my account ocbc credit card promotions singapore prepaid credit cards business quickbooks intuit credit card processing instant credit cards how to calculate credit card interest rate in excel best buy credit card payments online citibank business credit card payment clark howard how to choose a credit card is it good to have high credit card limits credit card companies that use equifax sbi credit card apply hsbc credit cards online australia citibank american airlines credit card offers best credit card for balance transfers 2011 icici credit card bill payment by cheque discovery credit card statement $5000 unsecured bad credit loan secured credit card reviews bank of america chase credit card security code how to write a cheque for sbi credit card payment disney visa card promo code current average credit card interest rate i want to apply for the moneybookers mastercard sbi credit card reviews india american express prepaid credit cards promotion code major credit card logos png american express black card requirements 2013 hdfc titanium credit card cash back best corporate credit cards for small business what credit card can i get with a 575 credit score accepting credit cards online paypal reward credit cards compare hdfc credit card application status using mobile number 0 balance transfer no fee credit card offers teachers federal credit union secured credit cards what is a credit card number i can use indian bank credit card statement what do i need to get a payday advance from amscot buy visa card number online check balance firestone credit card santander 123 credit card cash back list payday loans direct lenders only no credit check uk mastercard cash plus login credit card companies list wiki black lace cardigan new look how to pay hdfc credit card payment options real valid credit card numbers that work barclay credit card login uk bad credit loans no credit check no guarantor best credit card rewards 2012 uk car finance bad credit essex find my walmart credit card number prepaid credit card online paypal african bank gold credit card limit increase how to get free credit card numbers that work 2013 top credit card issuers 2012 cash advance payday loan direct lenders reducing credit card debt legally rewards points redemption with hdfc credit card bp gas rebate credit cards discover business credit card offers how to apply for a secured credit card with bad credit federal credit card debt relief program fast easy online payday loans canada sears canada credit card contact number cash back credit card reward calculator can;t pay sallie mae student loans free download easy credit card checker 1.2 free online visa credit card best student credit cards bank of america lloyds visa card issue number aqua reward credit card terms and conditions how can i get a visa credit card with bad credit how to cut a credit card to open a door bank of america secured credit card upgrade bad credit loans no guarantor review is capital one secured credit card good recurring credit card authorization form apply credit cards bad credit what if you don;t want a credit card anymore lower credit limit virgin mobile how to get a credit card at 18 years old aqua credit card cash back can you get a credit card with no credit score vanquis credit card payment british airways credit card benefits kia visa rewards card balance do aldi accept credit cards uk use international credit card newegg navy federal credit union mortgage rates free usa virtual credit card offers visa and mastercard virtual prepaid credit cards nab gold visa debit card exchange rate 0 interest on cash advances credit cards online credit card payment payday advance no credit check free credit card details that work credit card apply online sbi bank canadian tire credit card list of bad credit loan lenders 70 000 mile american express delta credit card credit card minimum payment interest rate american express gold credit card uk credit card with rewards for gas easiest credit card approval with bad credit cheap credit cards balance transfers how to negotiate with credit card companies to reduce debt will applying for multiple credit cards hurt my credit score distributed data mining in credit card fraud detection best buy credit card canada application personal loan with bad credit and cosigner best unsecured credit cards rebuild credit ge money bank credit cards bad credit best 0 interest credit card offers rewards canada credit card comparison how to get high credit card limits union bank of india apply online credit card do you need a major credit card to rent a hotel room hdfc online credit card payment from other bank account cash doctors australia payday loans jp morgan government travel credit card activate virgin credit card online square up credit card logos secured credit card capital one canada itunes credit card fraud phone number credit card merchant fees philippines best credit card offer september 2013 visa black card requirements how to apply for a mastercard prepaid monthly pay loans best company credit card machines real valid credit card numbers with cvv reloadable credit cards no monthly fee credit cards in canada citibank online credit card payment from other banks sbi corporate credit card helpline number cash back credit card malaysia 2011 can you get a capital one credit card with no credit best payday loan lenders best rewards cards canada can you use td visa debit cards online credit cards bad credit no credit no deposit credit card apps for ipad best buy credit card payment mastercard international credit card services netherlands consumer reports credit card ratings 2012 hsbc student credit card hk maurices credit card balance phone number post office credit card super balance transfer personal loans on hdfc credit card easy no credit check credit cards security credit card chase credit card minimum payment percentage walmart credit card credit score amscot payday advance fees chase freedom credit card deal pnc secured credit card application kotak mahindra bank credit card apply eligibility canadian credit card companies that use transunion hsbc credit card customer care toll free number chennai hdfc platinum plus master credit card offers help rebuild credit cards myer visa card points walmart credit cards pay online compare prepaid credit card canada capital one credit card annual report annual gold card zones 1-3 credit card reporting to credit bureaus united chase visa credit card discharged bankruptcy credit cards guaranteed acceptance payday loan lender hsbc premier credit card hk low interest credit card transfer nz sallie mae student loans bill pay citibank credit card promotions sg starbucks credit card promotion hk credit cards with low apr and no annual fees hsbc direct rewards discover credit card acrylic credit card machine stand apply for business credit card no personal guarantee hsbc credit card visa verification best no fee credit card virgin money credit card balance transfer to current account best credit card reader app for ipad hotel rewards credit cards canada using natwest student credit card abroad using international credit cards in india amazon credit card uk review advance pay loans credit cards in canada for fair credit best buy reward zone credit card login free visa prepaid credit card free credit report without credit card information disney credit card reward dollars ambank credit card balance transfer malaysia 0 credit cards with no transfer fee secured credit cards to rebuild credit score unemployed cash loans now pay my first premier bank credit card bill wells fargo health advantage credit card how to hack a credit card number visa master cards download credit cards for bad credit instant approval no fees chase master credit card login should i consolidate my credit card debt into my mortgage western union gold card uae online credit card fraud detection ppt how to get credit card numbers hdfc credit card bank ifsc code prepaid td canada trust credit card how to get a credit card with no credit yahoo answers iphone credit card processing lowest rate virgin black credit card login pay off credit card debt improve credit score cash back visa card wells fargo visa signature credit card rewards canadian debit visa cards why do i need a credit card for free apps amazon easy approval store credit cards for bad credit fixed rate credit card processing hdfc credit card payment instant pay earth black credit card travel insurance purchase visa debit cards online credit card insurance coverage india how long after chapter 7 bankruptcy can i get a credit card pay as you go credit card uk short term cash loans credit card app uk iphone hsbc credit card reward points catalogue philippines apply for sears credit card best low interest credit cards 2011 fake valid credit card numbers for testing credit card annual interest rate calculator accepting international credit cards how can i get my first credit card with no credit history credit card number font photoshop lloyds credit card insurance on purchases accept credit card payments on your iphone uk american express platinum card benefits singapore best way to accept credit cards online for small business credit card number sample and security code woolworths black credit card online huge credit card fraud bust in new jersey usaa credit card rate increase prepaid visa debit cards canada best payday advance loans online platinum cardcaptor sakura download best credit card for someone with no credit 2013 hsbc credit card online apply how to get hdfc new credit card state bank of india international credit card direct payday lenders only online uk
Home Forum Download/Upload Links Search

NetTalk User Group

NetTalk User Group Meeting!
Live Webinar!
Saturday Nov. 16 
7am PST
Click Here To Register!
Home arrow Forum arrow The Rest Of NetTalkarrow The Rest - Share Knowledgearrow Getting length from a non Clarion NetSimple packet
NetTalk Central
September 04, 2015, 05:07:44 PM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News: Welcome to the NetTalk Central Forums!
   Home   Help Search Login Register  
Pages: [1]
Author Topic: Getting length from a non Clarion NetSimple packet  (Read 6075 times)
Paul Blais
Posts: 8

View Profile
« on: August 23, 2011, 06:53:58 PM »

The WholePacket NetSimple Methodis great for NetTalk to NetTalk objects since it sends the length as a 4 byte header and can assemble the packets for you saving some code. (See the manual boundary example).

There is a standard way that many non NetTalk TCP applications use. They send the length as a 4 bytes header but it is no Clarion LONG you can distinguish.

The Bytes are sent as a Big Endian ULONG Integer. This is great until you find out Clarion is not Big Endian So we pretend it's a STRING instead and it's all better. You just need a little funny math.

Should Capesoft add an option  to WholePacket to use Big Endian longs they could make WholePacket work with other players as well as Clarion and it wouldn't break anyones code since we compute length as a Clarion LONG, but NetTalk could use Big Endian as an option and we wouldn't care since it is doing all the work.

The following functions will convert properly (we tested it today with a an Online service)

ToBigEndian            PROCEDURE  (LONG RawVal),STRING   

ByteArray               BYTE,DIM(4)
OutputVal               STRING(4),OVER(ByteArray)


  ByteArray[1] = INT(RawVal/256^3)
  ByteArray[2] = INT((RawVal % 256^3) / 256^2)
  ByteArray[3] = INT((RawVal % 256^2) / 256)
  ByteArray[4] = INT(RawVal  % 256)
  RETURN OutputVal

And to go the other way:

FromBEndian          PROCEDURE  (STRING RawVal), LONG   

ByteArray               BYTE,DIM(4)
InputVal                STRING(4),OVER(ByteArray)
Result                  LONG

  InputVal = RawVal

  Result = (INT(ByteArray[1]) * 256^3 + |
            INT(ByteArray[2]) * 256^2 + |
            INT(ByteArray[3]) * 256   + |
            INT(ByteArray[4]))   ! The packet includes the 4 byte header

  RETURN Result

Special thanks to Marc Walgren of MItten Software for being the tester that would have asked me to fix it if it didn't work..

Global Moderator
Hero Member
Posts: 7753

View Profile
« Reply #1 on: August 23, 2011, 10:39:38 PM »

Hi Paul,

Thanks for the suggestion. The following applies to 5.33 and later.

I've added a property,
to the NetSimple Class.

This only has affect if the WholePacketUseLengthField property is set. If WholePacketUseBigEndian is set then the incoming length field, and the outgoing length field is added ot the header in "Big Endian" format - ie with the most significant byte first.

If this property is not set then the length field is assumed to be in Little Endian format (ie least significant byte first).

Paul Blais
Posts: 8

View Profile
« Reply #2 on: August 30, 2011, 04:07:08 AM »

Sounds exactly as required Bruce. Thanks for the feature!
Pages: [1]
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.11 | SMF © 2006-2009, Simple Machines LLC
Joomla Bridge by
Valid XHTML 1.0! Valid CSS!

Login Form

Welcome Guest.

Lost Password?
No account yet? Register
home contact search contact search