Thread ID: |
Created: |
Updated: |
Platform: |
Replies: |
144576 | May 13,2019 06:32 AM UTC | May 29,2019 10:38 AM UTC | Vue | 3 |
![]() |
Tags: TextBox |
<template>
<div id="app">
<ejs-textbox ref="textareaObj" :created="onCreate" id="default" :multiline="true" :value="value" floatLabelType="Auto" placeholder="Enter your name"></ejs-textbox>
</div>
</template>
<script>
import Vue from "vue";
import { TextBoxPlugin } from '@syncfusion/ej2-vue-inputs';
Vue.use(TextBoxPlugin);
export default {
data() {
return {
value: "Syncfusion"
}
},
methods: {
onCreate: function (args) {
let value = this.$refs.textareaObj.value;
alert(value);
}
}
}
</script>
<style lang="scss">
@import "../node_modules/@syncfusion/ej2-base/styles/material.css";
@import "../node_modules/@syncfusion/ej2-vue-inputs/styles/material.css";
</style> |
<ejs-textbox ref="textboxObj" :change="changeValue" placeholder="First Name"></ejs-textbox> |
methods:{
changeValue:function(args){
console.log(args.value);
}
} |
<ejs-textbox ref="textboxObj" :change="changeValue" placeholder="First Name"></ejs-textbox> |
methods:{
changeValue:function(args){
console.log(this.$refs.textboxObj.ej2Instances.value);
}
} |
This post will be permanently deleted. Are you sure you want to continue?
Sorry, An error occured while processing your request. Please try again later.
This page will automatically be redirected to the sign-in page in 10 seconds.