![]() |
Insert Character in a String
i need to handle text in a shape with thousand of characters
when i insert a character or a string by character location, the insert method replace the string from position 10 to 265 with "a" it is not like an insert method ActiveSheet.Shapes("Text Box 17").Characters(10).insert("a") how to do the insert task correctly?? and seems i can not save more than 255 characters in a string but as in documentation, a string can store up to billions of characters dim temp as string temp = ActiveSheet.Shapes("Text Box 17").Characters(Start:=6, Length:=256).text is this part of the code have error instead of the string? ActiveSheet.Shapes("Text Box 17").Characters(Start:=6, Length:=256) What i can think about is to cut the string part by part.. and merge it finally. Is there any better way to do this? |
Insert Character in a String
Cut, append and merge would be the approach.
-- Regards, Tom Ogilvy "Laguna" wrote in message ... i need to handle text in a shape with thousand of characters when i insert a character or a string by character location, the insert method replace the string from position 10 to 265 with "a" it is not like an insert method ActiveSheet.Shapes("Text Box 17").Characters(10).insert("a") how to do the insert task correctly?? and seems i can not save more than 255 characters in a string but as in documentation, a string can store up to billions of characters dim temp as string temp = ActiveSheet.Shapes("Text Box 17").Characters(Start:=6, Length:=256).text is this part of the code have error instead of the string? ActiveSheet.Shapes("Text Box 17").Characters(Start:=6, Length:=256) What i can think about is to cut the string part by part.. and merge it finally. Is there any better way to do this? |
All times are GMT +1. The time now is 01:43 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com