XLSForms और rtSurvey में decimal question type का उपयोग ऐसे numeric responses एकत्र करने के लिए किया जाता है जिनमें fractional parts शामिल हो सकते हैं। यह question type measurements, prices, या percentages जैसे precise numerical data gather करने के लिए आवश्यक है।

Basic XLSForm Specification

typenamelabel
decimalweightअपना वजन kg में दर्ज करें

Basic decimal question type के बारे में अधिक जानकारी के लिए, XLSForm specification देखें।

उपयोग

Decimal questions सामान्यतः इनके लिए उपयोग किए जाते हैं:

  1. Measurements (जैसे वजन, ऊँचाई, दूरी)
  2. Financial data (जैसे prices, salaries)
  3. Percentages
  4. Scientific data collection
  5. कोई भी numeric data जिसके लिए whole numbers से परे precision की आवश्यकता हो

Best Practices

  1. Expected input और measurement की unit निर्दिष्ट करने के लिए clear और concise labels का उपयोग करें।
  2. Unrealistic या erroneous inputs को रोकने के लिए range constraints लागू करें।
  3. Expected format को स्पष्ट करने या उदाहरण प्रदान करने के लिए hint text का उपयोग करने पर विचार करें।
  4. यदि precision महत्वपूर्ण है तो label या hint में desired decimal places की संख्या निर्दिष्ट करें।

Constraints और Validation

आप यह सुनिश्चित करने के लिए constraints जोड़ सकते हैं कि दर्ज किया गया मूल्य एक specific range में हो:

typenamelabelconstraintconstraint_message
decimalheightअपनी ऊँचाई meters में दर्ज करें.>0 and .<=3ऊँचाई 0 और 3 meters के बीच होनी चाहिए

Example Usage

यहाँ बताया गया है कि आप health survey में decimal questions का उपयोग कैसे कर सकते हैं:

typenamelabelconstraintconstraint_message
decimalweightअपना वजन kg में दर्ज करें.>0 and .<=500वजन 0 और 500 kg के बीच होना चाहिए
decimalheightअपनी ऊँचाई meters में दर्ज करें.>0 and .<=3ऊँचाई 0 और 3 meters के बीच होनी चाहिए
decimalbody_tempCelsius में अपना body temperature दर्ज करें.>=35 and .<=42Temperature 35°C और 42°C के बीच होना चाहिए
calculatebmi

BMI के लिए calculate row में, आप इसका उपयोग कर सकते हैं:

  calculation | ${weight} / (${height} * ${height})
  

यह दर्ज किए गए weight और height का उपयोग करके BMI calculate करेगा।

rtSurvey Extensions

Basic XLSForm specification के अतिरिक्त, rtSurvey अतिरिक्त सुविधाएं प्रदान कर सकता है:

  1. Precision control (decimal places की संख्या)
  2. Custom input formats (जैसे percentage, currency)
  3. Advanced validation rules

सीमाएं

  • Decimal numbers की precision underlying system या database द्वारा सीमित हो सकती है।
  • Users को उनकी locale के आधार पर expected decimal separator (period या comma) पर मार्गदर्शन की आवश्यकता हो सकती है।
  • Mobile devices पर बड़े decimal numbers को पढ़ना या सटीक रूप से input करना कठिन हो सकता है।
क्या यह पृष्ठ सहायक था?