2

I had used virtual keyboard plugin available here in Ext JS 3 :

It does not seem to be working with Ext JS 4 . I have changed VirtualKeyboard.js file & it looks as follwing, problem is BackSpace gives me an error : Uncaught TypeError: Cannot read property 'length' of undefined

Thrown while executing dom.value.substr(0, dom.value.length - 1)

Here is modified VirtualKeyboard.js : http://www.sencha.com/forum/showthread.php?147963-Extjs-4-virtual-keyboard-plugin

sra
  • 23,820
  • 7
  • 55
  • 89
S R
  • 674
  • 2
  • 18
  • 45
  • 1
    I don't understand how the VirtualKeyboard is relevant for generating a PDF from an ExtJs form. Please clarify your question. Do you need a solution for a virtual keyboard on ExtJS4? – mistaecko Sep 27 '11 at 03:00
  • For the PDF part of your question: There is no Plugin to create a PDF on client side if you just using JavaScript. There should be only one question per post, therefore I've edited it. – sra Sep 30 '11 at 09:58

2 Answers2

2

Instead of making changes in the original virtual keyboard file, use the sencha provided, Ext JS 3 to Ext JS 4 migration pack. This will allow the you to run Ext 3 code under Ext JS 4. You can use this pack until the original author of the virtual keyboard provides a patch for ext js 4. Using this pack does not have a drastic effect on the performance of the application because of the increased indirection.

You can download the migration pack from here.

Cheers.

Varun Achar
  • 14,781
  • 7
  • 57
  • 74
1

To fix you error use Firebug and debug the content of your dom variable. It seems that either your keyboardTarget variable has a wrong value or you need to fix your value accessor then you should just select the el and access it with el.getValue() (untested!)

sra
  • 23,820
  • 7
  • 55
  • 89